@esri/hub-common 9.11.0 → 9.13.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/dist/es2017/ArcGISContext.js +194 -0
  2. package/dist/es2017/ArcGISContext.js.map +1 -0
  3. package/dist/es2017/ArcGISContextState.js +203 -0
  4. package/dist/es2017/ArcGISContextState.js.map +1 -0
  5. package/dist/es2017/content/index.js +124 -1
  6. package/dist/es2017/content/index.js.map +1 -1
  7. package/dist/es2017/index.js +1 -0
  8. package/dist/es2017/index.js.map +1 -1
  9. package/dist/es2017/utils/index.js +1 -0
  10. package/dist/es2017/utils/index.js.map +1 -1
  11. package/dist/es2017/utils/sessionLocalStorage.js +47 -0
  12. package/dist/es2017/utils/sessionLocalStorage.js.map +1 -0
  13. package/dist/esm/ArcGISContext.js +238 -0
  14. package/dist/esm/ArcGISContext.js.map +1 -0
  15. package/dist/esm/ArcGISContextState.js +285 -0
  16. package/dist/esm/ArcGISContextState.js.map +1 -0
  17. package/dist/esm/content/index.js +124 -1
  18. package/dist/esm/content/index.js.map +1 -1
  19. package/dist/esm/index.js +1 -0
  20. package/dist/esm/index.js.map +1 -1
  21. package/dist/esm/utils/index.js +1 -0
  22. package/dist/esm/utils/index.js.map +1 -1
  23. package/dist/esm/utils/sessionLocalStorage.js +50 -0
  24. package/dist/esm/utils/sessionLocalStorage.js.map +1 -0
  25. package/dist/node/ArcGISContext.js +198 -0
  26. package/dist/node/ArcGISContext.js.map +1 -0
  27. package/dist/node/ArcGISContextState.js +207 -0
  28. package/dist/node/ArcGISContextState.js.map +1 -0
  29. package/dist/node/content/index.js +125 -2
  30. package/dist/node/content/index.js.map +1 -1
  31. package/dist/node/index.js +1 -0
  32. package/dist/node/index.js.map +1 -1
  33. package/dist/node/utils/index.js +1 -0
  34. package/dist/node/utils/index.js.map +1 -1
  35. package/dist/node/utils/sessionLocalStorage.js +53 -0
  36. package/dist/node/utils/sessionLocalStorage.js.map +1 -0
  37. package/dist/types/ArcGISContext.d.ts +110 -0
  38. package/dist/types/ArcGISContextState.d.ts +129 -0
  39. package/dist/types/content/index.d.ts +13 -0
  40. package/dist/types/index.d.ts +1 -0
  41. package/dist/types/types.d.ts +5 -2
  42. package/dist/types/utils/index.d.ts +1 -0
  43. package/dist/types/utils/sessionLocalStorage.d.ts +23 -0
  44. package/dist/umd/common.umd.js +3421 -2695
  45. package/dist/umd/common.umd.js.map +1 -1
  46. package/dist/umd/common.umd.min.js +1 -1
  47. package/dist/umd/common.umd.min.js.map +1 -1
  48. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"common.umd.js","sources":["../esm/objects/_map-values.js","../esm/objects/_deep-map-values.js","../esm/objects/get-prop.js","../esm/util.js","../esm/objects/deep-set.js","../esm/objects/ensure-prop.js","../esm/objects/get-props.js","../esm/objects/get-with-default.js","../esm/objects/remove-empty-props.js","../esm/objects/deep-string-replace.js","../esm/objects/merge-objects.js","../esm/objects/set-prop.js","../esm/objects/deepFind.js","../esm/utils/batch.js","../esm/utils/includes.js","../esm/utils/ensure-unique-string.js","../../../../node_modules/tslib/tslib.es6.js","../esm/OperationError.js","../esm/utils/create-operation-pipeline.js","../esm/utils/fail-safe.js","../esm/utils/generate-random-string.js","../esm/utils/get-hub-product.js","../esm/utils/get-subscription-type.js","../esm/utils/is-guid.js","../esm/utils/map-by.js","../esm/utils/slugify.js","../esm/utils/without-by-prop.js","../esm/utils/propify-string.js","../esm/utils/increment-string.js","../esm/utils/logger.js","../esm/utils/is-update-group.js","../esm/utils/revertable-tasks.js","../esm/access/has-base-priv.js","../esm/access/can-edit-event.js","../esm/access/can-edit-item.js","../esm/access/can-edit-site-content.js","../esm/access/can-edit-site.js","../esm/urls/build-url.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/process-params.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/encode-query-string.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/encode-form-data.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/ArcGISRequestError.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/warn.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/request.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/append-custom-params.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/clean-url.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/decode-query-string.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/get-portal-url.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/helpers.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/update.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/add.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/get.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/protect.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/get.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/helpers.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/remove.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/SearchQueryBuilder.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/generic-search.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/search.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/array.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/add-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/remove-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/invite-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/protect.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/remove.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/search.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/update-user-membership.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/orgs/notification.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/users/get-user.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/users/search-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/is-item-shared-with-group.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/share-item-with-group.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/unshare-item-with-group.js","../esm/urls/get-portal-url.js","../esm/urls/hub-cdn-urlmap.js","../esm/urls/get-hub-locale-asset-url.js","../esm/urls/get-portal-api-url.js","../esm/urls/upgrade-protocol.js","../esm/urls/strip-protocol.js","../esm/urls/_get-http-and-https-uris.js","../esm/urls/_get-location.js","../esm/urls/_get-hub-url-from-portal-hostname.js","../esm/urls/get-hub-url-from-portal.js","../esm/urls/get-hub-api-url-from-portal.js","../esm/urls/get-item-home-url.js","../esm/urls/get-item-api-url.js","../esm/urls/get-item-data-url.js","../esm/urls/convert-urls-to-anchor-tags.js","../esm/urls/index.js","../esm/api.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/fetch-token.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/generate-token.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/federation-utils.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/validate-app-access.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/UserSession.js","../esm/auth.js","../esm/collections.js","../esm/categories.js","../esm/extent.js","../esm/items/get-structured-license.js","../esm/content/_internal.js","../esm/content/index.js","../../../../node_modules/abab/lib/atob.js","../../../../node_modules/abab/lib/btoa.js","../../../../node_modules/abab/index.js","../esm/downloads/build-existing-exports-portal-query.js","../esm/groups/_unprotect-and-remove-group.js","../esm/groups/add-users-workflow/output-processors/_consolidate-results.js","../esm/groups/add-users-workflow/output-processors/_format-auto-add-response.js","../esm/groups/add-users-workflow/utils/_can-email-user.js","../esm/groups/add-users-workflow/utils/_is-org-admin.js","../esm/groups/add-users-workflow/workflow-sections/email-org-users.js","../esm/groups/add-users-workflow/output-processors/_process-secondary-email.js","../esm/groups/add-users-workflow/workflow-sections/auto-add-users.js","../esm/groups/add-users-workflow/output-processors/_process-auto-add.js","../esm/groups/add-users-workflow/workflow-sections/invite-users.js","../esm/groups/add-users-workflow/output-processors/_process-invite.js","../esm/groups/add-users-workflow/output-processors/_process-primary-email.js","../esm/groups/add-users-workflow/utils/_get-auto-add-users.js","../esm/groups/add-users-workflow/utils/_get-invite-users.js","../esm/groups/add-users-workflow/utils/_get-email-users.js","../esm/groups/add-users-workflow/add-users-to-group.js","../esm/items/_unprotect-and-remove-item.js","../esm/items/apply-properties-to-items.js","../esm/items/delete-prop.js","../esm/items/serialize-model.js","../esm/items/fail-safe-update.js","../esm/items/get-model.js","../esm/items/get-model-from-options.js","../../../../node_modules/adlib/dist/adlib.esm.js","../esm/items/interpolate.js","../esm/items/interpolate-item-id.js","../esm/items/normalize-solution-template-item.js","../esm/items/replace-item-id.js","../esm/items/share-item-to-groups.js","../esm/items/unprotect-model.js","../esm/items/unshare-item-from-groups.js","../esm/items/does-item-exist-with-title.js","../esm/items/get-unique-item-title.js","../esm/items/fetch-all-pages.js","../esm/resources/_add-token-to-resource-url.js","../esm/resources/convert-solution-template-resources-to-assets.js","../esm/resources/fetch-image-as-blob.js","../esm/resources/fetch-and-upload-resource.js","../esm/resources/fetch-and-upload-thumbnail.js","../esm/resources/get-item-thumbnail-url.js","../esm/resources/get-item-assets.js","../esm/resources/string-to-blob.js","../esm/resources/upload-resources-from-url.js","../esm/resources/add-solution-resource-url-to-assets.js","../esm/resources/object-to-json-blob.js","../esm/search/hub-api-search.js","../esm/search/utils.js","../esm/search/content-utils.js","../esm/search/group-utils.js","../esm/search/user-utils.js","../esm/search/_searchContent.js","../esm/search/_searchGroups.js","../esm/search/_searchUsers.js","../esm/sites/domains/_check-status-and-parse-json.js","../esm/sites/domains/_get-auth-header.js","../esm/sites/domains/_get-domain-service-url.js","../esm/sites/domains/_lookup-portal.js","../esm/sites/domains/add-domain.js","../esm/sites/domains/domain-exists.js","../esm/sites/domains/domain-exists-portal.js","../esm/sites/domains/get-domains-for-site.js","../esm/sites/domains/get-unique-domain-name.js","../esm/sites/domains/get-unique-domain-name-portal.js","../esm/sites/domains/is-domain-for-legacy-site.js","../esm/sites/domains/lookup-domain.js","../esm/sites/domains/is-domain-used-elsewhere.js","../esm/sites/domains/is-valid-domain.js","../esm/sites/domains/remove-domain.js","../esm/sites/domains/update-domain.js","../esm/sites/domains/_ensure-safe-domain-length.js","../esm/sites/domains/ensure-unique-domain-name.js","../esm/sites/get-site-by-id.js","../esm/sites/drafts/build-draft.js","../esm/sites/_ensure-telemetry.js","../esm/sites/site-schema-version.js","../esm/sites/_apply-site-schema.js","../esm/sites/_enforce-lowercase-domains.js","../esm/sites/_ensure-catalog.js","../esm/sites/_purge-non-guids-from-catalog.js","../esm/sites/_migrate-feed-config.js","../esm/sites/upgrade-site-schema.js","../esm/sites/index.js","../esm/i18n/hub-locales.js","../esm/i18n/convert-to-well-known-locale.js","../esm/i18n/fetch-hub-translation.js","../esm/i18n/get-culture.js","../esm/request.js","../esm/surveys/get-input-feature-service-model.js","../esm/surveys/get-source-feature-service-model-from-fieldworker.js","../esm/surveys/get-stakeholder-model.js","../esm/surveys/is-fieldworker-view.js","../esm/surveys/get-survey-models.js","../esm/OperationStack.js"],"sourcesContent":["/**\n * Maps over the values of an object (one level deep)\n * @param obj\n * @param fn\n * @private\n */\nexport function _mapValues(obj, fn) {\n var keys = Object.keys(obj);\n var newObject = keys.reduce(function (acc, currentKey) {\n acc[currentKey] = fn(obj[currentKey], currentKey, obj);\n return acc;\n }, {});\n return newObject;\n}\n//# sourceMappingURL=_map-values.js.map","import { _mapValues } from \"./_map-values\";\n/**\n * Maps over _all_ values of an object graph\n * @param object\n * @param callback function to be called on each value\n * @param propertyPath an initial path (optional, only changes what is passed to the callback as the \"path\" argument)\n * @private\n */\nexport function _deepMapValues(object, callback, propertyPath) {\n propertyPath = propertyPath || \"\";\n if (Array.isArray(object)) {\n return object.map(deepMapValuesIteratee);\n }\n else if (object &&\n _isObject(object) &&\n !_isDate(object) &&\n !_isRegExp(object) &&\n !_isFunction(object)) {\n return Object.assign({}, object, _mapValues(object, deepMapValuesIteratee));\n }\n else {\n return callback(object, propertyPath);\n }\n function deepMapValuesIteratee(value, key) {\n var valuePath = \"\" + (propertyPath ? propertyPath + \".\" + key : key);\n return _deepMapValues(value, callback, valuePath);\n }\n}\n// Simple \"good-enough\" type checks for the tree traversal functions\n// these are not bullet-proof and should not be public/docd\n/**\n * Is this a string?\n * @param v\n * @private\n */\nexport function _isString(v) {\n return typeof v === \"string\" || v instanceof String;\n}\n/**\n * Return if the passed entry is a Date\n * @param v\n * @private\n */\nexport function _isDate(v) {\n return v instanceof Date;\n}\n/**\n * Is this a function?\n * @param v\n * @private\n */\nexport function _isFunction(v) {\n return typeof v === \"function\";\n}\n/**\n * Is this an Object?\n * @param v\n * @private\n */\nexport function _isObject(v) {\n return typeof v === \"object\";\n}\n/**\n * Is this a regexp?\n * @param v\n * @private\n */\nexport function _isRegExp(v) {\n return v instanceof RegExp;\n}\n//# sourceMappingURL=_deep-map-values.js.map","/**\n * Get a property out of a deeply nested object\n * Does not handle anything but nested object graph\n */\nexport function getProp(obj, path) {\n return path.split(\".\").reduce(function (prev, curr) {\n /* istanbul ignore next no need to test undefined scenario */\n return prev ? prev[curr] : undefined;\n }, obj);\n}\n//# sourceMappingURL=get-prop.js.map","/* Copyright (c) 2018-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { getProp } from \"./objects/get-prop\";\n/**\n * ```js\n * import { cloneObject } from \"@esri/hub-common\";\n * const original = { foo: \"bar\" }\n * const copy = cloneObject(original)\n * copy.foo // \"bar\"\n * copy === original // false\n * ```\n * Make a deep clone, including arrays. Does not handle functions!\n */\nexport function cloneObject(obj) {\n var clone = {};\n // first check array\n if (Array.isArray(obj)) {\n clone = obj.map(cloneObject);\n }\n else if (typeof obj === \"object\") {\n for (var i in obj) {\n /* istanbul ignore next no need to deal w/ other side of hasOwnProperty() */\n if (obj.hasOwnProperty(i)) {\n var value = obj[i];\n if (value != null && typeof value === \"object\") {\n if (value instanceof Date) {\n clone[i] = new Date(value.getTime());\n }\n else {\n clone[i] = cloneObject(value);\n }\n }\n else {\n clone[i] = value;\n }\n }\n }\n }\n else {\n clone = obj;\n }\n return clone;\n}\n/**\n * Given an array of objects, convert into an object, with each\n * entry assigned the key via the keyprop\n */\nexport function arrayToObject(arr, key) {\n return arr.reduce(function (hash, entry) {\n hash[getProp(entry, key)] = entry;\n return hash;\n }, {});\n}\n/**\n * Given an object, convert into an array, with each\n * something or other\n */\nexport function objectToArray(obj, keyProp) {\n if (keyProp === void 0) { keyProp = \"id\"; }\n var arr = Object.keys(obj).reduce(function (acc, prop) {\n obj[prop][keyProp] = prop;\n acc.push(cloneObject(obj[prop]));\n return acc;\n }, []);\n return arr;\n}\n/**\n * Return an entry from an array by a property name\n */\nexport function findBy(arr, prop, value) {\n if (!arr) {\n return null;\n }\n var res = arr.reduce(function (acc, entry) {\n if (getProp(entry, prop) === value) {\n acc = entry;\n }\n return acc;\n }, null);\n return res;\n}\n/**\n * Return a new array without the specified value.\n *\n * @export\n * @param {any[]} arr\n * @param {*} val value or object to remove\n * @returns {any[]} Array without the value\n */\nexport function without(arr, value) {\n var res = arr.filter(function (entry) { return entry !== value; });\n return res;\n}\n/**\n * Compose\n * adapted from: https://github.com/stoeffel/compose-function/blob/master/module/index.js\n */\nexport function compose() {\n var fns = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n fns[_i] = arguments[_i];\n }\n return fns.reduce(function (f, g) {\n return function () {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n return f(g.apply(void 0, args));\n };\n });\n}\n/**\n * Return a random number, prefixed with a string. Used for unique identifiers that do not require\n * the rigor of a full UUID - i.e. node id's, process ids etc.\n * @param prefix String to prefix the random number with so the result is a valid javascript property\n */\nexport function createId(prefix) {\n if (prefix === void 0) { prefix = \"i\"; }\n // prepend some char so it's always a valid dotable property name\n // get a random number, convert to base 36 representation, then grab chars 2-8\n return \"\" + prefix + Math.random().toString(36).substr(2, 8);\n}\n/**\n * Append or replace a value on an object, using a specified key, if the value is not null.\n * This is a very useful companion to the [getProp()](../getProp/) utility.\n *\n * Note: object that is passed in is cloned before the property is appended.\n *\n * Allows for code like:\n *\n * ```js\n * let model = {\n * item: {\n * title: 'some example object',\n * description: 'this is some longer text',\n * type: 'Web Map',\n * properties: {\n * sourceId: '3ef'\n * }\n * },\n * data: {\n * theme: 'orange',\n * parcelLayer: {\n * primaryField: 'PIN'\n * }\n * }\n * };\n *\n * // Let's extract some details into an object.\n * const summary = [\n * 'item.title',\n * 'item.description',\n * 'item.missingProp',\n * 'data.parcelLayer.primaryField'].reduce((acc, prop) => {\n * // create the property name... you could do this however...\n * let propName = prop.split('.').reverse()[0];\n * return maybeAdd(propName, getProp(model, key), acc);\n * }, {});\n *\n * // summary =>\n * // {\n * // title: 'some example object',\n * // description: 'this is some longer text',\n * // primaryField: 'PIN'\n * // }\n * ```\n * @param key - key to use when appending to the object\n * @param val - the possibly null value\n * @param target - the object to update\n */\nexport function maybeAdd(key, val, target) {\n // see if we got something...\n if (val !== null && val !== undefined) {\n target = cloneObject(target);\n // attach using the key\n target[key] = val;\n }\n return target;\n}\n/**\n * Append a value to an array, if the value is not null.\n * This is a very useful companion to the [getProp()](../getProp/) utility.\n *\n * Note: the array that is passed in is cloned before being appended to.\n *\n * Allows for code like:\n * ```js\n * // example object\n * let model = {\n * item: {\n * id: 'c00',\n * title: 'some example object',\n * description: 'this is some longer text',\n * type: 'Web Map',\n * properties: {\n * sourceId: '3ef'\n * }\n * },\n * data: {\n * theme: 'orange',\n * parcelLayer: {\n * itemId: '7ca',\n * primaryField: 'PIN'\n * }\n * }\n * };\n * // lets pluck some id's into an array...\n * maybePush(getProp(model, 'item.properties.sourceId'), []);\n * // > ['3ef']\n *\n * // now try to get a value from a property that is missing...\n * maybePush(getProp(obj, 'item.properties.childId'), []);\n * // > []\n *\n * // easily pluck values via property paths\n * const summary = [\n * 'item.id',\n * 'item.properties.sourceId',\n * 'item.properties.childId',\n * 'data.parcelLayer.itemId'].reduce((acc, prop) => {\n * return maybePush(getProp(model, key), acc);\n * }, []);\n *\n * // summary => ['c00', '3ef', '7ca']\n *\n * ```\n *\n * @param val - the possibly null value\n * @param target - the array to add the value to\n */\nexport function maybePush(val, target) {\n if (val !== null && val !== undefined) {\n // create a clone because mutation makes us sad...\n target = cloneObject(target);\n target.push(val);\n }\n return target;\n}\n/**\n * Convert a string to camelCase\n *\n * @export\n * @param {string} value\n * @returns {string} camelCased string\n */\nexport function camelize(value) {\n // lower case the whole thing to start...\n value = value.toLowerCase();\n // strip out any/all special chars...\n value = value.replace(/[`~!@#$%^&*()_|+\\-=?;:'\",.<>\\{\\}\\[\\]\\\\\\/]/gi, \" \");\n // Hoisted from EmberJS (MIT License)\n // https://github.com/emberjs/ember.js/blob/v2.0.1/packages/ember-runtime/lib/system/string.js#L23-L27\n var STRING_CAMELIZE_REGEXP_1 = /(\\-|\\_|\\.|\\s)+(.)?/g;\n var STRING_CAMELIZE_REGEXP_2 = /(^|\\/)([A-Z])/g;\n return value\n .replace(STRING_CAMELIZE_REGEXP_1, function (match, separator, chr) {\n return chr ? chr.toUpperCase() : \"\";\n })\n .replace(STRING_CAMELIZE_REGEXP_2, function (match, separator, chr) {\n return match.toLowerCase();\n });\n}\n/**\n * Determines if a value is unique in an array\n * Allows for code like:\n *\n * ```js\n * const ary = [ 1, 2, 3, 3, 4, 5, 1 ];\n *\n * const result = ary.filter(unique);\n *\n * result => [ 1, 2, 3, 4, 5 ]\n * ```\n * @param value - the value to search for\n * @param index - the index of the searched value\n * @param ary - the array to search\n * @returns {boolean} - indicating if the value is unique in the array\n */\nexport function unique(value, index, ary) {\n return ary.indexOf(value) === index;\n}\n/**\n * Return array of unique objects, based on a deep property value\n * Note: Property you compare on should be a primative type\n * @export\n * @template T\n * @param {T[]} arr\n * @param {string} prop\n * @return {*} {T[]}\n */\nexport function uniqueBy(arr, prop) {\n return arr.reduce(function (acc, entry) {\n var nameMatches = function (e) {\n return getProp(e, prop) === getProp(entry, prop);\n };\n return maybePush(acc.find(nameMatches) ? null : entry, acc);\n }, []);\n}\n/**\n * Return last element of an array\n *\n * @export\n * @template T\n * @param {T[]} arr\n * @return {*} {T}\n */\nexport function last(arr) {\n return arr[arr.length - 1];\n}\n/**\n * Filter an array by a deep property value\n *\n * @export\n * @template T\n * @param {T[]} arr\n * @param {string} prop\n * @param {unknown} val\n * @return {*} {T[]}\n */\nexport function filterBy(arr, prop, val) {\n return arr.filter(function (entry) { return getProp(entry, prop) === val; });\n}\n/**\n * Extends the target object with props from the source object, overwriting identically named\n * props in target with those from source, ignoring null and undefined values; similar to $.extend.\n * Performs a deep extend by default, unless deep = false is passed as the third arg.\n *\n * @param target - the object that will take props from source\n * @param source - the object from which to take props\n * @param deep - whether or not to perform a deep (recursive) extend of source\n */\nexport function extend(target, source, deep) {\n if (deep === void 0) { deep = true; }\n var extended = cloneObject(target);\n return Object.keys(source).reduce(function (obj, prop) {\n if (source[prop] !== null && source[prop] !== undefined) {\n var value = cloneObject(source[prop]);\n if (Array.isArray(value)) {\n // check for arrays, since array is type object\n obj[prop] = value;\n }\n else if (deep && typeof value === \"object\") {\n obj[prop] = extend(obj[prop] || {}, value, deep);\n }\n else {\n obj[prop] = value;\n }\n }\n return obj;\n }, extended);\n}\n/**\n * Add number of days to a given date\n *\n * @export\n * @param {string} date\n * @param {number} numOfDays\n * @returns {string} date string with numOfDays added to the given date\n */\nexport function addDays(date, numOfDays) {\n try {\n var given = new Date(date);\n var dateString = new Date(given.setDate(given.getDate() + numOfDays)).toISOString();\n return dateString.split(\"T\")[0];\n }\n catch (e) {\n throw new Error(\"Invalid Date\");\n }\n}\n/**\n * Returns an array with arrays of the given size.\n *\n * @param arr Array to split\n * @param size Size of every group\n */\nexport function chunkArray(arr, size) {\n var results = [];\n var index = 0;\n while (index < arr.length) {\n results.push(arr.slice(index, index + size));\n index += size;\n }\n return results;\n}\n/**\n * Determine if a value is null or undefined\n * @param value anything\n * @returns\n */\nexport var isNil = function (value) { return value == null; };\n/**\n * Upper case first letter (only) of a string\n * @param word\n * @returns Word\n */\nexport var capitalize = function (word) {\n // upper case first letter and return as element in array for backwards compatibility\n var chars = Array.from(word);\n chars[0] = chars[0].toUpperCase();\n return chars.join(\"\");\n};\n/**\n * An IE-compatible stand-in for Javascript's [array.flat](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/flat)\n * @param arr the array\n * @returns an array\n */\nexport function flattenArray(arr) {\n return arr.reduce(function (acc, val) { return acc.concat(val); }, []);\n}\n//# sourceMappingURL=util.js.map","import { cloneObject } from \"../util\";\n/**\n * Deep set function. Like Ember.set, but smarter as it will create the path\n * @param {Object} target Object we want to set the property on\n * @param {String} path Dotted path to the property we want to set\n * @param {Any} value Value we want to assign to the property\n */\nexport function deepSet(target, path, value) {\n if (value === void 0) { value = {}; }\n var parts = path.split(\".\");\n var worker = target;\n var lastIdx = parts.length - 1;\n parts.forEach(function (p, idx) {\n if (!worker.hasOwnProperty(p) || worker[p] == null) {\n if (idx === lastIdx) {\n worker[p] = value;\n }\n else {\n // keep building the path\n worker[p] = {};\n }\n }\n else if (idx === lastIdx) {\n if (typeof worker[p] === \"object\" && !Array.isArray(worker[p])) {\n worker[p] = Object.assign(worker[p], cloneObject(value));\n }\n else {\n worker[p] = value;\n }\n }\n worker = worker[p];\n });\n}\n//# sourceMappingURL=deep-set.js.map","import { deepSet } from \"./deep-set\";\n/**\n * Ensure that an object has a deep property path.\n * This will replace any existing object at the end of the path\n * @param {Object} target Object we want to ensure has some deep property\n * @param {string} path Dotted path to the property we want to ensure exists\n */\nexport function ensureProp(target, path) {\n return deepSet(target, path);\n}\n//# sourceMappingURL=ensure-prop.js.map","import { getProp } from \"./get-prop\";\n/**\n * Given an array of prop paths, return all the values that exist, in an array\n */\nexport function getProps(obj, props) {\n return props.reduce(function (a, p) {\n var v = getProp(obj, p);\n if (v) {\n a.push(v);\n }\n return a;\n }, []);\n}\n//# sourceMappingURL=get-props.js.map","import { getProp } from \"./get-prop\";\n/**\n * Gets the value of a property from an object with a\n * default if that prop is undefined\n * @param obj\n * @param prop\n * @param def\n */\nexport function getWithDefault(obj, prop, def) {\n var res = getProp(obj, prop);\n return res !== undefined ? res : def;\n}\n//# sourceMappingURL=get-with-default.js.map","/**\n * Remove empty properties from an object graph\n * @param {Object} obj Object to remove empty/null properties from\n */\nexport function removeEmptyProps(obj) {\n // http://stackoverflow.com/questions/286141/remove-blank-attributes-from-an-object-in-javascript\n Object.keys(obj).forEach(function (key) {\n if (obj[key] && typeof obj[key] === \"object\") {\n removeEmptyProps(obj[key]);\n }\n else if (obj[key] == null) {\n delete obj[key];\n }\n });\n return obj;\n}\n//# sourceMappingURL=remove-empty-props.js.map","import { _deepMapValues, _isString, _isRegExp } from \"./_deep-map-values\";\n/**\n * Iterate over an object graph, and for all string properties, search for a string,\n * and replace it with another string\n */\nexport function deepStringReplace(obj, stringOrRegex, replacement) {\n var replacedObject = _deepMapValues(obj, function (value) {\n // Only string templates\n if (!_isString(value)) {\n return value;\n }\n var re;\n if (_isRegExp(stringOrRegex)) {\n re = stringOrRegex;\n }\n else {\n re = new RegExp(stringOrRegex, \"g\");\n }\n return value.replace(re, replacement);\n });\n return replacedObject;\n}\n//# sourceMappingURL=deep-string-replace.js.map","import { getProp } from \"./get-prop\";\nimport { deepSet } from \"./deep-set\";\n/**\n * Apply a specified set properties from a source object to a target object\n *\n * @param {Object} source The source object\n * @param {Object} target The target object\n * @param {Array} allowList Array of property paths (if not provided, source returned)\n */\nexport function mergeObjects(source, target, allowList) {\n if (Array.isArray(allowList) && allowList.length) {\n // we iterate the allowList, applying changes to the target from source\n allowList.forEach(function (prop) {\n if (getProp(source, prop) !== undefined) {\n deepSet(target, prop, getProp(source, prop));\n }\n });\n // return the modified target object\n return target;\n }\n else {\n // if no property paths were passed in, return the source\n return source;\n }\n}\n//# sourceMappingURL=merge-objects.js.map","import { deepSet } from \"./deep-set\";\n/**\n * Sets a deep object property, constructing the property path as necessary\n *\n * @param path - the path to the property we want to set\n * @param val - the value we want to set it to\n * @param obj - the target object\n */\nexport function setProp(path, val, obj) {\n if (Array.isArray(path)) {\n path = path.join(\".\");\n }\n deepSet(obj, path, val);\n}\n//# sourceMappingURL=set-prop.js.map","import { _isDate, _isFunction, _isObject, _isRegExp, } from \"./_deep-map-values\";\n/**\n * Traverse a graph, locating the first entry with an `id` property that\n * has a specific string or number value\n *\n * ```js\n * const l = {\n * one: {\n * two: [\n * {\n * id: \"n001\",\n * color: \"red\"\n * },\n * {\n * id: \"n002\",\n * color: \"yellow\"\n * }\n * ]\n * }\n * };\n *\n * const config = deepFindById(l, \"n002\")\n * //> {id: \"n002\", color:\"yellow\"}\n * ```\n *\n * This was designed to search a Site/Page/Project layout, and return\n * the config for a card. There was some concern about the performance\n * and using a real layout object, in the test, it takes ~1.5ms to\n * do the search.\n *\n * @param object\n * @param key\n * @param value\n * @returns\n */\nexport function deepFindById(object, value) {\n var p = function (obj) { return obj.id === value; };\n return deepFind(object, p);\n}\n/**\n * Traverse a graph locating an entry that passes the predicate\n *\n * @param object\n * @param predicate\n * @returns\n */\nexport function deepFind(object, predicate) {\n if (Array.isArray(object)) {\n return object.reduce(function (acc, entry) {\n if (predicate(entry)) {\n acc = entry;\n }\n else {\n if (isFindable(entry)) {\n var maybe = deepFind(entry, predicate);\n if (maybe) {\n acc = maybe;\n }\n }\n }\n return acc;\n }, undefined);\n }\n else if (isFindable(object)) {\n if (predicate(object)) {\n return object;\n }\n else {\n return Object.keys(object).reduce(function (acc, entry) {\n if (isFindable(object[entry])) {\n var maybe = deepFind(object[entry], predicate);\n if (maybe) {\n acc = maybe;\n }\n }\n return acc;\n }, undefined);\n }\n }\n else {\n return undefined;\n }\n}\nfunction isFindable(object) {\n var result = false;\n if (object &&\n _isObject(object) &&\n !_isDate(object) &&\n !_isRegExp(object) &&\n !_isFunction(object)) {\n result = true;\n }\n return result;\n}\n//# sourceMappingURL=deepFind.js.map","/**\n * Helper to split a large number of calls into\n * smaller batches of concurrent calls.\n * @param {Array} values Any array of values with which to invoke fn\n * @param {Function} fn The function that will be invoked with each value\n * @param {number} [batchSize=5] The number of concurrent calls to fn, defaults to 5\n * @returns {Promise<IBatch[]>}\n */\nexport function batch(values, fn, batchSize) {\n if (batchSize === void 0) { batchSize = 5; }\n var toBatches = function (_batches, value) {\n var _batch = _batches[_batches.length - 1];\n if (!_batch || _batch.length === batchSize) {\n _batch = [];\n _batches.push(_batch);\n }\n _batch.push(value);\n return _batches;\n };\n var toSerialBatchChain = function (promise, batchOfValues) {\n var executeBatch = function (prevResults) {\n var batchResults = batchOfValues.map(function (id) { return fn(id); });\n return Promise.all(batchResults).then(function (results) {\n return prevResults.concat(results);\n });\n };\n return promise.then(executeBatch);\n };\n // split values into batches of values\n var batches = values.reduce(toBatches, []);\n // batches are processed serially, however\n // all calls within a batch are concurrent\n return batches.reduce(toSerialBatchChain, Promise.resolve([]));\n}\n//# sourceMappingURL=batch.js.map","/**\n * Checks whether a value exists in the given array\n * @param array The array\n * @param val The value\n */\nexport function includes(array, val) {\n return array.indexOf(val) !== -1;\n}\n//# sourceMappingURL=includes.js.map","import { includes } from \"./includes\";\n/**\n * Given an array of strings, add a value and ensure it is unique by incrementing a suffix number\n * @param {Array} entries array of strings\n * @param {string} value string to uniqueify and add\n */\nexport function ensureUniqueString(entries, value) {\n var foundUnique = false;\n var num = 0;\n var chk = value;\n while (!foundUnique) {\n if (includes(entries, chk)) {\n num++;\n chk = value + \"-\" + num;\n }\n else {\n foundUnique = true;\n }\n }\n return chk;\n}\n//# sourceMappingURL=ensure-unique-string.js.map","/*! *****************************************************************************\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***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n 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 extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(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\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n 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;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\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;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport function __createBinding(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}\r\n\r\nexport function __exportStar(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !exports.hasOwnProperty(p)) exports[p] = m[p];\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\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 () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\r\n result.default = mod;\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","/* Copyright (c) 2018-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __extends } from \"tslib\";\nimport { getWithDefault } from \"./objects/get-with-default\";\n/**\n * Generic Solution Error with an Error stack as well\n * as an optional serialized OperationStack.\n *\n * Also accepts a `rootCause` Error object\n */\nvar OperationError = /** @class */ (function (_super) {\n __extends(OperationError, _super);\n /**\n * Creates an instance of OperationError.\n * @param {string} operation\n * @param {string} [message]\n * @param {Error} [rootCause]\n * @memberof OperationError\n */\n function OperationError(operation, message, rootCause) {\n var _this = this;\n message = message || \"UNKNOWN_ERROR\";\n // if the rootCause has a .rootCause, use that so we don't deeply nest\n rootCause = getWithDefault(rootCause, \"rootCause\", rootCause);\n _this = _super.call(this, message) || this;\n _this.operation = operation;\n _this.name = \"OperationError\";\n _this.rootCause = rootCause;\n Object.setPrototypeOf(_this, OperationError.prototype);\n // using rootCause.stack ensures that the resulting error will have the original\n // message + call stack. If that's not an option, we create a new\n // stack... which is better than nothing, but it will look like\n // OperationError is the source of the error\n _this.stack = getWithDefault(rootCause, \"stack\", new Error().stack);\n return _this;\n }\n return OperationError;\n}(Error));\nexport default OperationError;\n//# sourceMappingURL=OperationError.js.map","import OperationError from \"../OperationError\";\n/**\n * Returns a function that orchestrates a pipeline of smaller functions.\n * See [Composing Workflows](../../../guides/composing-workflows) for more information.\n *\n * All the functions must adhere to the `PipelineFn<T>` signature:\n *\n * `(value: IPipeable<T>) => Promise<IPipeable<T>>`\n *\n * Given an array of OperationPipeFns, run them in sequence and return the resultant promise\n *\n * i.e. `createOperationPipeline([fn1, fn2, f3])` will return in a function that chains\n * the functions like this: `fn1(input).then(fn2).then(fn3).then(result)`\n *\n * @param fns functions to be run in sequence\n * @returns Promise<Pipable<T>>\n */\nexport var createOperationPipeline = function (fns) {\n return function (input) {\n return fns.reduce(function (chain, func) {\n return chain.then(func).catch(function (err) {\n // if it's an OperationError we can just reject with it...\n if (err.name === \"OperationError\") {\n return Promise.reject(err);\n }\n else {\n // otherwise, create an OperationError and reject with that\n var msg = \"IPipeableFn did not reject with an OperationError \\n Operation Stack: \\n \" + input.stack.toString();\n var opErr = new OperationError(\"pipeline execution error\", msg);\n opErr.operationStack = input.stack.serialize();\n return Promise.reject(opErr);\n }\n });\n }, Promise.resolve(input));\n };\n};\n//# sourceMappingURL=create-operation-pipeline.js.map","/**\n * Wrap an async function such that it will never reject\n * @param {Function} fn Async Function that we want to never fail\n * @param {Object} resolveWith Object to resolve with in the event of a failure\n */\nexport function failSafe(fn, resolveWith) {\n if (resolveWith === void 0) { resolveWith = {}; }\n return function () {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n return fn.apply(void 0, args).catch(function (_) {\n return resolveWith;\n });\n };\n}\n//# sourceMappingURL=fail-safe.js.map","/**\n * Generate a random string of a specified length\n * User when we need to ensure a unique domain with a fixed length\n * @param {Number} chars Length of random string\n */\nexport function generateRandomString(chars) {\n var d = new Date().getTime();\n var result = Array(chars)\n .fill(0)\n .reduce(function (acc) {\n /* tslint:disable-next-line */\n var r = (d + Math.random() * 16) % 16 | 0;\n d = Math.floor(d / 16);\n acc = \"\" + acc + r.toString(16);\n return acc;\n }, \"\");\n return result;\n}\n//# sourceMappingURL=generate-random-string.js.map","import { getProp } from \"../objects/get-prop\";\n/**\n * Gien a portal settings object, determine the hub product name\n * @param {Object} portal Portal settings object\n */\nexport function getHubProduct(portal) {\n var isPremium = getProp(portal, \"portalProperties.hub.enabled\") || false;\n var product = isPremium ? \"premium\" : \"basic\";\n // TODO confirm w/ AGO that this is 100% bomber logic\n if (portal.isPortal && portal.portalMode === \"singletenant\") {\n product = \"portal\";\n }\n return product;\n}\n//# sourceMappingURL=get-hub-product.js.map","import { getWithDefault } from \"../objects/get-with-default\";\nexport var getSubscriptionType = function (portalSelf) {\n return getWithDefault(portalSelf, \"subscriptionInfo.type\", \"Enterprise\");\n};\n//# sourceMappingURL=get-subscription-type.js.map","/**\n * Is a String a GUID?\n * @param {string} stringToTest string to check if it's a GUID\n */\nexport function isGuid(stringToTest) {\n // strip curlies if sent...\n if (stringToTest[0] === \"{\") {\n stringToTest = stringToTest.substring(1, stringToTest.length - 1);\n }\n // ughh... seems legit\n var regexGuid = /^(\\{){0,1}[0-9a-fA-F]{8}[-]?[0-9a-fA-F]{4}[-]?[0-9a-fA-F]{4}[-]?[0-9a-fA-F]{4}[-]?[0-9a-fA-F]{12}(\\}){0,1}$/gi;\n // test\n return regexGuid.test(stringToTest);\n}\n//# sourceMappingURL=is-guid.js.map","/**\n * Map over an array returning the specified property for each entry\n * @param {String} prop Property to extracct\n * @param {Array} arr array of objects\n */\nexport function mapBy(prop, arr) {\n if (arr === void 0) { arr = []; }\n return arr.map(function (e) { return e[prop]; });\n}\n//# sourceMappingURL=map-by.js.map","/**\n * Perform the following operations on a string to make it slug-friendly:\n * 1. trim it\n * 2. convert to lowercase\n * 3. remove any character not a-z, 0-9, or _\n * 4. dasherize it\n * @param {String} value String to slugify\n */\nexport function slugify(value) {\n if (typeof value === \"string\") {\n // @ts-ignore\n return value\n .trim()\n .toLowerCase()\n .replace(/ +/g, \"-\")\n .replace(/[^\\w-]/g, \"\")\n .replace(/-+/g, \"-\");\n }\n else {\n return value;\n }\n}\n//# sourceMappingURL=slugify.js.map","/**\n * Returns a new array with all the entries have the given value\n * at the given prop location removed.\n *\n * @param prop the property\n * @param val the value\n * @param arr the array\n */\nexport function withoutByProp(prop, val, arr) {\n return arr.filter(function (e) {\n return e[prop] !== val;\n });\n}\n//# sourceMappingURL=without-by-prop.js.map","import { camelize } from \"../util\";\n/**\n * Given a string, strip out chars etc that would make it\n * and invalid javascript property name, then camelize it.\n * @param {string} value String to convert into a property\n */\nexport function propifyString(value) {\n var result = value;\n // strip off any leading numbers...\n result = result.replace(/^[0-9]*/g, \"\");\n // remove any rando chars...\n result = result.replace(/[^\\w\\s]/g, \"\");\n // camelize the rest...\n result = camelize(result);\n return result;\n}\n//# sourceMappingURL=propify-string.js.map","/**\n * Given a string, append a `- 1` on the end if no number is present\n * otherwise, increment the number\n * @param {string} str String to increment\n */\nexport function incrementString(str) {\n var matches = str.match(/-\\s(\\d+$)/);\n if (matches) {\n // get the number\n var current = parseInt(matches[1], 10);\n // replace `- current` with `- current + 1`\n var next = current + 1;\n str = str.replace(\"- \" + current, \"- \" + next);\n }\n else {\n str = str + \" - 1\";\n }\n return str;\n}\n//# sourceMappingURL=increment-string.js.map","/* tslint:disable no-console */\nimport { __spreadArrays } from \"tslib\";\n/**\n * Enum for Logger Levels\n */\nexport var Level;\n(function (Level) {\n Level[Level[\"all\"] = 0] = \"all\";\n Level[Level[\"debug\"] = 1] = \"debug\";\n Level[Level[\"info\"] = 2] = \"info\";\n Level[Level[\"warn\"] = 3] = \"warn\";\n Level[Level[\"error\"] = 4] = \"error\";\n Level[Level[\"off\"] = 5] = \"off\";\n})(Level || (Level = {}));\n/**\n * ```js\n * import { Logger, Level } from '@esri/hub-common'\n * ```\n * Functions share the console interface\n * ```js\n * Logger.log('My Message');\n * Logger.warn('Watch out!', { threat: 'Charizard' });\n * // etc, etc\n * ```\n * Available logging levels are specified in the Level enum. The hierarchy is as follows:\n * ```\n * off > error > warn > info > debug > all\n * ```\n * Logger only sends messages whose level is greater than or equal to the global log level\n * ```js\n * // Global level is 'warn'\n * Logger.info('This message won't log');\n * Logger.error('But this one will!');\n * ```\n * Logger's default level is 'off', so set desired level before use\n * ```js\n * Logger.setLogLevel(Level.all);\n * ```\n */\nvar Logger = /** @class */ (function () {\n function Logger() {\n }\n /**\n * Sets the global log level\n * @param {Level} level\n */\n Logger.setLogLevel = function (level) {\n this.logLevel = level;\n };\n /**\n * Logs to debug if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.log = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.debug)) {\n console.log.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to debug if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.debug = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.debug)) {\n console.debug.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to info if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.info = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.info)) {\n console.info.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to warn if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.warn = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.warn)) {\n console.warn.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to error if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.error = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.error)) {\n console.error.apply(console, __spreadArrays([message], objects));\n }\n };\n Logger.isLevelPermitted = function (level) {\n return this.logLevel <= level;\n };\n Logger.logLevel = Level.off;\n return Logger;\n}());\nexport { Logger };\n//# sourceMappingURL=logger.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Determines if a given IGroup is an update group\n * @param {IGroup} group The group to evaluate\n */\nexport function isUpdateGroup(group) {\n return group.capabilities.includes(\"updateitemcontrol\");\n}\n//# sourceMappingURL=is-update-group.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Runs the given task and returns a IRevertableTaskResult\n * @param {Function} task A task method to run\n * @param {Function} revert A method to revert the task\n * @returns {Promise<IRevertableTaskResult>}\n */\nexport var runRevertableTask = function (task, revert) {\n return task()\n .then(function (results) {\n return {\n status: \"fullfilled\",\n results: results,\n revert: revert\n };\n })\n .catch(function (error) {\n return { status: \"rejected\", error: error };\n });\n};\n/**\n * Processes an Array of Promise<IRevertableTaskResult>. When all IRevertableTaskResult\n * are IRevertableTaskSuccess, it resolves an Array of all result values. If any\n * IRevertableTaskResult are IRevertableTaskFailed, it reverts all IRevertableTaskSuccess\n * and rejects with the first IRevertableTaskFailed error\n * @param revertableTasks\n * @returns {Promise<any[]>}\n */\nexport var processRevertableTasks = function (revertableTasks) {\n return Promise.all(revertableTasks).then(function (results) {\n var isFullfilled = function (result) {\n return result.status === \"fullfilled\";\n };\n var successfulTasks = results.filter(isFullfilled);\n var failedTasks = results.filter(function (result) { return !isFullfilled(result); });\n if (failedTasks.length) {\n var reverts = successfulTasks.map(function (task) { return task.revert(); });\n // fire & forget\n /* tslint:disable no-empty */\n Promise.all(reverts).catch(function () { });\n /* tslint:enable no-empty */\n throw failedTasks[0].error;\n }\n var returnResults = successfulTasks.map(function (result) { return result.results; });\n return returnResults;\n });\n};\n//# sourceMappingURL=revertable-tasks.js.map","import { includes } from \"../utils\";\n/**\n * Checks for fundamental privilege required by all access checks\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function hasBasePriv(user) {\n var _a = user.privileges, privileges = _a === void 0 ? [] : _a;\n return includes(privileges, \"portal:user:createItem\");\n}\n//# sourceMappingURL=has-base-priv.js.map","import { getProp } from \"../objects\";\nimport { findBy } from \"../util\";\nimport { hasBasePriv } from \"./has-base-priv\";\n/**\n * Checks if user has access to edit an event in Hub\n * @param {IEventModel} model consolidated event model as consumed by Hub, contains the event feature, related initiative model, and attendees group\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditEvent(model, user) {\n var res = false;\n if (hasBasePriv(user)) {\n var coreTeamId = getProp(model, \"initiative.item.properties.collaborationGroupId\");\n var _a = user.groups, groups = _a === void 0 ? [] : _a;\n res = !!coreTeamId && !!findBy(groups, \"id\", coreTeamId);\n }\n return res;\n}\n//# sourceMappingURL=can-edit-event.js.map","import { __spreadArrays } from \"tslib\";\nimport { isUpdateGroup, includes } from \"../utils\";\nimport { getProp } from \"../objects\";\nimport { hasBasePriv } from \"./has-base-priv\";\n/**\n * Checks if user has access to edit an item in Hub\n * @param {IItem} item\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditItem(item, user) {\n var res = false;\n var itemControls = [\"admin\", \"update\"];\n var itemControl = item.itemControl, owner = item.owner, itemOrgId = item.orgId;\n var roleId = user.roleId, role = user.role, username = user.username, userGroups = user.groups, userOrgId = user.orgId;\n var hasItemControl = includes(itemControls, itemControl);\n var isOwner = !!owner && owner === username;\n var isOrgItem = !!itemOrgId && itemOrgId === userOrgId;\n var isItemOrgAdmin = !!isOrgItem && !roleId && role === \"org_admin\";\n var hasPlatformControl = hasItemControl || isOwner || isItemOrgAdmin;\n var hasPriv = hasBasePriv(user);\n if (hasPriv && hasPlatformControl) {\n res = true;\n }\n else if (hasPriv) {\n var itemGroups_1 = __spreadArrays((getProp(item, \"groupIds\") || []), [\n getProp(item, \"properties.collaborationGroupId\")\n ]);\n var isGroupEditable = function (group) {\n return isUpdateGroup(group) && includes(itemGroups_1, group.id);\n };\n res = userGroups.some(isGroupEditable);\n }\n return res;\n}\n//# sourceMappingURL=can-edit-item.js.map","import { includes } from \"../utils\";\nimport { getProp } from \"../objects\";\nimport { hasBasePriv } from \"./has-base-priv\";\nimport { canEditItem } from \"./can-edit-item\";\nexport var REQUIRED_PRIVS = [\n \"portal:user:createGroup\",\n \"portal:user:createItem\",\n \"portal:user:shareToGroup\",\n \"portal:user:viewOrgGroups\",\n \"portal:user:viewOrgItems\"\n];\n/**\n * Checks if user has access to content library in Hub\n * In Hub Home context, user access requires additional privileges\n * In initiative context, check is delegated to canEditItem for the initiative site item\n * @param {IItem} item\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditSiteContent(item, user) {\n var res = false;\n var isDefaultHubHome = getProp(item, \"properties.isDefaultHubHome\");\n var hasPriv = hasBasePriv(user);\n if (!isDefaultHubHome && hasPriv) {\n res = canEditItem(item, user);\n }\n else if (hasPriv) {\n var userOrgId = user.orgId;\n var itemOrgId = item.orgId;\n var sameOrg = !!userOrgId && userOrgId === itemOrgId;\n if (sameOrg) {\n var privileges_1 = user.privileges || [];\n res = REQUIRED_PRIVS.every(function (privilege) { return includes(privileges_1, privilege); });\n }\n }\n return res;\n}\n//# sourceMappingURL=can-edit-site-content.js.map","import { getProp } from \"../objects\";\nimport { hasBasePriv } from \"./has-base-priv\";\nimport { canEditItem } from \"./can-edit-item\";\n/**\n * Checks if user has access to edit site in Hub\n * Currently, Hub Home sites are not editable\n * In initiative context, check is delegated to canEditItem for the initiative site item\n * @param {IItem} model\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditSite(model, user) {\n var res = false;\n var isDefaultHubHome = getProp(model, \"properties.isDefaultHubHome\");\n if (!isDefaultHubHome && hasBasePriv(user)) {\n res = canEditItem(model, user);\n }\n return res;\n}\n//# sourceMappingURL=can-edit-site.js.map","/**\n * @private\n */\nexport function buildUrl(params) {\n var host = params.host, path = params.path, query = params.query;\n var baseUrl = host.endsWith(\"/\") ? host : host + \"/\";\n var url = new URL(path, baseUrl);\n url.search = buildQueryString(query);\n return url.toString();\n}\nfunction buildQueryString(params) {\n if (params === void 0) { params = {}; }\n var queryParams = Object.keys(params)\n .filter(function (key) {\n return params[key] !== undefined;\n })\n .reduce(function (acc, key) {\n acc[key] = params[key];\n return acc;\n }, {});\n return new URLSearchParams(queryParams).toString();\n}\n//# sourceMappingURL=build-url.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Checks parameters to see if we should use FormData to send the request\n * @param params The object whose keys will be encoded.\n * @return A boolean indicating if FormData will be required.\n */\nexport function requiresFormData(params) {\n return Object.keys(params).some(function (key) {\n var value = params[key];\n if (!value) {\n return false;\n }\n if (value && value.toParam) {\n value = value.toParam();\n }\n var type = value.constructor.name;\n switch (type) {\n case \"Array\":\n return false;\n case \"Object\":\n return false;\n case \"Date\":\n return false;\n case \"Function\":\n return false;\n case \"Boolean\":\n return false;\n case \"String\":\n return false;\n case \"Number\":\n return false;\n default:\n return true;\n }\n });\n}\n/**\n * Converts parameters to the proper representation to send to the ArcGIS REST API.\n * @param params The object whose keys will be encoded.\n * @return A new object with properly encoded values.\n */\nexport function processParams(params) {\n var newParams = {};\n Object.keys(params).forEach(function (key) {\n var _a, _b;\n var param = params[key];\n if (param && param.toParam) {\n param = param.toParam();\n }\n if (!param &&\n param !== 0 &&\n typeof param !== \"boolean\" &&\n typeof param !== \"string\") {\n return;\n }\n var type = param.constructor.name;\n var value;\n // properly encodes objects, arrays and dates for arcgis.com and other services.\n // ported from https://github.com/Esri/esri-leaflet/blob/master/src/Request.js#L22-L30\n // also see https://github.com/Esri/arcgis-rest-js/issues/18:\n // null, undefined, function are excluded. If you want to send an empty key you need to send an empty string \"\".\n switch (type) {\n case \"Array\":\n // Based on the first element of the array, classify array as an array of arrays, an array of objects\n // to be stringified, or an array of non-objects to be comma-separated\n // eslint-disable-next-line no-case-declarations\n var firstElementType = (_b = (_a = param[0]) === null || _a === void 0 ? void 0 : _a.constructor) === null || _b === void 0 ? void 0 : _b.name;\n value =\n firstElementType === \"Array\" ? param : // pass thru array of arrays\n firstElementType === \"Object\" ? JSON.stringify(param) : // stringify array of objects\n param.join(\",\"); // join other types of array elements\n break;\n case \"Object\":\n value = JSON.stringify(param);\n break;\n case \"Date\":\n value = param.valueOf();\n break;\n case \"Function\":\n value = null;\n break;\n case \"Boolean\":\n value = param + \"\";\n break;\n default:\n value = param;\n break;\n }\n if (value || value === 0 || typeof value === \"string\" || Array.isArray(value)) {\n newParams[key] = value;\n }\n });\n return newParams;\n}\n//# sourceMappingURL=process-params.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { processParams } from \"./process-params\";\n/**\n * Encodes keys and parameters for use in a URL's query string.\n *\n * @param key Parameter's key\n * @param value Parameter's value\n * @returns Query string with key and value pairs separated by \"&\"\n */\nexport function encodeParam(key, value) {\n // For array of arrays, repeat key=value for each element of containing array\n if (Array.isArray(value) && value[0] && Array.isArray(value[0])) {\n return value.map(function (arrayElem) { return encodeParam(key, arrayElem); }).join(\"&\");\n }\n return encodeURIComponent(key) + \"=\" + encodeURIComponent(value);\n}\n/**\n * Encodes the passed object as a query string.\n *\n * @param params An object to be encoded.\n * @returns An encoded query string.\n */\nexport function encodeQueryString(params) {\n var newParams = processParams(params);\n return Object.keys(newParams)\n .map(function (key) {\n return encodeParam(key, newParams[key]);\n })\n .join(\"&\");\n}\n//# sourceMappingURL=encode-query-string.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { processParams, requiresFormData } from \"./process-params\";\nimport { encodeQueryString } from \"./encode-query-string\";\n/**\n * Encodes parameters in a [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData) object in browsers or in a [FormData](https://github.com/form-data/form-data) in Node.js\n *\n * @param params An object to be encoded.\n * @returns The complete [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData) object.\n */\nexport function encodeFormData(params, forceFormData) {\n // see https://github.com/Esri/arcgis-rest-js/issues/499 for more info.\n var useFormData = requiresFormData(params) || forceFormData;\n var newParams = processParams(params);\n if (useFormData) {\n var formData_1 = new FormData();\n Object.keys(newParams).forEach(function (key) {\n if (typeof Blob !== \"undefined\" && newParams[key] instanceof Blob) {\n /* To name the Blob:\n 1. look to an alternate request parameter called 'fileName'\n 2. see if 'name' has been tacked onto the Blob manually\n 3. if all else fails, use the request parameter\n */\n var filename = newParams[\"fileName\"] || newParams[key].name || key;\n formData_1.append(key, newParams[key], filename);\n }\n else {\n formData_1.append(key, newParams[key]);\n }\n });\n return formData_1;\n }\n else {\n return encodeQueryString(params);\n }\n}\n//# sourceMappingURL=encode-form-data.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n// TypeScript 2.1 no longer allows you to extend built in types. See https://github.com/Microsoft/TypeScript/issues/12790#issuecomment-265981442\n// and https://github.com/Microsoft/TypeScript-wiki/blob/master/Breaking-Changes.md#extending-built-ins-like-error-array-and-map-may-no-longer-work\n//\n// This code is from MDN https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error#Custom_Error_Types.\nvar ArcGISRequestError = /** @class */ (function () {\n /**\n * Create a new `ArcGISRequestError` object.\n *\n * @param message - The error message from the API\n * @param code - The error code from the API\n * @param response - The original response from the API that caused the error\n * @param url - The original url of the request\n * @param options - The original options and parameters of the request\n */\n function ArcGISRequestError(message, code, response, url, options) {\n message = message || \"UNKNOWN_ERROR\";\n code = code || \"UNKNOWN_ERROR_CODE\";\n this.name = \"ArcGISRequestError\";\n this.message =\n code === \"UNKNOWN_ERROR_CODE\" ? message : code + \": \" + message;\n this.originalMessage = message;\n this.code = code;\n this.response = response;\n this.url = url;\n this.options = options;\n }\n return ArcGISRequestError;\n}());\nexport { ArcGISRequestError };\nArcGISRequestError.prototype = Object.create(Error.prototype);\nArcGISRequestError.prototype.constructor = ArcGISRequestError;\n//# sourceMappingURL=ArcGISRequestError.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Method used internally to surface messages to developers.\n */\nexport function warn(message) {\n if (console && console.warn) {\n console.warn.apply(console, [message]);\n }\n}\n//# sourceMappingURL=warn.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign, __extends } from \"tslib\";\nimport { encodeFormData } from \"./utils/encode-form-data\";\nimport { encodeQueryString } from \"./utils/encode-query-string\";\nimport { requiresFormData } from \"./utils/process-params\";\nimport { ArcGISRequestError } from \"./utils/ArcGISRequestError\";\nimport { warn } from \"./utils/warn\";\nexport var NODEJS_DEFAULT_REFERER_HEADER = \"@esri/arcgis-rest-js\";\nvar DEFAULT_ARCGIS_REQUEST_OPTIONS = {\n httpMethod: \"POST\",\n params: {\n f: \"json\",\n },\n};\n/**\n * Sets the default options that will be passed in **all requests across all `@esri/arcgis-rest-js` modules**.\n *\n *\n * ```js\n * import { setDefaultRequestOptions } from \"@esri/arcgis-rest-request\";\n * setDefaultRequestOptions({\n * authentication: userSession // all requests will use this session by default\n * })\n * ```\n * You should **never** set a default `authentication` when you are in a server side environment where you may be handling requests for many different authenticated users.\n *\n * @param options The default options to pass with every request. Existing default will be overwritten.\n * @param hideWarnings Silence warnings about setting default `authentication` in shared environments.\n */\nexport function setDefaultRequestOptions(options, hideWarnings) {\n if (options.authentication && !hideWarnings) {\n warn(\"You should not set `authentication` as a default in a shared environment such as a web server which will process multiple users requests. You can call `setDefaultRequestOptions` with `true` as a second argument to disable this warning.\");\n }\n DEFAULT_ARCGIS_REQUEST_OPTIONS = options;\n}\nvar ArcGISAuthError = /** @class */ (function (_super) {\n __extends(ArcGISAuthError, _super);\n /**\n * Create a new `ArcGISAuthError` object.\n *\n * @param message - The error message from the API\n * @param code - The error code from the API\n * @param response - The original response from the API that caused the error\n * @param url - The original url of the request\n * @param options - The original options of the request\n */\n function ArcGISAuthError(message, code, response, url, options) {\n if (message === void 0) { message = \"AUTHENTICATION_ERROR\"; }\n if (code === void 0) { code = \"AUTHENTICATION_ERROR_CODE\"; }\n var _this = _super.call(this, message, code, response, url, options) || this;\n _this.name = \"ArcGISAuthError\";\n _this.message =\n code === \"AUTHENTICATION_ERROR_CODE\" ? message : code + \": \" + message;\n return _this;\n }\n ArcGISAuthError.prototype.retry = function (getSession, retryLimit) {\n var _this = this;\n if (retryLimit === void 0) { retryLimit = 3; }\n var tries = 0;\n var retryRequest = function (resolve, reject) {\n getSession(_this.url, _this.options)\n .then(function (session) {\n var newOptions = __assign(__assign({}, _this.options), { authentication: session });\n tries = tries + 1;\n return request(_this.url, newOptions);\n })\n .then(function (response) {\n resolve(response);\n })\n .catch(function (e) {\n if (e.name === \"ArcGISAuthError\" && tries < retryLimit) {\n retryRequest(resolve, reject);\n }\n else if (e.name === \"ArcGISAuthError\" && tries >= retryLimit) {\n reject(_this);\n }\n else {\n reject(e);\n }\n });\n };\n return new Promise(function (resolve, reject) {\n retryRequest(resolve, reject);\n });\n };\n return ArcGISAuthError;\n}(ArcGISRequestError));\nexport { ArcGISAuthError };\n/**\n * Checks for errors in a JSON response from the ArcGIS REST API. If there are no errors, it will return the `data` passed in. If there is an error, it will throw an `ArcGISRequestError` or `ArcGISAuthError`.\n *\n * @param data The response JSON to check for errors.\n * @param url The url of the original request\n * @param params The parameters of the original request\n * @param options The options of the original request\n * @returns The data that was passed in the `data` parameter\n */\nexport function checkForErrors(response, url, params, options, originalAuthError) {\n // this is an error message from billing.arcgis.com backend\n if (response.code >= 400) {\n var message = response.message, code = response.code;\n throw new ArcGISRequestError(message, code, response, url, options);\n }\n // error from ArcGIS Online or an ArcGIS Portal or server instance.\n if (response.error) {\n var _a = response.error, message = _a.message, code = _a.code, messageCode = _a.messageCode;\n var errorCode = messageCode || code || \"UNKNOWN_ERROR_CODE\";\n if (code === 498 ||\n code === 499 ||\n messageCode === \"GWM_0003\" ||\n (code === 400 && message === \"Unable to generate token.\")) {\n if (originalAuthError) {\n throw originalAuthError;\n }\n else {\n throw new ArcGISAuthError(message, errorCode, response, url, options);\n }\n }\n throw new ArcGISRequestError(message, errorCode, response, url, options);\n }\n // error from a status check\n if (response.status === \"failed\" || response.status === \"failure\") {\n var message = void 0;\n var code = \"UNKNOWN_ERROR_CODE\";\n try {\n message = JSON.parse(response.statusMessage).message;\n code = JSON.parse(response.statusMessage).code;\n }\n catch (e) {\n message = response.statusMessage || response.message;\n }\n throw new ArcGISRequestError(message, code, response, url, options);\n }\n return response;\n}\n/**\n * ```js\n * import { request } from '@esri/arcgis-rest-request';\n * //\n * request('https://www.arcgis.com/sharing/rest')\n * .then(response) // response.currentVersion === 5.2\n * //\n * request('https://www.arcgis.com/sharing/rest', {\n * httpMethod: \"GET\"\n * })\n * //\n * request('https://www.arcgis.com/sharing/rest/search', {\n * params: { q: 'parks' }\n * })\n * .then(response) // response.total => 78379\n * ```\n * Generic method for making HTTP requests to ArcGIS REST API endpoints.\n *\n * @param url - The URL of the ArcGIS REST API endpoint.\n * @param requestOptions - Options for the request, including parameters relevant to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function request(url, requestOptions) {\n if (requestOptions === void 0) { requestOptions = { params: { f: \"json\" } }; }\n var options = __assign(__assign(__assign({ httpMethod: \"POST\" }, DEFAULT_ARCGIS_REQUEST_OPTIONS), requestOptions), {\n params: __assign(__assign({}, DEFAULT_ARCGIS_REQUEST_OPTIONS.params), requestOptions.params),\n headers: __assign(__assign({}, DEFAULT_ARCGIS_REQUEST_OPTIONS.headers), requestOptions.headers),\n });\n var missingGlobals = [];\n var recommendedPackages = [];\n // don't check for a global fetch if a custom implementation was passed through\n if (!options.fetch && typeof fetch !== \"undefined\") {\n options.fetch = fetch.bind(Function(\"return this\")());\n }\n else {\n missingGlobals.push(\"`fetch`\");\n recommendedPackages.push(\"`node-fetch`\");\n }\n if (typeof Promise === \"undefined\") {\n missingGlobals.push(\"`Promise`\");\n recommendedPackages.push(\"`es6-promise`\");\n }\n if (typeof FormData === \"undefined\") {\n missingGlobals.push(\"`FormData`\");\n recommendedPackages.push(\"`isomorphic-form-data`\");\n }\n if (!options.fetch ||\n typeof Promise === \"undefined\" ||\n typeof FormData === \"undefined\") {\n throw new Error(\"`arcgis-rest-request` requires a `fetch` implementation and global variables for `Promise` and `FormData` to be present in the global scope. You are missing \" + missingGlobals.join(\", \") + \". We recommend installing the \" + recommendedPackages.join(\", \") + \" modules at the root of your application to add these to the global scope. See https://bit.ly/2KNwWaJ for more info.\");\n }\n var httpMethod = options.httpMethod, authentication = options.authentication, rawResponse = options.rawResponse;\n var params = __assign({ f: \"json\" }, options.params);\n var originalAuthError = null;\n var fetchOptions = {\n method: httpMethod,\n /* ensures behavior mimics XMLHttpRequest.\n needed to support sending IWA cookies */\n credentials: options.credentials || \"same-origin\",\n };\n // the /oauth2/platformSelf route will add X-Esri-Auth-Client-Id header\n // and that request needs to send cookies cross domain\n // so we need to set the credentials to \"include\"\n if (options.headers &&\n options.headers[\"X-Esri-Auth-Client-Id\"] &&\n url.indexOf(\"/oauth2/platformSelf\") > -1) {\n fetchOptions.credentials = \"include\";\n }\n return (authentication\n ? authentication.getToken(url, { fetch: options.fetch }).catch(function (err) {\n /**\n * append original request url and requestOptions\n * to the error thrown by getToken()\n * to assist with retrying\n */\n err.url = url;\n err.options = options;\n /**\n * if an attempt is made to talk to an unfederated server\n * first try the request anonymously. if a 'token required'\n * error is thrown, throw the UNFEDERATED error then.\n */\n originalAuthError = err;\n return Promise.resolve(\"\");\n })\n : Promise.resolve(\"\"))\n .then(function (token) {\n if (token.length) {\n params.token = token;\n }\n if (authentication && authentication.getDomainCredentials) {\n fetchOptions.credentials = authentication.getDomainCredentials(url);\n }\n // Custom headers to add to request. IRequestOptions.headers with merge over requestHeaders.\n var requestHeaders = {};\n if (fetchOptions.method === \"GET\") {\n // Prevents token from being passed in query params when hideToken option is used.\n /* istanbul ignore if - window is always defined in a browser. Test case is covered by Jasmine in node test */\n if (params.token &&\n options.hideToken &&\n // Sharing API does not support preflight check required by modern browsers https://developer.mozilla.org/en-US/docs/Glossary/Preflight_request\n typeof window === \"undefined\") {\n requestHeaders[\"X-Esri-Authorization\"] = \"Bearer \" + params.token;\n delete params.token;\n }\n // encode the parameters into the query string\n var queryParams = encodeQueryString(params);\n // dont append a '?' unless parameters are actually present\n var urlWithQueryString = queryParams === \"\" ? url : url + \"?\" + encodeQueryString(params);\n if (\n // This would exceed the maximum length for URLs specified by the consumer and requires POST\n (options.maxUrlLength &&\n urlWithQueryString.length > options.maxUrlLength) ||\n // Or if the customer requires the token to be hidden and it has not already been hidden in the header (for browsers)\n (params.token && options.hideToken)) {\n // the consumer specified a maximum length for URLs\n // and this would exceed it, so use post instead\n fetchOptions.method = \"POST\";\n // If the token was already added as a Auth header, add the token back to body with other params instead of header\n if (token.length && options.hideToken) {\n params.token = token;\n // Remove existing header that was added before url query length was checked\n delete requestHeaders[\"X-Esri-Authorization\"];\n }\n }\n else {\n // just use GET\n url = urlWithQueryString;\n }\n }\n /* updateResources currently requires FormData even when the input parameters dont warrant it.\n https://developers.arcgis.com/rest/users-groups-and-items/update-resources.htm\n see https://github.com/Esri/arcgis-rest-js/pull/500 for more info. */\n var forceFormData = new RegExp(\"/items/.+/updateResources\").test(url);\n if (fetchOptions.method === \"POST\") {\n fetchOptions.body = encodeFormData(params, forceFormData);\n }\n // Mixin headers from request options\n fetchOptions.headers = __assign(__assign({}, requestHeaders), options.headers);\n /* istanbul ignore next - karma reports coverage on browser tests only */\n if (typeof window === \"undefined\" && !fetchOptions.headers.referer) {\n fetchOptions.headers.referer = NODEJS_DEFAULT_REFERER_HEADER;\n }\n /* istanbul ignore else blob responses are difficult to make cross platform we will just have to trust the isomorphic fetch will do its job */\n if (!requiresFormData(params) && !forceFormData) {\n fetchOptions.headers[\"Content-Type\"] =\n \"application/x-www-form-urlencoded\";\n }\n return options.fetch(url, fetchOptions);\n })\n .then(function (response) {\n if (!response.ok) {\n // server responded w/ an actual error (404, 500, etc)\n var status_1 = response.status, statusText = response.statusText;\n throw new ArcGISRequestError(statusText, \"HTTP \" + status_1, response, url, options);\n }\n if (rawResponse) {\n return response;\n }\n switch (params.f) {\n case \"json\":\n return response.json();\n case \"geojson\":\n return response.json();\n case \"html\":\n return response.text();\n case \"text\":\n return response.text();\n /* istanbul ignore next blob responses are difficult to make cross platform we will just have to trust that isomorphic fetch will do its job */\n default:\n return response.blob();\n }\n })\n .then(function (data) {\n if ((params.f === \"json\" || params.f === \"geojson\") && !rawResponse) {\n var response = checkForErrors(data, url, params, options, originalAuthError);\n if (originalAuthError) {\n /* If the request was made to an unfederated service that\n didn't require authentication, add the base url and a dummy token\n to the list of trusted servers to avoid another federation check\n in the event of a repeat request */\n var truncatedUrl = url\n .toLowerCase()\n .split(/\\/rest(\\/admin)?\\/services\\//)[0];\n options.authentication.federatedServers[truncatedUrl] = {\n token: [],\n // default to 24 hours\n expires: new Date(Date.now() + 86400 * 1000),\n };\n originalAuthError = null;\n }\n return response;\n }\n else {\n return data;\n }\n });\n}\n//# sourceMappingURL=request.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\n/**\n * Helper for methods with lots of first order request options to pass through as request parameters.\n */\nexport function appendCustomParams(customOptions, keys, baseOptions) {\n var requestOptionsKeys = [\n \"params\",\n \"httpMethod\",\n \"rawResponse\",\n \"authentication\",\n \"portal\",\n \"fetch\",\n \"maxUrlLength\",\n \"headers\"\n ];\n var options = __assign(__assign({ params: {} }, baseOptions), customOptions);\n // merge all keys in customOptions into options.params\n options.params = keys.reduce(function (value, key) {\n if (customOptions[key] || typeof customOptions[key] === \"boolean\") {\n value[key] = customOptions[key];\n }\n return value;\n }, options.params);\n // now remove all properties in options that don't exist in IRequestOptions\n return requestOptionsKeys.reduce(function (value, key) {\n if (options[key]) {\n value[key] = options[key];\n }\n return value;\n }, {});\n}\n//# sourceMappingURL=append-custom-params.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Helper method to ensure that user supplied urls don't include whitespace or a trailing slash.\n */\nexport function cleanUrl(url) {\n // Guard so we don't try to trim something that's not a string\n if (typeof url !== \"string\") {\n return url;\n }\n // trim leading and trailing spaces, but not spaces inside the url\n url = url.trim();\n // remove the trailing slash to the url if one was included\n if (url[url.length - 1] === \"/\") {\n url = url.slice(0, -1);\n }\n return url;\n}\n//# sourceMappingURL=clean-url.js.map","/* Copyright (c) 2017-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nexport function decodeParam(param) {\n var _a = param.split(\"=\"), key = _a[0], value = _a[1];\n return { key: decodeURIComponent(key), value: decodeURIComponent(value) };\n}\n/**\n * Decodes the passed query string as an object.\n *\n * @param query A string to be decoded.\n * @returns A decoded query param object.\n */\nexport function decodeQueryString(query) {\n return query\n .replace(/^#/, \"\")\n .split(\"&\")\n .reduce(function (acc, entry) {\n var _a = decodeParam(entry), key = _a.key, value = _a.value;\n acc[key] = value;\n return acc;\n }, {});\n}\n//# sourceMappingURL=decode-query-string.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { cleanUrl } from \"@esri/arcgis-rest-request\";\n/**\n * Helper that returns the appropriate portal url for a given request. `requestOptions.portal` is given\n * precedence over `authentication.portal`. If neither `portal` nor `authentication` is present,\n * `www.arcgis.com/sharing/rest` is returned.\n *\n * @param requestOptions - Request options that may have authentication manager\n * @returns Portal url to be used in API requests\n */\nexport function getPortalUrl(requestOptions) {\n if (requestOptions === void 0) { requestOptions = {}; }\n // use portal in options if specified\n if (requestOptions.portal) {\n return cleanUrl(requestOptions.portal);\n }\n // if auth was passed, use that portal\n if (requestOptions.authentication) {\n // the portal url is already scrubbed in the auth package\n return requestOptions.authentication.portal;\n }\n // default to arcgis.com\n return \"https://www.arcgis.com/sharing/rest\";\n}\n//# sourceMappingURL=get-portal-url.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Serialize an item and its data into a json format accepted by the Portal API for create and update operations\n *\n * @param item Item to be serialized\n * @returns a formatted json object to be sent to Portal\n */\nexport function serializeItem(item) {\n // create a clone so we're not messing with the original\n var clone = JSON.parse(JSON.stringify(item));\n // binary data needs POSTed as a `file`\n // JSON object literals should be passed as `text`.\n if (clone.data) {\n (typeof Blob !== \"undefined\" && item.data instanceof Blob) ||\n // Node.js doesn't implement Blob\n item.data.constructor.name === \"ReadStream\"\n ? (clone.file = item.data)\n : (clone.text = item.data);\n delete clone.data;\n }\n return clone;\n}\n/**\n * `requestOptions.owner` is given priority, `requestOptions.item.owner` will be checked next. If neither are present, `authentication.getUserName()` will be used instead.\n */\nexport function determineOwner(requestOptions) {\n if (requestOptions.owner) {\n return Promise.resolve(requestOptions.owner);\n }\n else if (requestOptions.item && requestOptions.item.owner) {\n return Promise.resolve(requestOptions.item.owner);\n }\n else if (requestOptions.authentication &&\n requestOptions.authentication.getUsername) {\n return requestOptions.authentication.getUsername();\n }\n else {\n return Promise.reject(new Error(\"Could not determine the owner of this item. Pass the `owner`, `item.owner`, or `authentication` option.\"));\n }\n}\n//# sourceMappingURL=helpers.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { serializeItem, determineOwner } from \"./helpers\";\n/**\n * ```js\n * import { updateItem } from \"@esri/arcgis-rest-portal\";\n * //\n * updateItem({\n * item: {\n * id: \"3ef\",\n * description: \"A three hour tour\"\n * },\n * authentication\n * })\n * .then(response)\n * ```\n * Update an Item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-item.htm) for more information.\n *\n * @param requestOptions - Options for the request.\n * @returns A Promise that updates an item.\n */\nexport function updateItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = requestOptions.folderId\n ? getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/\" + requestOptions.folderId + \"/items/\" + requestOptions.item.id + \"/update\"\n : getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.item.id + \"/update\";\n // serialize the item into something Portal will accept\n requestOptions.params = __assign(__assign({}, requestOptions.params), serializeItem(requestOptions.item));\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { updateItemInfo } from \"@esri/arcgis-rest-portal\";\n * //\n * updateItemInfo({\n * id: '3ef',\n * file: file,\n * authentication\n * })\n * .then(response)\n * ```\n * Update an info file associated with an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-info.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that updates an item info file.\n */\nexport function updateItemInfo(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/updateinfo\";\n // mix in user supplied params\n requestOptions.params = __assign({ folderName: requestOptions.folderName, file: requestOptions.file }, requestOptions.params);\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { updateItemResource } from \"@esri/arcgis-rest-portal\";\n * //\n * updateItemResource({\n * id: '3ef',\n * resource: file,\n * name: 'bigkahuna.jpg',\n * authentication\n * })\n * .then(response)\n * ```\n * Update a resource associated with an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-resources.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that updates an item resource.\n */\nexport function updateItemResource(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/updateResources\";\n // mix in user supplied params\n requestOptions.params = __assign({ file: requestOptions.resource, fileName: requestOptions.name, resourcesPrefix: requestOptions.prefix, text: requestOptions.content }, requestOptions.params);\n // only override the access specified previously if 'private' is passed explicitly\n if (typeof requestOptions.private !== \"undefined\") {\n requestOptions.params.access = requestOptions.private\n ? \"private\"\n : \"inherit\";\n }\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { moveItem } from \"@esri/arcgis-rest-portal\";\n * //\n * moveItem({\n * itemId: \"3ef\",\n * folderId: \"7c5\",\n * authentication: userSession\n * })\n * ```\n * Move an item to a folder. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/move-item.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that resolves with owner and folder details once the move has been completed\n */\nexport function moveItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.itemId + \"/move\";\n var folderId = requestOptions.folderId;\n if (!folderId) {\n folderId = \"/\";\n }\n requestOptions.params = __assign({ folder: folderId }, requestOptions.params);\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=update.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { determineOwner } from \"./helpers\";\nimport { updateItem } from \"./update\";\n/**\n * ```js\n * import { addItemData } from \"@esri/arcgis-rest-portal\";\n * //\n * addItemData({\n * id: '3ef',\n * data: file,\n * authentication\n * })\n * .then(response)\n * ```\n * Send a file or blob to an item to be stored as the `/data` resource. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-item.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with an object reporting\n * success/failure and echoing the item id.\n */\nexport function addItemData(requestOptions) {\n var options = __assign({ item: {\n id: requestOptions.id,\n data: requestOptions.data\n } }, requestOptions);\n delete options.id;\n delete options.data;\n return updateItem(options);\n}\n/**\n * ```js\n * import { addItemRelationship } from \"@esri/arcgis-rest-portal\";\n * //\n * addItemRelationship({\n * originItemId: '3ef',\n * destinationItemId: 'ae7',\n * relationshipType: 'Service2Layer',\n * authentication\n * })\n * .then(response)\n * ```\n * Add a relationship between two items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/add-relationship.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to add item resources.\n */\nexport function addItemRelationship(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/addRelationship\";\n var options = appendCustomParams(requestOptions, [\"originItemId\", \"destinationItemId\", \"relationshipType\"], { params: __assign({}, requestOptions.params) });\n return request(url, options);\n });\n}\n/**\n * ```js\n * import { addItemResource } from \"@esri/arcgis-rest-portal\";\n * //\n * // Add a file resource\n * addItemResource({\n * id: '3ef',\n * resource: file,\n * name: 'bigkahuna.jpg',\n * authentication\n * })\n * .then(response)\n * //\n * // Add a text resource\n * addItemResource({\n * id: '4fg',\n * content: \"Text content\",\n * name: 'bigkahuna.txt',\n * authentication\n * })\n * .then(response)\n * ```\n * Add a resource associated with an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/add-resources.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to add item resources.\n */\nexport function addItemResource(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/addResources\";\n requestOptions.params = __assign({ file: requestOptions.resource, fileName: requestOptions.name, resourcesPrefix: requestOptions.prefix, text: requestOptions.content, access: requestOptions.private ? \"private\" : \"inherit\" }, requestOptions.params);\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=add.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { scrubControlChars } from '../util/scrub-control-chars';\nimport { determineOwner } from \"./helpers\";\n/**\n * ```\n * import { getItem } from \"@esri/arcgis-rest-portal\";\n * //\n * getItem(\"ae7\")\n * .then(response);\n * // or\n * getItem(\"ae7\", { authentication })\n * .then(response)\n * ```\n * Get an item by id. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/item.htm) for more information.\n *\n * @param id - Item Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function getItem(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions);\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * Get the fully qualified base URL to the REST end point for an item.\n * @param id Item Id\n * @param portalUrlOrRequestOptions a portal URL or request options\n * @returns URL to the item's REST end point, defaults to `https://www.arcgis.com/sharing/rest/content/items/{id}`\n */\nexport var getItemBaseUrl = function (id, portalUrlOrRequestOptions) {\n var portalUrl = typeof portalUrlOrRequestOptions === \"string\"\n ? portalUrlOrRequestOptions\n : getPortalUrl(portalUrlOrRequestOptions);\n return portalUrl + \"/content/items/\" + id;\n};\n/**\n * ```\n * import { getItemData } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemData(\"ae7\")\n * .then(response)\n * // or\n * getItemData(\"ae7\", { authentication })\n * .then(response)\n * ```\n * Get the /data for an item. If no data exists, returns `undefined`. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/item-data.htm) for more information.\n * @param id - Item Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the json data for the item.\n */\nexport function getItemData(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions) + \"/data\";\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\", params: {} }, requestOptions);\n if (options.file) {\n options.params.f = null;\n }\n return request(url, options).catch(function (err) {\n /* if the item doesn't include data, the response will be empty\n and the internal call to response.json() will fail */\n var emptyResponseErr = RegExp(/The string did not match the expected pattern|(Unexpected end of (JSON input|data at line 1 column 1))/i);\n /* istanbul ignore else */\n if (emptyResponseErr.test(err.message)) {\n return;\n }\n else\n throw err;\n });\n}\n/**\n * ```\n * import { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n * //\n * getRelatedItems({\n * id: \"ae7\",\n * relationshipType: \"Service2Layer\" // or several [\"Service2Layer\", \"Map2Area\"]\n * })\n * .then(response)\n * ```\n * Get the related items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/related-items.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to get some item resources.\n */\nexport function getRelatedItems(requestOptions) {\n var url = getItemBaseUrl(requestOptions.id, requestOptions) + \"/relatedItems\";\n var options = __assign({ httpMethod: \"GET\", params: {\n direction: requestOptions.direction\n } }, requestOptions);\n if (typeof requestOptions.relationshipType === \"string\") {\n options.params.relationshipType = requestOptions.relationshipType;\n }\n else {\n options.params.relationshipTypes = requestOptions.relationshipType;\n }\n delete options.direction;\n delete options.relationshipType;\n return request(url, options);\n}\n/**\n * Get the resources associated with an item\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to get some item resources.\n */\nexport function getItemResources(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions) + \"/resources\";\n // Mix in num:1000 with any user supplied params\n // Key thing - we don't want to mutate the passed in requestOptions\n // as that may be used in other (subsequent) calls in the course\n // of a long promise chains\n var options = __assign({}, requestOptions);\n options.params = __assign({ num: 1000 }, options.params);\n return request(url, options);\n}\n/**\n * ```js\n * import { getItemResource } from \"@esri/arcgis-rest-portal\";\n *\n * // Parses contents as blob by default\n * getItemResource(\"3ef\", { fileName: \"resource.jpg\", ...})\n * .then(resourceContents => {});\n *\n * // Can override parse method\n * getItemResource(\"3ef\", { fileName: \"resource.json\", readAs: 'json', ...})\n * .then(resourceContents => {});\n *\n * // Get the response object instead\n * getItemResource(\"3ef\",{ rawResponse: true, fileName: \"resource.json\" })\n * .then(response => {})\n * ```\n * Fetches an item resource and optionally parses it to the correct format.\n *\n * Note: provides JSON parse error protection by sanitizing out any unescaped control\n * characters before parsing that would otherwise cause an error to be thrown\n *\n * @param {string} itemId\n * @param {IGetItemResourceOptions} requestOptions\n */\nexport function getItemResource(itemId, requestOptions) {\n var readAs = requestOptions.readAs || 'blob';\n return getItemFile(itemId, \"/resources/\" + requestOptions.fileName, readAs, requestOptions);\n}\n/**\n * ```js\n * import { getItemGroups } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemGroups(\"30e5fe3149c34df1ba922e6f5bbf808f\")\n * .then(response)\n * ```\n * Lists the groups of which the item is a part, only showing the groups that the calling user can access. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/groups.htm) for more information.\n *\n * @param id - The Id of the item to query group association for.\n * @param requestOptions - Options for the request\n * @returns A Promise to get some item groups.\n */\nexport function getItemGroups(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions) + \"/groups\";\n return request(url, requestOptions);\n}\n/**\n * ```js\n * import { getItemStatus } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemStatus({\n * id: \"30e5fe3149c34df1ba922e6f5bbf808f\",\n * authentication\n * })\n * .then(response)\n * ```\n * Inquire about status when publishing an item, adding an item in async mode, or adding with a multipart upload. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/status.htm) for more information.\n *\n * @param id - The Id of the item to get status for.\n * @param requestOptions - Options for the request\n * @returns A Promise to get the item status.\n */\nexport function getItemStatus(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/status\";\n var options = appendCustomParams(requestOptions, [\"jobId\", \"jobType\"], { params: __assign({}, requestOptions.params) });\n return request(url, options);\n });\n}\n/**\n * ```js\n * import { getItemParts } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemParts({\n * id: \"30e5fe3149c34df1ba922e6f5bbf808f\",\n * authentication\n * })\n * .then(response)\n * ```\n * Lists the part numbers of the file parts that have already been uploaded in a multipart file upload. This method can be used to verify the parts that have been received as well as those parts that were not received by the server. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/parts.htm) for more information.\n *\n * @param id - The Id of the item to get part list.\n * @param requestOptions - Options for the request\n * @returns A Promise to get the item part list.\n */\nexport function getItemParts(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/parts\";\n return request(url, requestOptions);\n });\n}\n/**\n * ```\n * import { getItemInfo } from \"@esri/arcgis-rest-portal\";\n * // get the \"Info Card\" for the item\n * getItemInfo(\"ae7\")\n * .then(itemInfoXml) // XML document as a string\n * // or get the contents of a specific file\n * getItemInfo(\"ae7\", { fileName: \"form.json\", readAs: \"json\", authentication })\n * .then(formJson) // JSON document as JSON\n * ```\n * Get an info file for an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/item-info-file.htm) for more information.\n * @param id - Item Id\n * @param requestOptions - Options for the request, including the file name which defaults to `iteminfo.xml`.\n * If the file is not a text file (XML, HTML, etc) you will need to specify the `readAs` parameter\n * @returns A Promise that will resolve with the contents of the info file for the item.\n */\nexport function getItemInfo(id, requestOptions) {\n var _a = requestOptions || {}, _b = _a.fileName, fileName = _b === void 0 ? \"iteminfo.xml\" : _b, _c = _a.readAs, readAs = _c === void 0 ? \"text\" : _c;\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return getItemFile(id, \"/info/\" + fileName, readAs, options);\n}\n/**\n * ```\n * import { getItemMetadata } from \"@esri/arcgis-rest-portal\";\n * // get the metadata for the item\n * getItemMetadata(\"ae7\")\n * .then(itemMetadataXml) // XML document as a string\n * // or with additional request options\n * getItemMetadata(\"ae7\", { authentication })\n * .then(itemMetadataXml) // XML document as a string\n * ```\n * Get the standard formal metadata XML file for an item (`/info/metadata/metadata.xml`)\n * @param id - Item Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the contents of the metadata file for the item as a string.\n */\nexport function getItemMetadata(id, requestOptions) {\n var options = __assign(__assign({}, requestOptions), { fileName: \"metadata/metadata.xml\" });\n return getItemInfo(id, options);\n}\n// overrides request()'s default behavior for reading the response\n// which is based on `params.f` and defaults to JSON\n// Also adds JSON parse error protection by sanitizing out any unescaped control characters before parsing\nfunction getItemFile(id, \n// NOTE: fileName should include any folder/subfolders\nfileName, readMethod, requestOptions) {\n var url = \"\" + getItemBaseUrl(id, requestOptions) + fileName;\n // preserve escape hatch to let the consumer read the response\n // and ensure the f param is not appended to the query string\n var options = __assign({ params: {} }, requestOptions);\n var justReturnResponse = options.rawResponse;\n options.rawResponse = true;\n options.params.f = null;\n return request(url, options).then(function (response) {\n if (justReturnResponse) {\n return response;\n }\n return readMethod !== 'json'\n ? response[readMethod]()\n : response.text().then(function (text) { return JSON.parse(scrubControlChars(text)); });\n });\n}\n//# sourceMappingURL=get.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { determineOwner } from \"./helpers\";\n/**\n * Protect an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/protect.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to protect an item.\n */\nexport function protectItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/protect\";\n return request(url, requestOptions);\n });\n}\n/**\n * Unprotect an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/unprotect.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to unprotect an item.\n */\nexport function unprotectItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/unprotect\";\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=protect.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { getGroup } from \"@esri/arcgis-rest-portal\";\n * //\n * getGroup(\"fxb988\") // id\n * .then(response)\n * ```\n * Fetch a group using its id. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group.htm) for more information.\n *\n * @param id - Group Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function getGroup(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id;\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * Gets the category schema set on a group\n *\n * @param id - Group Id\n * @param requestOptions - Options for the request\n * @returns A promise that will resolve with JSON of group's category schema\n * @see https://developers.arcgis.com/rest/users-groups-and-items/group-category-schema.htm\n */\nexport function getGroupCategorySchema(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/categorySchema\";\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * Returns the content of a Group. Since the group may contain 1000s of items\n * the requestParams allow for paging.\n * @param id - Group Id\n * @param requestOptions - Options for the request, including paging parameters.\n * @returns A Promise that will resolve with the content of the group.\n */\nexport function getGroupContent(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/content/groups/\" + id;\n // default to a GET request\n var options = __assign(__assign({ httpMethod: \"GET\" }, { params: { start: 1, num: 100 } }), requestOptions);\n // is this the most concise way to mixin with the defaults above?\n if (requestOptions && requestOptions.paging) {\n options.params = __assign({}, requestOptions.paging);\n }\n return request(url, options);\n}\n/**\n * Get the usernames of the admins and members. Does not return actual 'User' objects. Those must be\n * retrieved via separate calls to the User's API.\n * @param id - Group Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with arrays of the group admin usernames and the member usernames\n */\nexport function getGroupUsers(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/users\";\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * ```js\n * import { searchGroupUsers } from \"@esri/arcgis-rest-portal\";\n * //\n * searchGroupUsers('abc123')\n * .then(response)\n * ```\n * Search the users in a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group-users-list.htm) for more information.\n *\n * @param id - The group id\n * @param searchOptions - Options for the request, including paging parameters.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchGroupUsers(id, searchOptions) {\n var url = getPortalUrl(searchOptions) + \"/community/groups/\" + id + \"/userlist\";\n var options = appendCustomParams(searchOptions || {}, [\"name\", \"num\", \"start\", \"sortField\", \"sortOrder\", \"joined\", \"memberType\"], {\n httpMethod: \"GET\"\n });\n return request(url, options);\n}\n//# sourceMappingURL=get.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { getGroup } from \"../groups/get\";\nexport function getSharingUrl(requestOptions) {\n var username = requestOptions.authentication.username;\n var owner = requestOptions.owner || username;\n return getPortalUrl(requestOptions) + \"/content/users/\" + encodeURIComponent(owner) + \"/items/\" + requestOptions.id + \"/share\";\n}\nexport function isItemOwner(requestOptions) {\n var username = requestOptions.authentication.username;\n var owner = requestOptions.owner || username;\n return owner === username;\n}\n/**\n * Check it the user is a full org_admin\n * @param requestOptions\n * @returns Promise resolving in a boolean indicating if the user is an ArcGIS Organization administrator\n */\nexport function isOrgAdmin(requestOptions) {\n var session = requestOptions.authentication;\n return session.getUser(requestOptions).then(function (user) {\n return user && user.role === \"org_admin\" && !user.roleId;\n });\n}\n/**\n * Get the User Membership for a particular group. Use this if all you have is the groupId.\n * If you have the group object, check the `userMembership.memberType` property instead of calling this method.\n *\n * @param requestOptions\n * @returns A Promise that resolves with \"owner\" | \"admin\" | \"member\" | \"nonmember\"\n */\nexport function getUserMembership(requestOptions) {\n // fetch the group...\n return getGroup(requestOptions.groupId, requestOptions)\n .then(function (group) {\n return group.userMembership.memberType;\n })\n .catch(function () {\n return \"none\";\n });\n}\n//# sourceMappingURL=helpers.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { determineOwner } from \"./helpers\";\n/**\n * ```js\n * import { removeItem } from \"@esri/arcgis-rest-portal\";\n * //\n * removeItem({\n * id: \"3ef\",\n * authentication\n * })\n * ```\n * Delete an item from the portal. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-item.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that deletes an item.\n */\nexport function removeItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/delete\";\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { removeItemRelationship } from \"@esri/arcgis-rest-portal\";\n * //\n * removeItemRelationship({\n * originItemId: '3ef',\n * destinationItemId: 'ae7',\n * relationshipType: 'Service2Layer',\n * authentication\n * })\n * .then(response)\n * ```\n * Remove a relationship between two items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-relationship.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to add item resources.\n */\nexport function removeItemRelationship(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/deleteRelationship\";\n var options = appendCustomParams(requestOptions, [\"originItemId\", \"destinationItemId\", \"relationshipType\"], { params: __assign({}, requestOptions.params) });\n return request(url, options);\n });\n}\n/**\n * Remove a resource associated with an item\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that deletes an item resource.\n */\nexport function removeItemResource(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/removeResources\";\n // mix in user supplied params\n requestOptions.params = __assign(__assign({}, requestOptions.params), { resource: requestOptions.resource });\n // only override the deleteAll param specified previously if it is passed explicitly\n if (typeof requestOptions.deleteAll !== \"undefined\") {\n requestOptions.params.deleteAll = requestOptions.deleteAll;\n }\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { removeFolder } from \"@esri/arcgis-rest-portal\";\n * //\n * removeFolder({\n * folderId: \"fe4\",\n * owner: \"c@sey\",\n * authentication\n * })\n * .then(response)\n *\n * ```\n * Delete a non-root folder and all the items it contains. See the [REST\n * Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-folder.htm) for\n * more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that deletes a folder\n */\nexport function removeFolder(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + encodeURIComponent(owner) + \"/\" + requestOptions.folderId + \"/delete\";\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=remove.js.map","/* Copyright (c) 2018-2021 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { warn } from \"@esri/arcgis-rest-request\";\n/**\n * `SearchQueryBuilder` can be used to construct the `q` param for\n * [`searchItems`](/arcgis-rest-js/api/portal/searchItems#searchItems-search) or\n * [`searchGroups`](/arcgis-rest-js/api/portal/searchGroups#searchGroups-search).\n * By chaining methods, it helps build complex search queries.\n *\n * ```js\n * const startDate = new Date(\"2020-01-01\");\n * const endDate = new Date(\"2020-09-01\");\n * const query = new SearchQueryBuilder()\n * .match(\"Patrick\")\n * .in(\"owner\")\n * .and()\n * .from(startDate)\n * .to(endDate)\n * .in(\"created\")\n * .and()\n * .startGroup()\n * .match(\"Web Mapping Application\")\n * .in(\"type\")\n * .or()\n * .match(\"Mobile Application\")\n * .in(\"type\")\n * .or()\n * .match(\"Application\")\n * .in(\"type\")\n * .endGroup()\n * .and()\n * .match(\"Demo App\");\n *\n * searchItems(query).then((res) => {\n * console.log(res.results);\n * });\n * ```\n *\n * Will search for items matching\n * ```\n * \"owner: Patrick AND created:[1577836800000 TO 1598918400000] AND (type:\"Web Mapping Application\" OR type:\"Mobile Application\" OR type:Application) AND Demo App\"\n * ```\n */\nvar SearchQueryBuilder = /** @class */ (function () {\n /**\n * @param q An existing query string to start building from.\n */\n function SearchQueryBuilder(q) {\n if (q === void 0) { q = \"\"; }\n this.termStack = [];\n this.rangeStack = [];\n this.openGroups = 0;\n this.q = q;\n }\n /**\n * Defines strings to search for.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"My Layer\")\n * ```\n *\n * @param terms strings to search for.\n */\n SearchQueryBuilder.prototype.match = function () {\n var terms = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n terms[_i] = arguments[_i];\n }\n this.termStack = this.termStack.concat(terms);\n return this;\n };\n /**\n * Defines fields to search in. You can pass `\"*\"` or call this method without arguments to search a default set of fields\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"My Layer\")\n * .in(\"title\")\n * ```\n *\n * @param field The field to search for the previous match in.\n */\n SearchQueryBuilder.prototype.in = function (field) {\n var fn = \"`in(\" + (field ? \"\\\"\" + field + \"\\\"\" : \"\") + \")`\";\n if (!this.hasRange && !this.hasTerms) {\n warn(\n // apparently-p-rettier-ignore causes some\n fn + \" was called with no call to `match(...)` or `from(...)`/`to(...)`. Your query was not modified.\");\n return this;\n }\n if (field && field !== \"*\") {\n this.q += field + \":\";\n }\n return this.commit();\n };\n /**\n * Starts a new search group.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .startGroup()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .endGroup()\n * .or()\n * .startGroup()\n * .match(\"Rivers\")\n * .in(\"title\")\n * .endGroup()\n * ```\n */\n SearchQueryBuilder.prototype.startGroup = function () {\n this.commit();\n if (this.openGroups > 0) {\n this.q += \" \";\n }\n this.openGroups++;\n this.q += \"(\";\n return this;\n };\n /**\n * Ends a search group.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .startGroup()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .endGroup()\n * .or()\n * .startGroup()\n * .match(\"Rivers\")\n * .in(\"title\")\n * .endGroup()\n * ```\n */\n SearchQueryBuilder.prototype.endGroup = function () {\n if (this.openGroups <= 0) {\n warn(\"`endGroup(...)` was called without calling `startGroup(...)` first. Your query was not modified.\");\n return this;\n }\n this.commit();\n this.openGroups--;\n this.q += \")\";\n return this;\n };\n /**\n * Joins two sets of queries with an `AND` clause.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .and()\n * .match(\"Rivers\")\n * .in(\"title\")\n * ```\n */\n SearchQueryBuilder.prototype.and = function () {\n return this.addModifier(\"and\");\n };\n /**\n * Joins two sets of queries with an `OR` clause.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .or()\n * .match(\"Rivers\")\n * .in(\"title\")\n * ```\n */\n SearchQueryBuilder.prototype.or = function () {\n return this.addModifier(\"or\");\n };\n /**\n * Joins two sets of queries with a `NOT` clause. Another option for filtering results is the [prohibit operator '-'](https://developers.arcgis.com/rest/users-groups-and-items/search-reference.htm#ESRI_SECTION1_5C6C35DB9E4A4F4492C5B937BDA2BF67).\n *\n * ```js\n * // omit results with \"Rivers\" in their title\n * const query = new SearchQueryBuilder()\n * .not()\n * .match(\"Rivers\")\n * .in(\"title\")\n *\n * // equivalent\n * const query = new SearchQueryBuilder()\n * .match(\"Rivers\")\n * .in(\"-title\")\n * ```\n */\n SearchQueryBuilder.prototype.not = function () {\n return this.addModifier(\"not\");\n };\n /**\n * Begins a new range query.\n *\n * ```js\n *\n * const NEWYEARS = new Date(\"2020-01-01\")\n * const TODAY = new Date()\n *\n * const query = new SearchQueryBuilder()\n * .from(NEWYEARS)\n * .to(TODAY)\n * .in(\"created\")\n * ```\n */\n SearchQueryBuilder.prototype.from = function (term) {\n if (this.hasTerms) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"`from(...)` is not allowed after `match(...)` try using `.from(...).to(...).in(...)`. Optionally, you may see this because dates are incorrectly formatted. Dates should be a primative Date value, aka a number in milliseconds or Date object, ie new Date(\\\"2020-01-01\\\"). Your query was not modified.\");\n return this;\n }\n this.rangeStack[0] = term;\n return this;\n };\n /**\n * Ends a range query.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .from(yesterdaysDate)\n * .to(todaysDate)\n * .in(\"created\")\n * ```\n */\n SearchQueryBuilder.prototype.to = function (term) {\n if (this.hasTerms) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"`to(...)` is not allowed after `match(...)` try using `.from(...).to(...).in(...)`. Optionally, you may see this because dates are incorrectly formatted. Dates should be a primative Date value, aka a number in milliseconds or Date object, ie new Date(\\\"2020-01-01\\\"). Your query was not modified.\");\n return this;\n }\n this.rangeStack[1] = term;\n return this;\n };\n /**\n * Boosts the previous term to increase its rank in the results.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .or()\n * .match(\"Rivers\")\n * .in(\"title\")\n * .boost(3)\n * ```\n */\n SearchQueryBuilder.prototype.boost = function (num) {\n this.commit();\n this.q += \"^\" + num;\n return this;\n };\n /**\n * Returns the current query string. Called internally when the request is made.\n */\n SearchQueryBuilder.prototype.toParam = function () {\n this.commit();\n this.cleanup();\n return this.q;\n };\n /**\n * Returns a new instance of `SearchQueryBuilder` based on the current instance.\n */\n SearchQueryBuilder.prototype.clone = function () {\n this.commit();\n this.cleanup();\n return new SearchQueryBuilder(this.q + \"\");\n };\n SearchQueryBuilder.prototype.addModifier = function (modifier) {\n if (this.currentModifer) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"You have called `\" + this.currentModifer + \"()` after `\" + modifier + \"()`. Your current query was not modified.\");\n return this;\n }\n this.commit();\n if (this.q === \"\" && modifier !== \"not\") {\n warn(\"You have called `\" + modifier + \"()` without calling another method to modify your query first. Try calling `match()` first.\");\n return this;\n }\n this.currentModifer = modifier;\n this.q += this.q === \"\" ? \"\" : \" \";\n this.q += modifier.toUpperCase() + \" \";\n return this;\n };\n SearchQueryBuilder.prototype.needsQuotes = function (s) {\n return /\\s|:/g.test(s);\n };\n SearchQueryBuilder.prototype.formatTerm = function (term) {\n if (term instanceof Date) {\n return term.getTime();\n }\n if (typeof term === \"string\" && this.needsQuotes(term)) {\n return \"\\\"\" + term + \"\\\"\";\n }\n return term;\n };\n SearchQueryBuilder.prototype.commit = function () {\n var _this = this;\n this.currentModifer = undefined;\n if (this.hasRange) {\n this.q += \"[\" + this.formatTerm(this.rangeStack[0]) + \" TO \" + this.formatTerm(this.rangeStack[1]) + \"]\";\n this.rangeStack = [undefined, undefined];\n }\n if (this.hasTerms) {\n this.q += this.termStack\n .map(function (term) {\n return _this.formatTerm(term);\n })\n .join(\" \");\n this.termStack = [];\n }\n return this;\n };\n Object.defineProperty(SearchQueryBuilder.prototype, \"hasTerms\", {\n get: function () {\n return this.termStack.length > 0;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(SearchQueryBuilder.prototype, \"hasRange\", {\n get: function () {\n return this.rangeStack.length && this.rangeStack[0] && this.rangeStack[1];\n },\n enumerable: false,\n configurable: true\n });\n SearchQueryBuilder.prototype.cleanup = function () {\n // end a group if we have started one\n if (this.openGroups > 0) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"Automatically closing \" + this.openGroups + \" group(s). You can use `endGroup(...)` to remove this warning.\");\n while (this.openGroups > 0) {\n this.q += \")\";\n this.openGroups--;\n }\n }\n var oldQ = this.q;\n this.q = oldQ.replace(/( AND ?| NOT ?| OR ?)*$/, \"\");\n if (oldQ !== this.q) {\n warn(\"`startGroup(...)` was called without calling `endGroup(...)` first. Your query was not modified.\");\n }\n // clear empty groups\n this.q = this.q.replace(/(\\(\\))*/, \"\");\n };\n return SearchQueryBuilder;\n}());\nexport { SearchQueryBuilder };\n//# sourceMappingURL=SearchQueryBuilder.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request, appendCustomParams, } from \"@esri/arcgis-rest-request\";\nimport { SearchQueryBuilder } from \"./SearchQueryBuilder\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nexport function genericSearch(search, searchType) {\n var options;\n if (typeof search === \"string\" || search instanceof SearchQueryBuilder) {\n options = {\n httpMethod: \"GET\",\n params: {\n q: search,\n },\n };\n }\n else {\n // searchUserAccess has one (knonw) valid value: \"groupMember\"\n options = appendCustomParams(search, [\n \"q\",\n \"num\",\n \"start\",\n \"sortField\",\n \"sortOrder\",\n \"searchUserAccess\",\n \"searchUserName\",\n \"filter\",\n \"countFields\",\n \"countSize\",\n \"categories\",\n \"categoryFilters\",\n ], {\n httpMethod: \"GET\",\n });\n }\n var path;\n switch (searchType) {\n case \"item\":\n path = \"/search\";\n break;\n case \"group\":\n path = \"/community/groups\";\n break;\n case \"groupContent\":\n // Need to have groupId property to do group contents search,\n // cso filter out all but ISearchGroupContentOptions\n if (typeof search !== \"string\" &&\n !(search instanceof SearchQueryBuilder) &&\n search.groupId) {\n path = \"/content/groups/\" + search.groupId + \"/search\";\n }\n else {\n return Promise.reject(new Error(\"you must pass a `groupId` option to `searchGroupContent`\"));\n }\n break;\n default:\n // \"users\"\n path = \"/portals/self/users/search\";\n break;\n }\n var url = getPortalUrl(options) + path;\n // send the request\n return request(url, options).then(function (r) {\n if (r.nextStart && r.nextStart !== -1) {\n r.nextPage = function () {\n var newOptions;\n if (typeof search === \"string\" ||\n search instanceof SearchQueryBuilder) {\n newOptions = {\n q: search,\n start: r.nextStart,\n };\n }\n else {\n newOptions = search;\n newOptions.start = r.nextStart;\n }\n return genericSearch(newOptions, searchType);\n };\n }\n return r;\n });\n}\n//# sourceMappingURL=generic-search.js.map","/* Copyright (c) 2018-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { genericSearch } from \"../util/generic-search\";\n/**\n * ```js\n * import { searchItems } from \"@esri/arcgis-rest-portal\";\n * //\n * searchItems('water')\n * .then(response) // response.total => 355\n * ```\n * Search a portal for items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/search.htm) for more information.\n *\n * @param search - A string or RequestOptions object to pass through to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchItems(search) {\n return genericSearch(search, \"item\");\n}\n//# sourceMappingURL=search.js.map","/* Copyright (c) 2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nexport function chunk(array, size) {\n if (array.length === 0) {\n return [];\n }\n var chunks = [];\n for (var i = 0; i < array.length; i += size) {\n chunks.push(array.slice(i, i + size));\n }\n return chunks;\n}\n//# sourceMappingURL=array.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign, __spreadArrays } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * ```js\n * import { addGroupUsers } from \"@esri/arcgis-rest-portal\";\n * //\n * addGroupUsers({\n * id: groupId,\n * users: [\"username1\", \"username2\"],\n * admins: [\"username3\"],\n * authentication\n * })\n * .then(response);\n * ```\n * Add users to a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/add-users-to-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise\n */\nexport function addGroupUsers(requestOptions) {\n var id = requestOptions.id;\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/addUsers\";\n var baseOptions = Object.assign({}, requestOptions, {\n admins: undefined,\n users: undefined\n });\n var batchRequestOptions = __spreadArrays(_prepareRequests(\"users\", requestOptions.users, baseOptions), _prepareRequests(\"admins\", requestOptions.admins, baseOptions));\n var promises = batchRequestOptions.map(function (options) {\n return _sendSafeRequest(url, options);\n });\n return Promise.all(promises).then(_consolidateRequestResults);\n}\nfunction _prepareRequests(type, usernames, baseOptions) {\n if (!usernames || usernames.length < 1) {\n return [];\n }\n // the ArcGIS REST API only allows to add no more than 25 users per request,\n // see https://developers.arcgis.com/rest/users-groups-and-items/add-users-to-group.htm\n var userChunks = chunk(usernames, 25);\n return userChunks.map(function (users) {\n return _generateRequestOptions(type, users, baseOptions);\n });\n}\nfunction _generateRequestOptions(type, usernames, baseOptions) {\n var _a, _b;\n return Object.assign({}, baseOptions, (_a = {},\n _a[type] = usernames,\n _a.params = __assign(__assign({}, baseOptions.params), (_b = {}, _b[type] = usernames, _b)),\n _a));\n}\n// this request is safe since the request error will be handled\nfunction _sendSafeRequest(url, requestOptions) {\n return request(url, requestOptions).catch(function (error) {\n return {\n errors: [error]\n };\n });\n}\nfunction _consolidateRequestResults(results) {\n var notAdded = results\n .filter(function (result) { return result.notAdded; })\n .reduce(function (collection, result) { return collection.concat(result.notAdded); }, []);\n var errors = results\n .filter(function (result) { return result.errors; })\n .reduce(function (collection, result) { return collection.concat(result.errors); }, []);\n var consolidated = { notAdded: notAdded };\n if (errors.length > 0) {\n consolidated.errors = errors;\n }\n return consolidated;\n}\n//# sourceMappingURL=add-users.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * ```js\n * import { removeGroupUsers } from \"@esri/arcgis-rest-portal\";\n * //\n * removeGroupUsers({\n * id: groupId,\n * users: [\"username1\", \"username2\"],\n * authentication\n * })\n * .then(response);\n * ```\n * Add users to a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/remove-users-from-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise\n */\nexport function removeGroupUsers(requestOptions) {\n var id = requestOptions.id, usersToRemove = requestOptions.users;\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/removeUsers\";\n var safeSend = function (users) {\n var options = __assign(__assign({}, requestOptions), { users: users, params: { users: users } });\n return request(url, options)\n .catch(function (error) { return ({ errors: [error] }); });\n };\n // the ArcGIS REST API only allows to add no more than 25 users per request,\n // see https://developers.arcgis.com/rest/users-groups-and-items/remove-users-from-group.htm\n var promises = chunk(usersToRemove, 25).map(function (usersChunk) { return safeSend(usersChunk); });\n return Promise.all(promises)\n .then(function (results) {\n var filtered = function (propName) { return results\n .filter(function (result) { return result[propName]; })\n .reduce(function (collection, result) { return collection.concat(result[propName]); }, []); };\n var errors = filtered('errors');\n var consolidated = { notRemoved: filtered('notRemoved') };\n return errors.length ? __assign(__assign({}, consolidated), { errors: errors }) : consolidated;\n });\n}\n//# sourceMappingURL=remove-users.js.map","import { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * Invites users to join a group. Operation success\n * will be indicated by a flag on the return\n * object. If there are any errors, they will be\n * placed in an errors array on the return object\n *\n * ```js\n * const authentication: IAuthenticationManager; // Typically passed into to the function\n * //\n * const options: IInviteGroupUsersOptions = {\n * id: 'group_id',\n * users: ['ed', 'edd', 'eddy'],\n * role: 'group-member',\n * expiration: 20160,\n * authentication\n * }\n * //\n * const result = await inviteGroupUsers(options);\n * //\n * const if_success_result_looks_like = {\n * success: true\n * }\n * //\n * const if_failure_result_looks_like = {\n * success: false,\n * errors: [ArcGISRequestError]\n * }\n * ```\n * @param {IInviteGroupUsersOptions} options\n *\n * @returns {Promise<IAddGroupUsersResult>}\n */\nexport function inviteGroupUsers(options) {\n var id = options.id;\n var url = getPortalUrl(options) + \"/community/groups/\" + id + \"/invite\";\n var batches = _generateBatchRequests(options);\n var promises = batches.map(function (batch) { return _sendSafeRequest(url, batch); });\n return Promise.all(promises).then(_combineResults);\n}\n/**\n * @private\n */\nfunction _generateBatchRequests(options) {\n var userBatches = chunk(options.users, 25);\n return userBatches.map(function (users) { return _generateRequestOptions(users, options); });\n}\n/**\n * @private\n */\nfunction _generateRequestOptions(users, baseOptions) {\n var requestOptions = Object.assign({}, baseOptions);\n requestOptions.params = __assign(__assign({}, requestOptions.params), { users: users, role: requestOptions.role, expiration: requestOptions.expiration });\n return requestOptions;\n}\n/**\n * @private\n */\nfunction _sendSafeRequest(url, requestOptions) {\n return request(url, requestOptions)\n .catch(function (error) { return ({ errors: [error] }); });\n}\n/**\n * @private\n */\nfunction _combineResults(responses) {\n var success = responses.every(function (res) { return res.success; });\n var errors = responses.reduce(function (collection, res) { return collection.concat(res.errors || []); }, []);\n var combined = { success: success };\n if (errors.length > 0) {\n combined.errors = errors;\n }\n return combined;\n}\n//# sourceMappingURL=invite-users.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { protectGroup } from '@esri/arcgis-rest-portal';\n * //\n * protectGroup({\n * id: groupId,\n * authentication\n * })\n * .then(response)\n * ```\n * Protect a group to avoid accidental deletion. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/protect-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the success/failure status of the request\n */\nexport function protectGroup(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/protect\";\n return request(url, requestOptions);\n}\n/**\n * ```js\n * import { unprotectGroup } from '@esri/arcgis-rest-portal';\n * //\n * unprotectGroup({\n * id: groupId,\n * authentication\n * })\n * .then(response)\n * ```\n * Unprotect a Group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/unprotect-group.htm) for more information.\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the success/failure status of the request\n */\nexport function unprotectGroup(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/unprotect\";\n return request(url, requestOptions);\n}\n//# sourceMappingURL=protect.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { removeGroup } from '@esri/arcgis-rest-portal';\n * //\n * removeGroup({\n * id: groupId,\n * authentication\n * })\n * .then(response)\n * ```\n * Delete a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the success/failure status of the request\n */\nexport function removeGroup(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/delete\";\n var options = __assign({}, requestOptions);\n return request(url, options);\n}\n//# sourceMappingURL=remove.js.map","/* Copyright (c) 2018-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { genericSearch } from \"../util/generic-search\";\n/**\n * ```js\n * import { searchGroups } from \"@esri/arcgis-rest-portal\";\n * //\n * searchGroups('water')\n * .then(response) // response.total => 355\n * ```\n * Search a portal for groups. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group-search.htm) for more information.\n *\n * @param search - A string or RequestOptions object to pass through to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchGroups(search) {\n return genericSearch(search, \"group\");\n}\n/**\n * ```js\n * import { searchGroupContent } from \"@esri/arcgis-rest-portal\";\n * //\n * searchGroupContent('water')\n * .then(response) // response.total => 355\n * ```\n * Search a portal for items in a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group-content-search.htm) for more information.\n *\n * @param options - RequestOptions object amended with search parameters.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchGroupContent(options) {\n return genericSearch(options, \"groupContent\");\n}\n//# sourceMappingURL=search.js.map","import { getPortalUrl } from \"../util/get-portal-url\";\nimport { request } from \"@esri/arcgis-rest-request\";\n/**\n * ```js\n * import { updateUserMemberships } from \"@esri/arcgis-rest-portal\";\n * //\n * updateUserMemberships({\n * id: groupId,\n * admins: [\"username3\"],\n * authentication\n * })\n * .then(response);\n * ```\n * Change the user membership levels of existing users in a group\n *\n * @param requestOptions - Options for the request\n * @returns A Promise\n */\nexport function updateUserMemberships(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/updateUsers\";\n var opts = {\n authentication: requestOptions.authentication,\n params: {}\n };\n // add the correct params depending on the type of membership we are changing to\n if (requestOptions.newMemberType === \"admin\") {\n opts.params.admins = requestOptions.users;\n }\n else {\n opts.params.users = requestOptions.users;\n }\n // make the request\n return request(url, opts);\n}\n//# sourceMappingURL=update-user-membership.js.map","import { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * Send a notification to members of the requesting user's org.\n * Operation success will be indicated by a flag on the return\n * object. If there are any errors, they will be placed in an\n * errors array on the return object\n *\n * ```js\n * const authentication: IAuthenticationManager; // Typically passed into to the function\n * //\n * const options: IInviteGroupUsersOptions = {\n * id: 'group_id',\n * users: ['larry', 'curly', 'moe'],\n * notificationChannelType: 'email',\n * expiration: 20160,\n * authentication\n * }\n * //\n * const result = await createOrgNotification(options);\n * //\n * const if_success_result_looks_like = {\n * success: true\n * }\n * //\n * const if_failure_result_looks_like = {\n * success: false,\n * errors: [ArcGISRequestError]\n * }\n * ```\n * @param {ICreateOrgNotificationOptions} options\n *\n * @returns {ICreateOrgNotificationResult}\n */\nexport function createOrgNotification(options) {\n var url = getPortalUrl(options) + \"/portals/self/createNotification\";\n var batches = _generateBatchRequests(options);\n var promises = batches.map(function (batch) { return _sendSafeRequest(url, batch); });\n return Promise.all(promises).then(_combineResults);\n}\n/**\n * @private\n */\nfunction _generateBatchRequests(options) {\n var userBatches = chunk(options.users, options.batchSize || 25);\n return userBatches.map(function (users) { return _generateRequestOptions(users, options); });\n}\n/**\n * @private\n */\nfunction _generateRequestOptions(users, baseOptions) {\n var requestOptions = Object.assign({}, baseOptions);\n requestOptions.params = __assign(__assign({}, requestOptions.params), { users: users, subject: baseOptions.subject, message: baseOptions.message, notificationChannelType: requestOptions.notificationChannelType });\n return requestOptions;\n}\n/**\n * @private\n */\nfunction _sendSafeRequest(url, requestOptions) {\n return request(url, requestOptions)\n .catch(function (error) { return ({ errors: [error] }); });\n}\n/**\n * @private\n */\nfunction _combineResults(responses) {\n var success = responses.every(function (res) { return res.success; });\n var errors = responses.reduce(function (collection, res) { return collection.concat(res.errors || []); }, []);\n var combined = { success: success };\n if (errors.length > 0) {\n combined.errors = errors;\n }\n return combined;\n}\n//# sourceMappingURL=notification.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { getUser } from '@esri/arcgis-rest-portal';\n * //\n * getUser(\"jsmith\")\n * .then(response)\n * // => { firstName: \"John\", lastName: \"Smith\",tags: [\"GIS Analyst\", \"City of Redlands\"] }\n * ```\n * Get information about a user. This method has proven so generically useful that you can also call [`UserSession.getUser()`](/arcgis-rest-js/api/auth/UserSession#getUser-summary).\n *\n * @param requestOptions - options to pass through in the request\n * @returns A Promise that will resolve with metadata about the user\n */\nexport function getUser(requestOptions) {\n var url;\n var options = { httpMethod: \"GET\" };\n // if a username is passed, assume ArcGIS Online\n if (typeof requestOptions === \"string\") {\n url = \"https://www.arcgis.com/sharing/rest/community/users/\" + requestOptions;\n }\n else {\n // if an authenticated session is passed, default to that user/portal unless another username is provided manually\n var username = requestOptions.username || requestOptions.authentication.username;\n url = getPortalUrl(requestOptions) + \"/community/users/\" + encodeURIComponent(username);\n options = __assign(__assign({}, requestOptions), options);\n }\n // send the request\n return request(url, options);\n}\n//# sourceMappingURL=get-user.js.map","import { genericSearch } from \"../util/generic-search\";\n/**\n * ```js\n * import { searchItems } from \"@esri/arcgis-rest-portal\";\n * //\n * searchUsers({ q: 'tommy', authentication })\n * .then(response) // response.total => 355\n * ```\n * Search a portal for users.\n *\n * @param search - A RequestOptions object to pass through to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchUsers(search) {\n return genericSearch(search, \"user\");\n}\n//# sourceMappingURL=search-users.js.map","import { searchItems } from \"../items/search\";\n/**\n * ```js\n * import { isItemSharedWithGroup } from \"@esri/arcgis-rest-portal\";\n * //\n * isItemSharedWithGroup({\n * groupId: 'bc3,\n * itemId: 'f56,\n * authentication\n * })\n * .then(isShared => {})\n * ```\n * Find out whether or not an item is already shared with a group.\n *\n * @param requestOptions - Options for the request. NOTE: `rawResponse` is not supported by this operation.\n * @returns Promise that will resolve with true/false\n */\nexport function isItemSharedWithGroup(requestOptions) {\n var searchOpts = {\n q: \"id: \" + requestOptions.id + \" AND group: \" + requestOptions.groupId,\n start: 1,\n num: 10,\n sortField: \"title\",\n authentication: requestOptions.authentication,\n httpMethod: \"POST\"\n };\n return searchItems(searchOpts).then(function (searchResponse) {\n var result = false;\n if (searchResponse.total > 0) {\n result = searchResponse.results.some(function (itm) {\n return itm.id === requestOptions.id;\n });\n return result;\n }\n });\n}\n//# sourceMappingURL=is-item-shared-with-group.js.map","import { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { getUserMembership, } from \"./helpers\";\nimport { getUser } from \"../users/get-user\";\nimport { addGroupUsers } from \"../groups/add-users\";\nimport { removeGroupUsers } from \"../groups/remove-users\";\nimport { updateUserMemberships, } from \"../groups/update-user-membership\";\nimport { isItemSharedWithGroup } from \"../sharing/is-item-shared-with-group\";\n/**\n * ```js\n * import { shareItemWithGroup } from '@esri/arcgis-rest-portal';\n * //\n * shareItemWithGroup({\n * id: \"abc123\",\n * groupId: \"xyz987\",\n * owner: \"some-owner\",\n * authentication\n * })\n * ```\n * Share an item with a group, either as an\n * [item owner](https://developers.arcgis.com/rest/users-groups-and-items/share-item-as-item-owner-.htm),\n * [group admin](https://developers.arcgis.com/rest/users-groups-and-items/share-item-as-group-admin-.htm) or\n * organization admin.\n *\n * Note: Sharing the item as an Admin will use the `/content/users/:ownername/items/:itemid/share` end-point\n *\n * @param requestOptions - Options for the request.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function shareItemWithGroup(requestOptions) {\n return isItemSharedWithGroup(requestOptions)\n .then(function (isShared) {\n if (isShared) {\n // already shared, exit early with success response\n return {\n itemId: requestOptions.id,\n shortcut: true,\n notSharedWith: [],\n };\n }\n var username = requestOptions.authentication.username, owner = requestOptions.owner, confirmItemControl = requestOptions.confirmItemControl;\n var itemOwner = owner || username;\n // non-item owner\n if (itemOwner !== username) {\n // need to track if the user is an admin\n var isAdmin_1 = false;\n // track if the admin & owner are in the same org\n var isCrossOrgSharing_1 = false;\n // next perform any necessary membership adjustments for\n // current user and/or item owner\n return Promise.all([\n getUser({\n username: username,\n authentication: requestOptions.authentication,\n }),\n getUser({\n username: itemOwner,\n authentication: requestOptions.authentication,\n }),\n getUserMembership(requestOptions),\n ])\n .then(function (_a) {\n var currentUser = _a[0], ownerUser = _a[1], membership = _a[2];\n var isSharedEditingGroup = !!confirmItemControl;\n isAdmin_1 = currentUser.role === \"org_admin\" && !currentUser.roleId;\n isCrossOrgSharing_1 = currentUser.orgId !== ownerUser.orgId;\n return getMembershipAdjustments(currentUser, isSharedEditingGroup, membership, isAdmin_1, ownerUser, requestOptions);\n })\n .then(function (membershipAdjustments) {\n var _a = membershipAdjustments[0], revert = (_a === void 0 ? {\n promise: Promise.resolve({ notAdded: [] }),\n revert: function (sharingResults) {\n return Promise.resolve(sharingResults);\n },\n } : _a).revert;\n // perform all membership adjustments\n return Promise.all(membershipAdjustments.map(function (_a) {\n var promise = _a.promise;\n return promise;\n }))\n .then(function () {\n // then attempt the share\n return shareToGroup(requestOptions, isAdmin_1, isCrossOrgSharing_1);\n })\n .then(function (sharingResults) {\n // lastly, if the admin user was added to the group,\n // remove them from the group. this is a no-op that\n // immediately resolves the sharingResults when no\n // membership adjustment was needed\n return revert(sharingResults);\n });\n });\n }\n // item owner, let it call through\n return shareToGroup(requestOptions);\n })\n .then(function (sharingResponse) {\n if (sharingResponse.notSharedWith.length) {\n throw Error(\"Item \" + requestOptions.id + \" could not be shared to group \" + requestOptions.groupId + \".\");\n }\n else {\n // all is well\n return sharingResponse;\n }\n });\n}\nfunction getMembershipAdjustments(currentUser, isSharedEditingGroup, membership, isAdmin, ownerUser, requestOptions) {\n var membershipGuarantees = [];\n if (requestOptions.groupId !== currentUser.favGroupId) {\n if (isSharedEditingGroup) {\n if (!isAdmin) {\n // abort and reject promise\n throw Error(\"This item can not be shared to shared editing group \" + requestOptions.groupId + \" by \" + currentUser.username + \" as they not the item owner or org admin.\");\n }\n membershipGuarantees.push(\n // admin user must be a group member to share, should be reverted afterwards\n ensureMembership(currentUser, currentUser, false, \"Error adding \" + currentUser.username + \" as member to edit group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\", requestOptions), \n // item owner must be a group admin\n ensureMembership(currentUser, ownerUser, true, membership === \"none\"\n ? \"Error adding user \" + ownerUser.username + \" to edit group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\"\n : \"Error promoting user \" + ownerUser.username + \" to admin in edit group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\", requestOptions));\n }\n else if (isAdmin) {\n // admin user must be a group member to share, should be reverted afterwards\n membershipGuarantees.push(ensureMembership(currentUser, currentUser, false, \"Error adding \" + currentUser.username + \" as member to view group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\", requestOptions));\n }\n else if (membership === \"none\") {\n // all other non-item owners must be a group member\n throw new Error(\"This item can not be shared by \" + currentUser.username + \" as they are not a member of the specified group \" + requestOptions.groupId + \".\");\n }\n }\n return membershipGuarantees;\n}\nfunction shareToGroup(requestOptions, isAdmin, isCrossOrgSharing) {\n if (isAdmin === void 0) { isAdmin = false; }\n if (isCrossOrgSharing === void 0) { isCrossOrgSharing = false; }\n var username = requestOptions.authentication.username;\n var itemOwner = requestOptions.owner || username;\n // decide what url to use\n // default to the non-owner url...\n var url = getPortalUrl(requestOptions) + \"/content/items/\" + requestOptions.id + \"/share\";\n // but if they are the owner, or org_admin, use this route\n // Note: When using this end-point as an admin, apparently the admin does not need to be a member of the group (the itemOwner does)\n // Note: Admin's can only use this route when the item is in the same org they are admin for\n if (itemOwner === username || (isAdmin && !isCrossOrgSharing)) {\n url = getPortalUrl(requestOptions) + \"/content/users/\" + itemOwner + \"/items/\" + requestOptions.id + \"/share\";\n }\n // now its finally time to do the sharing\n requestOptions.params = {\n groups: requestOptions.groupId,\n confirmItemControl: requestOptions.confirmItemControl,\n };\n return request(url, requestOptions);\n}\nexport function ensureMembership(currentUser, ownerUser, shouldPromote, errorMessage, requestOptions) {\n var _a;\n var ownerGroups = ownerUser.groups || [];\n var group = ownerGroups.find(function (g) {\n return g.id === requestOptions.groupId;\n });\n // if they are in different orgs, eject\n if (currentUser.orgId !== ownerUser.orgId) {\n throw Error(\"User \" + ownerUser.username + \" is not a member of the same org as \" + currentUser.username + \". Consequently they can not be added added to group \" + requestOptions.groupId + \" nor can item \" + requestOptions.id + \" be shared to the group.\");\n }\n // if owner is not a member, and has 512 groups\n if (!group && ownerGroups.length > 511) {\n throw Error(\"User \" + ownerUser.username + \" already has 512 groups, and can not be added to group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" can not be shared to the group.\");\n }\n var promise;\n var revert;\n // decide if we need to add them or upgrade them\n if (group) {\n // they are in the group...\n // check member type\n if (shouldPromote && group.userMembership.memberType === \"member\") {\n // promote them\n promise = updateUserMemberships({\n id: requestOptions.groupId,\n users: [ownerUser.username],\n newMemberType: \"admin\",\n authentication: requestOptions.authentication,\n })\n .then(function (results) {\n // convert the result into the right type\n var notAdded = results.results.reduce(function (acc, entry) {\n if (!entry.success) {\n acc.push(entry.username);\n }\n return acc;\n }, []);\n // and return it\n return Promise.resolve({ notAdded: notAdded });\n })\n .catch(function () { return ({ notAdded: [ownerUser.username] }); });\n revert = function (sharingResults) {\n return updateUserMemberships({\n id: requestOptions.groupId,\n users: [ownerUser.username],\n newMemberType: \"member\",\n authentication: requestOptions.authentication,\n })\n .then(function () { return sharingResults; })\n .catch(function () { return sharingResults; });\n };\n }\n else {\n // they are already an admin in the group\n // return the same response the API would if we added them\n promise = Promise.resolve({ notAdded: [] });\n revert = function (sharingResults) { return Promise.resolve(sharingResults); };\n }\n }\n else {\n // attempt to add user to group\n var userType = shouldPromote ? \"admins\" : \"users\";\n // can't currently determine if the group is within the admin's\n // org without performing a search, so attempt to add and handle\n // the api error\n promise = addGroupUsers((_a = {\n id: requestOptions.groupId\n },\n _a[userType] = [ownerUser.username],\n _a.authentication = requestOptions.authentication,\n _a))\n .then(function (results) {\n // results.errors includes an ArcGISAuthError when the group\n // is in a different org, but notAdded is empty, throw here\n // to normalize the results in below catch\n if (results.errors && results.errors.length) {\n throw results.errors[0];\n }\n return results;\n })\n .catch(function () { return ({ notAdded: [ownerUser.username] }); });\n revert = function (sharingResults) {\n return removeGroupUsers({\n id: requestOptions.groupId,\n users: [ownerUser.username],\n authentication: requestOptions.authentication,\n }).then(function () {\n // always resolves, suppress any resolved errors\n return sharingResults;\n });\n };\n }\n return {\n promise: promise.then(function (membershipResponse) {\n if (membershipResponse.notAdded.length) {\n throw new Error(errorMessage);\n }\n return membershipResponse;\n }),\n revert: revert,\n };\n}\n//# sourceMappingURL=share-item-with-group.js.map","import { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { getUserMembership } from \"./helpers\";\nimport { isItemSharedWithGroup } from \"./is-item-shared-with-group\";\nimport { getUser } from \"../users/get-user\";\n/**\n * Stop sharing an item with a group, either as an\n * [item owner](https://developers.arcgis.com/rest/users-groups-and-items/unshare-item-as-item-owner-.htm),\n * [group admin](https://developers.arcgis.com/rest/users-groups-and-items/unshare-item-as-group-admin-.htm) or\n * organization admin.\n *\n * ```js\n * import { unshareItemWithGroup } from '@esri/arcgis-rest-portal';\n *\n * unshareItemWithGroup({\n * id: \"abc123\",\n * groupId: \"xyz987\",\n * owner: \"some-owner\",\n * authentication: session\n * })\n * ```\n *\n * @param requestOptions - Options for the request.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function unshareItemWithGroup(requestOptions) {\n return isItemSharedWithGroup(requestOptions)\n .then(function (isShared) {\n // not shared\n if (!isShared) {\n // exit early with success response\n return Promise.resolve({\n itemId: requestOptions.id,\n shortcut: true,\n notUnsharedFrom: []\n });\n }\n var username = requestOptions.authentication.username, owner = requestOptions.owner;\n // next check if the user is a member of the group\n return Promise.all([\n getUserMembership(requestOptions),\n getUser({\n username: username,\n authentication: requestOptions.authentication\n })\n ])\n .then(function (_a) {\n var membership = _a[0], currentUser = _a[1];\n var itemOwner = owner || username;\n var isItemOwner = itemOwner === username;\n var isAdmin = currentUser.role === 'org_admin' && !currentUser.roleId;\n if (!isItemOwner && !isAdmin && ['admin', 'owner'].indexOf(membership) < 0) {\n // abort and reject promise\n throw Error(\"This item can not be unshared from group \" + requestOptions.groupId + \" by \" + username + \" as they not the item owner, an org admin, group admin or group owner.\");\n }\n // let the sharing call go\n return unshareFromGroup(requestOptions);\n })\n .then(function (sharingResponse) {\n if (sharingResponse.notUnsharedFrom.length) {\n throw Error(\"Item \" + requestOptions.id + \" could not be unshared to group \" + requestOptions.groupId);\n }\n else {\n // all is well\n return sharingResponse;\n }\n });\n });\n}\nfunction unshareFromGroup(requestOptions) {\n var username = requestOptions.authentication.username;\n var itemOwner = requestOptions.owner || username;\n // decide what url to use\n // default to the non-owner url...\n var url = getPortalUrl(requestOptions) + \"/content/items/\" + requestOptions.id + \"/unshare\";\n // but if they are the owner, we use a different path...\n if (itemOwner === username) {\n url = getPortalUrl(requestOptions) + \"/content/users/\" + itemOwner + \"/items/\" + requestOptions.id + \"/unshare\";\n }\n // now its finally time to do the sharing\n requestOptions.params = {\n groups: requestOptions.groupId\n };\n return request(url, requestOptions);\n}\n//# sourceMappingURL=unshare-item-with-group.js.map","import { getPortalUrl as getPortalApiUrl, } from \"@esri/arcgis-rest-portal\";\n/**\n * ```js\n * import { getPortalUrl } from \"@esri/hub-common\";\n * // from a portal API URL\n * let portalUrl = getPortalUrl(\"https://org.maps.arcgis.com/sharing/rest\"); // https://org.maps.arcgis.com\n * // from an enterprise portal self response (IPortal)\n * let portalSelf = { isPortal: true, portalHostname: \"server.example.org\" };\n * portalUrl = getPortalUrl(portalSelf); // https://server.example.org\n * // from an online portal self response (IPortal)\n * portalSelf = { isPortal: false, urlKey: \"org\", customBaseUrl: \"maps.arcgis.com\" };\n * portalUrl = getPortalUrl(portalSelf); // https://org.maps.arcgis.com\n * // from hub request options (IHubRequestOptions) with a portal self (IPortal)\n * let requestOptions = { isPortal: false, portalSelf };\n * portalUrl = getPortalUrl(requestOptions); // https://org.maps.arcgis.com\n * // from request options (IRequestOptions) with a portal (string)\n * requestOptions = { portal: \"https://org.maps.arcgis.com/sharing/rest\" };\n * portalUrl = getPortalUrl(requestOptions); // https://org.maps.arcgis.com\n * ```\n * Derive a portal's base URL from the portal's API URL, a portal object, or request options\n * @param urlOrObject a portal API URL, a portal object, or request options containing either of those\n * @returns The portal base URL, defaults to `https://www.arcgis.com`\n */\nexport function getPortalUrl(urlOrObject) {\n if (typeof urlOrObject === \"string\") {\n // assume this is the URL of the portal API\n // and strip the `/sharing/rest`\n return urlOrObject.replace(/\\/sharing\\/rest\\/?$/, \"\");\n }\n if (typeof urlOrObject === \"object\") {\n // build URL from portal self object, which could be\n // either a property of the object (request options) or the object itself\n var portalSelf = urlOrObject.portalSelf;\n var portal = portalSelf || urlOrObject;\n var portalHostname = portal.portalHostname, urlKey = portal.urlKey, customBaseUrl = portal.customBaseUrl;\n if (portalHostname || (urlKey && customBaseUrl)) {\n // user passed in a portal object, we'll use that to build the URL\n if (portal.isPortal) {\n return \"https://\" + portal.portalHostname;\n }\n else {\n return \"https://\" + portal.urlKey + \".\" + portal.customBaseUrl;\n }\n }\n }\n // urlOrObj is either undefined, or a request options w/o portal self\n // get portal API URL and parse portal URL from that\n return getPortalUrl(getPortalApiUrl(urlOrObject));\n}\n//# sourceMappingURL=get-portal-url.js.map","/**\n * Mapping between the AGO Env's and the Hub's asset CDNs\n */\nexport var HUB_CDN_URLMAP = {\n devext: \"https://d1011m9qpnz5mw.cloudfront.net\",\n qaext: \"https://dyq9ux9ryu4qj.cloudfront.net\",\n www: \"https://d1iq7pbacwn5rb.cloudfront.net\"\n};\n//# sourceMappingURL=hub-cdn-urlmap.js.map","import { getPortalUrl } from \"./get-portal-url\";\nimport { HUB_CDN_URLMAP } from \"./hub-cdn-urlmap\";\n// TODO: should this take IHubRequestOptions as well as a portal?\n// if so, address when we tackle https://github.com/Esri/hub.js/issues/321\n/**\n * Given a Portal object, return the full Hub locale asset url\n * Used for fetching translations\n * @param {Object} portal Portal Self\n */\nexport function getHubLocaleAssetUrl(portal) {\n if (portal.isPortal) {\n // Enterprise - use Site app as source for assets\n var baseUrl = getPortalUrl(portal);\n return baseUrl + \"/apps/sites\";\n }\n else {\n // AGO - Convert portalHostname into CDN url\n var index = portal.portalHostname.split(\".\")[0];\n var base = HUB_CDN_URLMAP[index] || HUB_CDN_URLMAP.www;\n return base + \"/opendata-ui/assets\";\n }\n}\n//# sourceMappingURL=get-hub-locale-asset-url.js.map","import { getPortalUrl } from \"./get-portal-url\";\n/**\n * ```js\n * import { getPortalApiUrl } from \"@esri/hub-common\";\n * // from a portal base URL\n * let portalApiUrl = getPortalApiUrl(\"https://org.maps.arcgis.com\"); // https://org.maps.arcgis.com/sharing/rest\n * // from an enterprise portal self response (IPortal)\n * let portalSelf = { isPortal: true, portalHostname: \"server.example.org\" };\n * portalApiUrl = getPortalApiUrl(portalSelf); // https://server.example.org/sharing/rest\n * // from an online portal self response (IPortal)\n * portalSelf = { isPortal: false, urlKey: \"org\", customBaseUrl: \"maps.arcgis.com\" };\n * portalApiUrl = getPortalApiUrl(portalSelf); // https://org.maps.arcgis.com/sharing/rest\n * // from hub request options (IHubRequestOptions) with a portal self (IPortal)\n * let requestOptions = { isPortal: false, portalSelf };\n * portalApiUrl = getPortalApiUrl(requestOptions); // https://org.maps.arcgis.com/sharing/rest\n * // from request options (IRequestOptions) with a portal (string)\n * requestOptions = { portal: \"https://org.maps.arcgis.com/sharing/rest\" };\n * portalApiUrl = getPortalApiUrl(requestOptions); // https://org.maps.arcgis.com/sharing/rest\n * ```\n * Derive a portal's API URL from the portal's base URL, a portal object, or request options\n * @param urlOrObject a portal base URL, a portal object, or request options containing either of those\n * @returns The portal API URL, defaults to `https://www.arcgis.com/sharing/rest`\n */\nexport function getPortalApiUrl(urlOrObject) {\n return getPortalUrl(urlOrObject) + \"/sharing/rest\";\n}\n//# sourceMappingURL=get-portal-api-url.js.map","/**\n * Add protocol or upgrade http to https\n * @param {string} url\n */\nexport function upgradeProtocol(url) {\n if (url.indexOf(\"http\") === -1) {\n return \"https://\" + url;\n }\n else if (url.indexOf(\"http://\") !== -1) {\n return url.replace(/^http:/i, \"https:\");\n }\n return url;\n}\n//# sourceMappingURL=upgrade-protocol.js.map","/**\n * Remove protocol if present\n * @param {string} hostname Hostname\n */\nexport function stripProtocol(hostname) {\n hostname = hostname.toLowerCase();\n if (hostname.includes(\"//\")) {\n hostname = hostname.split(\"//\")[1];\n }\n return hostname;\n}\n//# sourceMappingURL=strip-protocol.js.map","/**\n * Given a url without a protocol or with either http or https, return an array\n * that contains both the http and https version\n * @param {string} uri Url with either http or https, or no protocol\n * @private\n */\nexport function _getHttpAndHttpsUris(uri) {\n if (!uri) {\n return [];\n }\n var domain = uri.replace(/^http(s?):\\/\\//, \"\");\n return [\"http://\" + domain, \"https://\" + domain];\n}\n//# sourceMappingURL=_get-http-and-https-uris.js.map","/**\n * Wrapper over window.location\n * @private\n */\n/* istanbul ignore next */\nexport function _getLocation() {\n /* istanbul ignore next */\n if (window) {\n return window.location;\n }\n}\n//# sourceMappingURL=_get-location.js.map","/**\n * Parse the portal url, and if it matches one of the AGO\n * Url patterns, return the correct Hub Url\n * If portalUrl does not match an AGO pattern, this will\n * return `undefined`\n * @param portalUrl\n * @private\n */\nexport function _getHubUrlFromPortalHostname(portalUrl) {\n var result;\n if (portalUrl.match(/(qaext|\\.mapsqa)\\.arcgis.com/)) {\n result = \"https://hubqa.arcgis.com\";\n }\n else if (portalUrl.match(/(devext|\\.mapsdevext)\\.arcgis.com/)) {\n result = \"https://hubdev.arcgis.com\";\n }\n else if (portalUrl.match(/(www|\\.maps)\\.arcgis.com/)) {\n result = \"https://hub.arcgis.com\";\n }\n return result;\n}\n//# sourceMappingURL=_get-hub-url-from-portal-hostname.js.map","import { _getHubUrlFromPortalHostname } from \"./_get-hub-url-from-portal-hostname\";\n/**\n * Return the Hub Url based on the portal self\n * @param portal\n */\nexport function getHubUrlFromPortal(portal) {\n if (portal.isPortal) {\n throw new Error(\"Hub Url is not available in ArcGIS Enterprise\");\n }\n else {\n return _getHubUrlFromPortalHostname(portal.portalHostname);\n }\n}\n//# sourceMappingURL=get-hub-url-from-portal.js.map","import { getHubUrlFromPortal } from \"./get-hub-url-from-portal\";\n/**\n * Return the Portal url based on the portal self\n * @param {Object} portal Portal Self\n */\nexport function getHubApiUrlFromPortal(portal) {\n return getHubUrlFromPortal(portal) + \"/api/v3\";\n}\n//# sourceMappingURL=get-hub-api-url-from-portal.js.map","import { getPortalUrl } from \"./get-portal-url\";\n/**\n * Return the URL of the item's page in the Portal Home application\n * @param itemId The item's ID\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @returns URL to the item's data REST end point, defaults to `https://www.arcgis.com/home/item.html?id={item.id}`\n */\nexport function getItemHomeUrl(itemId, portalUrlOrObject) {\n var portalUrl = getPortalUrl(portalUrlOrObject);\n return portalUrl + \"/home/item.html?id=\" + itemId;\n}\n//# sourceMappingURL=get-item-home-url.js.map","import { getPortalApiUrl } from \"./get-portal-api-url\";\n// NOTE: this fn is tested via getItemDataUrl tests\n/**\n * Get the fully qualified URL to the REST end point for an item.\n * @param item w/ id and access\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @param token token for the current user's session; will only be appended as a query parameter if the item's access is **not** `public`\n * @returns URL to the item's REST end point, defaults to `https://www.arcgis.com/sharing/rest/content/items/{item.id}?f=json`\n */\nexport var getItemApiUrl = function (item, portalUrlOrObject, token) {\n var id = item.id, access = item.access;\n var url = getPortalApiUrl(portalUrlOrObject) + \"/content/items/\" + id;\n var params = new URLSearchParams({ f: \"json\" });\n if (access !== \"public\" && token) {\n params.append(\"token\", token);\n }\n return url + \"?\" + params.toString();\n};\n//# sourceMappingURL=get-item-api-url.js.map","import { getItemApiUrl } from \"./get-item-api-url\";\n/**\n * Get the fully qualified URL to the data REST end point for an item\n * @param item w/ id and access\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @param token token for the current user's session; will only be appended as a query parameter if the item's access is **not** `public`\n * @returns URL to the item's data REST end point, defaults to `https://www.arcgis.com/sharing/rest/content/items/{item.id}/data`\n */\nexport var getItemDataUrl = function (item, portalUrlOrObject, token) {\n var url = getItemApiUrl(item, portalUrlOrObject, token);\n var pattern = \"\\\\/\" + item.id + \"\\\\?f=json\";\n var regExp = new RegExp(pattern);\n // TODO: re-append f param based on item.type?\n return (url && url.replace(regExp, \"/\" + item.id + \"/data\").replace(/\\&token/, \"?token\"));\n};\n//# sourceMappingURL=get-item-data-url.js.map","/**\n * Convert urls in a string to hyperlinks\n * @param {content} string\n */\nexport function convertUrlsToAnchorTags(content) {\n var urls = content.match(/((((ftp|https?):\\/\\/)|(w{3}\\.))[-\\w@:%_+.~#?,&//=]+)/g);\n if (urls) {\n urls.forEach(function (url) {\n content = content.replace(url, '<a target=\"_blank\" href=\"' + url + '\">' + url + \"</a>\");\n });\n }\n return content.replace(\"(\", \"<br/>(\");\n}\n//# sourceMappingURL=convert-urls-to-anchor-tags.js.map","import { capitalize } from \"../util\";\nexport * from \"./build-url\";\nexport * from \"./get-hub-locale-asset-url\";\nexport * from \"./get-portal-api-url\";\nexport * from \"./get-portal-url\";\nexport * from \"./hub-cdn-urlmap\";\nexport * from \"./upgrade-protocol\";\nexport * from \"./strip-protocol\";\nexport * from \"./_get-http-and-https-uris\";\nexport * from \"./_get-location\";\nexport * from \"./get-hub-api-url-from-portal\";\nexport * from \"./get-hub-url-from-portal\";\nexport * from \"./get-item-home-url\";\nexport * from \"./get-item-api-url\";\nexport * from \"./get-item-data-url\";\nexport * from \"./convert-urls-to-anchor-tags\";\nvar MAP_OR_FEATURE_SERVER_URL_REGEX = /\\/(map|feature)server/i;\n/**\n *\n * @param url\n * @returns true if the url is of a map or feature service\n */\nexport var isMapOrFeatureServerUrl = function (url) {\n return MAP_OR_FEATURE_SERVER_URL_REGEX.test(url);\n};\n/**\n * parses map or feature service type from URL\n * @param url map or feature service URL\n * @returns item type, either \"Map Service\" or \"Feature Service\"\n * or undefined for other types of URLs\n */\nexport var getServiceTypeFromUrl = function (url) {\n var match = url.match(MAP_OR_FEATURE_SERVER_URL_REGEX);\n var mapOrFeature = match && match[1];\n return mapOrFeature && capitalize(mapOrFeature) + \" Service\";\n};\n//# sourceMappingURL=index.js.map","import { getPortalApiUrl } from \"./urls\";\nimport { _getHubUrlFromPortalHostname } from \"./urls/_get-hub-url-from-portal-hostname\";\n/**\n * ```js\n * import { getHubApiUrl() } from \"@esri/hub-common\";\n * //\n * getHubApiUrl({ portal: \"https://custom.maps.arcgis.com/sharing/rest\" })\n * >> \"https://hub.arcgis.com\"\n * ```\n * Retrieves the Hub API Url associated with a specific ArcGIS Online organization.\n * @param urlOrObject a Portal URL, Portal API URL, request options object, or Portal self object\n * @returns the associated Hub API Url as a string.\n */\nexport function getHubApiUrl(urlOrObject) {\n var hubApiUrl = urlOrObject && urlOrObject.hubApiUrl;\n if (hubApiUrl) {\n // this is request options w/ hubApiUrl already defined\n return hubApiUrl;\n }\n return _getHubUrlFromPortalHostname(getPortalApiUrl(urlOrObject));\n}\n//# sourceMappingURL=api.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nexport function fetchToken(url, requestOptions) {\n var options = requestOptions;\n // we generate a response, so we can't return the raw response\n options.rawResponse = false;\n return request(url, options).then(function (response) {\n var r = {\n token: response.access_token,\n username: response.username,\n expires: new Date(\n // convert seconds in response to milliseconds and add the value to the current time to calculate a static expiration timestamp\n Date.now() + (response.expires_in * 1000 - 1000)),\n ssl: response.ssl === true\n };\n if (response.refresh_token) {\n r.refreshToken = response.refresh_token;\n }\n return r;\n });\n}\n//# sourceMappingURL=fetch-token.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request, NODEJS_DEFAULT_REFERER_HEADER, } from \"@esri/arcgis-rest-request\";\nexport function generateToken(url, requestOptions) {\n var options = requestOptions;\n /* istanbul ignore else */\n if (typeof window !== \"undefined\" &&\n window.location &&\n window.location.host) {\n options.params.referer = window.location.host;\n }\n else {\n options.params.referer = NODEJS_DEFAULT_REFERER_HEADER;\n }\n return request(url, options);\n}\n//# sourceMappingURL=generate-token.js.map","import { cleanUrl } from \"@esri/arcgis-rest-request\";\n/**\n * Used to test if a URL is an ArcGIS Online URL\n */\nvar arcgisOnlineUrlRegex = /^https?:\\/\\/(\\S+)\\.arcgis\\.com.+/;\n/**\n * Used to test if a URL is production ArcGIS Online Portal\n */\nvar arcgisOnlinePortalRegex = /^https?:\\/\\/(dev|devext|qa|qaext|www)\\.arcgis\\.com\\/sharing\\/rest+/;\n/**\n * Used to test if a URL is an ArcGIS Online Organization Portal\n */\nvar arcgisOnlineOrgPortalRegex = /^https?:\\/\\/(?:[a-z0-9-]+\\.maps(dev|devext|qa|qaext)?)?.arcgis\\.com\\/sharing\\/rest/;\nexport function isOnline(url) {\n return arcgisOnlineUrlRegex.test(url);\n}\nexport function normalizeOnlinePortalUrl(portalUrl) {\n if (!arcgisOnlineUrlRegex.test(portalUrl)) {\n return portalUrl;\n }\n switch (getOnlineEnvironment(portalUrl)) {\n case \"dev\":\n return \"https://devext.arcgis.com/sharing/rest\";\n case \"qa\":\n return \"https://qaext.arcgis.com/sharing/rest\";\n default:\n return \"https://www.arcgis.com/sharing/rest\";\n }\n}\nexport function getOnlineEnvironment(url) {\n if (!arcgisOnlineUrlRegex.test(url)) {\n return null;\n }\n var match = url.match(arcgisOnlineUrlRegex);\n var subdomain = match[1].split(\".\").pop();\n if (subdomain.includes(\"dev\")) {\n return \"dev\";\n }\n if (subdomain.includes(\"qa\")) {\n return \"qa\";\n }\n return \"production\";\n}\nexport function isFederated(owningSystemUrl, portalUrl) {\n var normalizedPortalUrl = cleanUrl(normalizeOnlinePortalUrl(portalUrl)).replace(/https?:\\/\\//, \"\");\n var normalizedOwningSystemUrl = cleanUrl(owningSystemUrl).replace(/https?:\\/\\//, \"\");\n return new RegExp(normalizedOwningSystemUrl, \"i\").test(normalizedPortalUrl);\n}\nexport function canUseOnlineToken(portalUrl, requestUrl) {\n var portalIsOnline = isOnline(portalUrl);\n var requestIsOnline = isOnline(requestUrl);\n var portalEnv = getOnlineEnvironment(portalUrl);\n var requestEnv = getOnlineEnvironment(requestUrl);\n if (portalIsOnline && requestIsOnline && portalEnv === requestEnv) {\n return true;\n }\n return false;\n}\n//# sourceMappingURL=federation-utils.js.map","/* Copyright (c) 2018-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\n/**\n * Validates that the user has access to the application\n * and if they user should be presented a \"View Only\" mode\n *\n * This is only needed/valid for Esri applications that are \"licensed\"\n * and shipped in ArcGIS Online or ArcGIS Enterprise. Most custom applications\n * should not need or use this.\n *\n * ```js\n * import { validateAppAccess } from '@esri/arcgis-rest-auth';\n *\n * return validateAppAccess('your-token', 'theClientId')\n * .then((result) => {\n * if (!result.value) {\n * // redirect or show some other ui\n * } else {\n * if (result.viewOnlyUserTypeApp) {\n * // use this to inform your app to show a \"View Only\" mode\n * }\n * }\n * })\n * .catch((err) => {\n * // two possible errors\n * // invalid clientId: {\"error\":{\"code\":400,\"messageCode\":\"GWM_0007\",\"message\":\"Invalid request\",\"details\":[]}}\n * // invalid token: {\"error\":{\"code\":498,\"message\":\"Invalid token.\",\"details\":[]}}\n * })\n * ```\n *\n * Note: This is only usable by Esri applications hosted on *arcgis.com, *esri.com or within\n * an ArcGIS Enterprise installation. Custom applications can not use this.\n *\n * @param token platform token\n * @param clientId application client id\n * @param portal Optional\n */\nexport function validateAppAccess(token, clientId, portal) {\n if (portal === void 0) { portal = \"https://www.arcgis.com/sharing/rest\"; }\n var url = portal + \"/oauth2/validateAppAccess\";\n var ro = {\n method: \"POST\",\n params: {\n f: \"json\",\n client_id: clientId,\n token: token,\n },\n };\n return request(url, ro);\n}\n//# sourceMappingURL=validate-app-access.js.map","/* Copyright (c) 2017-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, ArcGISAuthError, cleanUrl, encodeQueryString, decodeQueryString, } from \"@esri/arcgis-rest-request\";\nimport { generateToken } from \"./generate-token\";\nimport { fetchToken } from \"./fetch-token\";\nimport { canUseOnlineToken, isFederated } from \"./federation-utils\";\nimport { validateAppAccess } from \"./validate-app-access\";\nfunction defer() {\n var deferred = {\n promise: null,\n resolve: null,\n reject: null,\n };\n deferred.promise = new Promise(function (resolve, reject) {\n deferred.resolve = resolve;\n deferred.reject = reject;\n });\n return deferred;\n}\n/**\n * ```js\n * import { UserSession } from '@esri/arcgis-rest-auth';\n * UserSession.beginOAuth2({\n * // register an app of your own to create a unique clientId\n * clientId: \"abc123\",\n * redirectUri: 'https://yourapp.com/authenticate.html'\n * })\n * .then(session)\n * // or\n * new UserSession({\n * username: \"jsmith\",\n * password: \"123456\"\n * })\n * // or\n * UserSession.deserialize(cache)\n * ```\n * Used to authenticate both ArcGIS Online and ArcGIS Enterprise users. `UserSession` includes helper methods for [OAuth 2.0](/arcgis-rest-js/guides/browser-authentication/) in both browser and server applications.\n */\nvar UserSession = /** @class */ (function () {\n function UserSession(options) {\n this.clientId = options.clientId;\n this._refreshToken = options.refreshToken;\n this._refreshTokenExpires = options.refreshTokenExpires;\n this.username = options.username;\n this.password = options.password;\n this._token = options.token;\n this._tokenExpires = options.tokenExpires;\n this.portal = options.portal\n ? cleanUrl(options.portal)\n : \"https://www.arcgis.com/sharing/rest\";\n this.ssl = options.ssl;\n this.provider = options.provider || \"arcgis\";\n this.tokenDuration = options.tokenDuration || 20160;\n this.redirectUri = options.redirectUri;\n this.refreshTokenTTL = options.refreshTokenTTL || 20160;\n this.server = options.server;\n this.federatedServers = {};\n this.trustedDomains = [];\n // if a non-federated server was passed explicitly, it should be trusted.\n if (options.server) {\n // if the url includes more than '/arcgis/', trim the rest\n var root = this.getServerRootUrl(options.server);\n this.federatedServers[root] = {\n token: options.token,\n expires: options.tokenExpires,\n };\n }\n this._pendingTokenRequests = {};\n }\n Object.defineProperty(UserSession.prototype, \"token\", {\n /**\n * The current ArcGIS Online or ArcGIS Enterprise `token`.\n */\n get: function () {\n return this._token;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"tokenExpires\", {\n /**\n * The expiration time of the current `token`.\n */\n get: function () {\n return this._tokenExpires;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"refreshToken\", {\n /**\n * The current token to ArcGIS Online or ArcGIS Enterprise.\n */\n get: function () {\n return this._refreshToken;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"refreshTokenExpires\", {\n /**\n * The expiration time of the current `refreshToken`.\n */\n get: function () {\n return this._refreshTokenExpires;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"trustedServers\", {\n /**\n * Deprecated, use `federatedServers` instead.\n *\n * @deprecated\n */\n get: function () {\n console.log(\"DEPRECATED: use federatedServers instead\");\n return this.federatedServers;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Begins a new browser-based OAuth 2.0 sign in. If `options.popup` is `true` the\n * authentication window will open in a new tab/window and the function will return\n * Promise&lt;UserSession&gt;. Otherwise, the user will be redirected to the\n * authorization page in their current tab/window and the function will return `undefined`.\n *\n * @browserOnly\n */\n /* istanbul ignore next */\n UserSession.beginOAuth2 = function (options, win) {\n if (win === void 0) { win = window; }\n if (options.duration) {\n console.log(\"DEPRECATED: 'duration' is deprecated - use 'expiration' instead\");\n }\n var _a = __assign({\n portal: \"https://www.arcgis.com/sharing/rest\",\n provider: \"arcgis\",\n expiration: 20160,\n popup: true,\n popupWindowFeatures: \"height=400,width=600,menubar=no,location=yes,resizable=yes,scrollbars=yes,status=yes\",\n state: options.clientId,\n locale: \"\",\n }, options), portal = _a.portal, provider = _a.provider, clientId = _a.clientId, expiration = _a.expiration, redirectUri = _a.redirectUri, popup = _a.popup, popupWindowFeatures = _a.popupWindowFeatures, state = _a.state, locale = _a.locale, params = _a.params;\n var url;\n if (provider === \"arcgis\") {\n url = portal + \"/oauth2/authorize?client_id=\" + clientId + \"&response_type=token&expiration=\" + (options.duration || expiration) + \"&redirect_uri=\" + encodeURIComponent(redirectUri) + \"&state=\" + state + \"&locale=\" + locale;\n }\n else {\n url = portal + \"/oauth2/social/authorize?client_id=\" + clientId + \"&socialLoginProviderName=\" + provider + \"&autoAccountCreateForSocial=true&response_type=token&expiration=\" + (options.duration || expiration) + \"&redirect_uri=\" + encodeURIComponent(redirectUri) + \"&state=\" + state + \"&locale=\" + locale;\n }\n // append additional params\n if (params) {\n url = url + \"&\" + encodeQueryString(params);\n }\n if (!popup) {\n win.location.href = url;\n return undefined;\n }\n var session = defer();\n win[\"__ESRI_REST_AUTH_HANDLER_\" + clientId] = function (errorString, oauthInfoString) {\n if (errorString) {\n var error = JSON.parse(errorString);\n session.reject(new ArcGISAuthError(error.errorMessage, error.error));\n return;\n }\n if (oauthInfoString) {\n var oauthInfo = JSON.parse(oauthInfoString);\n session.resolve(new UserSession({\n clientId: clientId,\n portal: portal,\n ssl: oauthInfo.ssl,\n token: oauthInfo.token,\n tokenExpires: new Date(oauthInfo.expires),\n username: oauthInfo.username,\n }));\n }\n };\n win.open(url, \"oauth-window\", popupWindowFeatures);\n return session.promise;\n };\n /**\n * Completes a browser-based OAuth 2.0 sign in. If `options.popup` is `true` the user\n * will be returned to the previous window. Otherwise a new `UserSession`\n * will be returned. You must pass the same values for `options.popup` and\n * `options.portal` as you used in `beginOAuth2()`.\n *\n * @browserOnly\n */\n /* istanbul ignore next */\n UserSession.completeOAuth2 = function (options, win) {\n if (win === void 0) { win = window; }\n var _a = __assign({ portal: \"https://www.arcgis.com/sharing/rest\", popup: true }, options), portal = _a.portal, clientId = _a.clientId, popup = _a.popup;\n function completeSignIn(error, oauthInfo) {\n try {\n var handlerFn = void 0;\n var handlerFnName = \"__ESRI_REST_AUTH_HANDLER_\" + clientId;\n if (popup) {\n // Guard b/c IE does not support window.opener\n if (win.opener) {\n if (win.opener.parent && win.opener.parent[handlerFnName]) {\n handlerFn = win.opener.parent[handlerFnName];\n }\n else if (win.opener && win.opener[handlerFnName]) {\n // support pop-out oauth from within an iframe\n handlerFn = win.opener[handlerFnName];\n }\n }\n else {\n // IE\n if (win !== win.parent && win.parent && win.parent[handlerFnName]) {\n handlerFn = win.parent[handlerFnName];\n }\n }\n // if we have a handler fn, call it and close the window\n if (handlerFn) {\n handlerFn(error ? JSON.stringify(error) : undefined, JSON.stringify(oauthInfo));\n win.close();\n return undefined;\n }\n }\n }\n catch (e) {\n throw new ArcGISAuthError(\"Unable to complete authentication. It's possible you specified popup based oAuth2 but no handler from \\\"beginOAuth2()\\\" present. This generally happens because the \\\"popup\\\" option differs between \\\"beginOAuth2()\\\" and \\\"completeOAuth2()\\\".\");\n }\n if (error) {\n throw new ArcGISAuthError(error.errorMessage, error.error);\n }\n return new UserSession({\n clientId: clientId,\n portal: portal,\n ssl: oauthInfo.ssl,\n token: oauthInfo.token,\n tokenExpires: oauthInfo.expires,\n username: oauthInfo.username,\n });\n }\n var params = decodeQueryString(win.location.hash);\n if (!params.access_token) {\n var error = void 0;\n var errorMessage = \"Unknown error\";\n if (params.error) {\n error = params.error;\n errorMessage = params.error_description;\n }\n return completeSignIn({ error: error, errorMessage: errorMessage });\n }\n var token = params.access_token;\n var expires = new Date(Date.now() + parseInt(params.expires_in, 10) * 1000 - 60 * 1000);\n var username = params.username;\n var ssl = params.ssl === \"true\";\n return completeSignIn(undefined, {\n token: token,\n expires: expires,\n ssl: ssl,\n username: username,\n });\n };\n /**\n * Request session information from the parent application\n *\n * When an application is embedded into another application via an IFrame, the embedded app can\n * use `window.postMessage` to request credentials from the host application. This function wraps\n * that behavior.\n *\n * The ArcGIS API for Javascript has this built into the Identity Manager as of the 4.19 release.\n *\n * Note: The parent application will not respond if the embedded app's origin is not:\n * - the same origin as the parent or *.arcgis.com (JSAPI)\n * - in the list of valid child origins (REST-JS)\n *\n *\n * @param parentOrigin origin of the parent frame. Passed into the embedded application as `parentOrigin` query param\n * @browserOnly\n */\n UserSession.fromParent = function (parentOrigin, win) {\n /* istanbul ignore next: must pass in a mockwindow for tests so we can't cover the other branch */\n if (!win && window) {\n win = window;\n }\n // Declare handler outside of promise scope so we can detach it\n var handler;\n // return a promise that will resolve when the handler receives\n // session information from the correct origin\n return new Promise(function (resolve, reject) {\n // create an event handler that just wraps the parentMessageHandler\n handler = function (event) {\n // ensure we only listen to events from the parent\n if (event.source === win.parent && event.data) {\n try {\n return resolve(UserSession.parentMessageHandler(event));\n }\n catch (err) {\n return reject(err);\n }\n }\n };\n // add listener\n win.addEventListener(\"message\", handler, false);\n win.parent.postMessage({ type: \"arcgis:auth:requestCredential\" }, parentOrigin);\n }).then(function (session) {\n win.removeEventListener(\"message\", handler, false);\n return session;\n });\n };\n /**\n * Begins a new server-based OAuth 2.0 sign in. This will redirect the user to\n * the ArcGIS Online or ArcGIS Enterprise authorization page.\n *\n * @nodeOnly\n */\n UserSession.authorize = function (options, response) {\n if (options.duration) {\n console.log(\"DEPRECATED: 'duration' is deprecated - use 'expiration' instead\");\n }\n var _a = __assign({ portal: \"https://arcgis.com/sharing/rest\", expiration: 20160 }, options), portal = _a.portal, clientId = _a.clientId, expiration = _a.expiration, redirectUri = _a.redirectUri;\n response.writeHead(301, {\n Location: portal + \"/oauth2/authorize?client_id=\" + clientId + \"&expiration=\" + (options.duration || expiration) + \"&response_type=code&redirect_uri=\" + encodeURIComponent(redirectUri),\n });\n response.end();\n };\n /**\n * Completes the server-based OAuth 2.0 sign in process by exchanging the `authorizationCode`\n * for a `access_token`.\n *\n * @nodeOnly\n */\n UserSession.exchangeAuthorizationCode = function (options, authorizationCode) {\n var _a = __assign({\n portal: \"https://www.arcgis.com/sharing/rest\",\n refreshTokenTTL: 20160,\n }, options), portal = _a.portal, clientId = _a.clientId, redirectUri = _a.redirectUri, refreshTokenTTL = _a.refreshTokenTTL;\n return fetchToken(portal + \"/oauth2/token\", {\n params: {\n grant_type: \"authorization_code\",\n client_id: clientId,\n redirect_uri: redirectUri,\n code: authorizationCode,\n },\n }).then(function (response) {\n return new UserSession({\n clientId: clientId,\n portal: portal,\n ssl: response.ssl,\n redirectUri: redirectUri,\n refreshToken: response.refreshToken,\n refreshTokenTTL: refreshTokenTTL,\n refreshTokenExpires: new Date(Date.now() + (refreshTokenTTL - 1) * 60 * 1000),\n token: response.token,\n tokenExpires: response.expires,\n username: response.username,\n });\n });\n };\n UserSession.deserialize = function (str) {\n var options = JSON.parse(str);\n return new UserSession({\n clientId: options.clientId,\n refreshToken: options.refreshToken,\n refreshTokenExpires: new Date(options.refreshTokenExpires),\n username: options.username,\n password: options.password,\n token: options.token,\n tokenExpires: new Date(options.tokenExpires),\n portal: options.portal,\n ssl: options.ssl,\n tokenDuration: options.tokenDuration,\n redirectUri: options.redirectUri,\n refreshTokenTTL: options.refreshTokenTTL,\n });\n };\n /**\n * Translates authentication from the format used in the [ArcGIS API for JavaScript](https://developers.arcgis.com/javascript/).\n *\n * ```js\n * UserSession.fromCredential({\n * userId: \"jsmith\",\n * token: \"secret\"\n * });\n * ```\n *\n * @returns UserSession\n */\n UserSession.fromCredential = function (credential) {\n // At ArcGIS Online 9.1, credentials no longer include the ssl and expires properties\n // Here, we provide default values for them to cover this condition\n var ssl = typeof credential.ssl !== \"undefined\" ? credential.ssl : true;\n var expires = credential.expires || Date.now() + 7200000; /* 2 hours */\n return new UserSession({\n portal: credential.server.includes(\"sharing/rest\")\n ? credential.server\n : credential.server + \"/sharing/rest\",\n ssl: ssl,\n token: credential.token,\n username: credential.userId,\n tokenExpires: new Date(expires),\n });\n };\n /**\n * Handle the response from the parent\n * @param event DOM Event\n */\n UserSession.parentMessageHandler = function (event) {\n if (event.data.type === \"arcgis:auth:credential\") {\n return UserSession.fromCredential(event.data.credential);\n }\n if (event.data.type === \"arcgis:auth:error\") {\n var err = new Error(event.data.error.message);\n err.name = event.data.error.name;\n throw err;\n }\n else {\n throw new Error(\"Unknown message type.\");\n }\n };\n /**\n * Returns authentication in a format useable in the [ArcGIS API for JavaScript](https://developers.arcgis.com/javascript/).\n *\n * ```js\n * esriId.registerToken(session.toCredential());\n * ```\n *\n * @returns ICredential\n */\n UserSession.prototype.toCredential = function () {\n return {\n expires: this.tokenExpires.getTime(),\n server: this.portal,\n ssl: this.ssl,\n token: this.token,\n userId: this.username,\n };\n };\n /**\n * Returns information about the currently logged in [user](https://developers.arcgis.com/rest/users-groups-and-items/user.htm). Subsequent calls will *not* result in additional web traffic.\n *\n * ```js\n * session.getUser()\n * .then(response => {\n * console.log(response.role); // \"org_admin\"\n * })\n * ```\n *\n * @param requestOptions - Options for the request. NOTE: `rawResponse` is not supported by this operation.\n * @returns A Promise that will resolve with the data from the response.\n */\n UserSession.prototype.getUser = function (requestOptions) {\n var _this = this;\n if (this._pendingUserRequest) {\n return this._pendingUserRequest;\n }\n else if (this._user) {\n return Promise.resolve(this._user);\n }\n else {\n var url = this.portal + \"/community/self\";\n var options = __assign(__assign({ httpMethod: \"GET\", authentication: this }, requestOptions), { rawResponse: false });\n this._pendingUserRequest = request(url, options).then(function (response) {\n _this._user = response;\n _this._pendingUserRequest = null;\n return response;\n });\n return this._pendingUserRequest;\n }\n };\n /**\n * Returns information about the currently logged in user's [portal](https://developers.arcgis.com/rest/users-groups-and-items/portal-self.htm). Subsequent calls will *not* result in additional web traffic.\n *\n * ```js\n * session.getPortal()\n * .then(response => {\n * console.log(portal.name); // \"City of ...\"\n * })\n * ```\n *\n * @param requestOptions - Options for the request. NOTE: `rawResponse` is not supported by this operation.\n * @returns A Promise that will resolve with the data from the response.\n */\n UserSession.prototype.getPortal = function (requestOptions) {\n var _this = this;\n if (this._pendingPortalRequest) {\n return this._pendingPortalRequest;\n }\n else if (this._portalInfo) {\n return Promise.resolve(this._portalInfo);\n }\n else {\n var url = this.portal + \"/portals/self\";\n var options = __assign(__assign({ httpMethod: \"GET\", authentication: this }, requestOptions), { rawResponse: false });\n this._pendingPortalRequest = request(url, options).then(function (response) {\n _this._portalInfo = response;\n _this._pendingPortalRequest = null;\n return response;\n });\n return this._pendingPortalRequest;\n }\n };\n /**\n * Returns the username for the currently logged in [user](https://developers.arcgis.com/rest/users-groups-and-items/user.htm). Subsequent calls will *not* result in additional web traffic. This is also used internally when a username is required for some requests but is not present in the options.\n *\n * * ```js\n * session.getUsername()\n * .then(response => {\n * console.log(response); // \"casey_jones\"\n * })\n * ```\n */\n UserSession.prototype.getUsername = function () {\n if (this.username) {\n return Promise.resolve(this.username);\n }\n else if (this._user) {\n return Promise.resolve(this._user.username);\n }\n else {\n return this.getUser().then(function (user) {\n return user.username;\n });\n }\n };\n /**\n * Gets an appropriate token for the given URL. If `portal` is ArcGIS Online and\n * the request is to an ArcGIS Online domain `token` will be used. If the request\n * is to the current `portal` the current `token` will also be used. However if\n * the request is to an unknown server we will validate the server with a request\n * to our current `portal`.\n */\n UserSession.prototype.getToken = function (url, requestOptions) {\n if (canUseOnlineToken(this.portal, url)) {\n return this.getFreshToken(requestOptions);\n }\n else if (new RegExp(this.portal, \"i\").test(url)) {\n return this.getFreshToken(requestOptions);\n }\n else {\n return this.getTokenForServer(url, requestOptions);\n }\n };\n /**\n * Get application access information for the current user\n * see `validateAppAccess` function for details\n *\n * @param clientId application client id\n */\n UserSession.prototype.validateAppAccess = function (clientId) {\n return this.getToken(this.portal).then(function (token) {\n return validateAppAccess(token, clientId);\n });\n };\n UserSession.prototype.toJSON = function () {\n return {\n clientId: this.clientId,\n refreshToken: this.refreshToken,\n refreshTokenExpires: this.refreshTokenExpires,\n username: this.username,\n password: this.password,\n token: this.token,\n tokenExpires: this.tokenExpires,\n portal: this.portal,\n ssl: this.ssl,\n tokenDuration: this.tokenDuration,\n redirectUri: this.redirectUri,\n refreshTokenTTL: this.refreshTokenTTL,\n };\n };\n UserSession.prototype.serialize = function () {\n return JSON.stringify(this);\n };\n /**\n * For a \"Host\" app that embeds other platform apps via iframes, after authenticating the user\n * and creating a UserSession, the app can then enable \"post message\" style authentication by calling\n * this method.\n *\n * Internally this adds an event listener on window for the `message` event\n *\n * @param validChildOrigins Array of origins that are allowed to request authentication from the host app\n */\n UserSession.prototype.enablePostMessageAuth = function (validChildOrigins, win) {\n /* istanbul ignore next: must pass in a mockwindow for tests so we can't cover the other branch */\n if (!win && window) {\n win = window;\n }\n this._hostHandler = this.createPostMessageHandler(validChildOrigins);\n win.addEventListener(\"message\", this._hostHandler, false);\n };\n /**\n * For a \"Host\" app that has embedded other platform apps via iframes, when the host needs\n * to transition routes, it should call `UserSession.disablePostMessageAuth()` to remove\n * the event listener and prevent memory leaks\n */\n UserSession.prototype.disablePostMessageAuth = function (win) {\n /* istanbul ignore next: must pass in a mockwindow for tests so we can't cover the other branch */\n if (!win && window) {\n win = window;\n }\n win.removeEventListener(\"message\", this._hostHandler, false);\n };\n /**\n * Manually refreshes the current `token` and `tokenExpires`.\n */\n UserSession.prototype.refreshSession = function (requestOptions) {\n // make sure subsequent calls to getUser() don't returned cached metadata\n this._user = null;\n if (this.username && this.password) {\n return this.refreshWithUsernameAndPassword(requestOptions);\n }\n if (this.clientId && this.refreshToken) {\n return this.refreshWithRefreshToken();\n }\n return Promise.reject(new ArcGISAuthError(\"Unable to refresh token.\"));\n };\n /**\n * Determines the root of the ArcGIS Server or Portal for a given URL.\n *\n * @param url the URl to determine the root url for.\n */\n UserSession.prototype.getServerRootUrl = function (url) {\n var root = cleanUrl(url).split(/\\/rest(\\/admin)?\\/services(?:\\/|#|\\?|$)/)[0];\n var _a = root.match(/(https?:\\/\\/)(.+)/), match = _a[0], protocol = _a[1], domainAndPath = _a[2];\n var _b = domainAndPath.split(\"/\"), domain = _b[0], path = _b.slice(1);\n // only the domain is lowercased because in some cases an org id might be\n // in the path which cannot be lowercased.\n return \"\" + protocol + domain.toLowerCase() + \"/\" + path.join(\"/\");\n };\n /**\n * Returns the proper [`credentials`] option for `fetch` for a given domain.\n * See [trusted server](https://enterprise.arcgis.com/en/portal/latest/administer/windows/configure-security.htm#ESRI_SECTION1_70CC159B3540440AB325BE5D89DBE94A).\n * Used internally by underlying request methods to add support for specific security considerations.\n *\n * @param url The url of the request\n * @returns \"include\" or \"same-origin\"\n */\n UserSession.prototype.getDomainCredentials = function (url) {\n if (!this.trustedDomains || !this.trustedDomains.length) {\n return \"same-origin\";\n }\n return this.trustedDomains.some(function (domainWithProtocol) {\n return url.startsWith(domainWithProtocol);\n })\n ? \"include\"\n : \"same-origin\";\n };\n /**\n * Return a function that closes over the validOrigins array and\n * can be used as an event handler for the `message` event\n *\n * @param validOrigins Array of valid origins\n */\n UserSession.prototype.createPostMessageHandler = function (validOrigins) {\n var _this = this;\n // return a function that closes over the validOrigins and\n // has access to the credential\n return function (event) {\n // Verify that the origin is valid\n // Note: do not use regex's here. validOrigins is an array so we're checking that the event's origin\n // is in the array via exact match. More info about avoiding postMessage xss issues here\n // https://jlajara.gitlab.io/web/2020/07/17/Dom_XSS_PostMessage_2.html#tipsbypasses-in-postmessage-vulnerabilities\n var isValidOrigin = validOrigins.indexOf(event.origin) > -1;\n // JSAPI handles this slightly differently - instead of checking a list, it will respond if\n // event.origin === window.location.origin || event.origin.endsWith('.arcgis.com')\n // For Hub, and to enable cross domain debugging with port's in urls, we are opting to\n // use a list of valid origins\n // Ensure the message type is something we want to handle\n var isValidType = event.data.type === \"arcgis:auth:requestCredential\";\n var isTokenValid = _this.tokenExpires.getTime() > Date.now();\n if (isValidOrigin && isValidType) {\n var msg = {};\n if (isTokenValid) {\n var credential = _this.toCredential();\n // arcgis:auth:error with {name: \"\", message: \"\"}\n // the following line allows us to conform to our spec without changing other depended-on functionality\n // https://github.com/Esri/arcgis-rest-js/blob/master/packages/arcgis-rest-auth/post-message-auth-spec.md#arcgisauthcredential\n credential.server = credential.server.replace(\"/sharing/rest\", \"\");\n msg = { type: \"arcgis:auth:credential\", credential: credential };\n }\n else {\n // Return an error\n msg = {\n type: \"arcgis:auth:error\",\n error: {\n name: \"tokenExpiredError\",\n message: \"Session token was expired, and not returned to the child application\",\n },\n };\n }\n event.source.postMessage(msg, event.origin);\n }\n };\n };\n /**\n * Validates that a given URL is properly federated with our current `portal`.\n * Attempts to use the internal `federatedServers` cache first.\n */\n UserSession.prototype.getTokenForServer = function (url, requestOptions) {\n var _this = this;\n // requests to /rest/services/ and /rest/admin/services/ are both valid\n // Federated servers may have inconsistent casing, so lowerCase it\n var root = this.getServerRootUrl(url);\n var existingToken = this.federatedServers[root];\n if (existingToken &&\n existingToken.expires &&\n existingToken.expires.getTime() > Date.now()) {\n return Promise.resolve(existingToken.token);\n }\n if (this._pendingTokenRequests[root]) {\n return this._pendingTokenRequests[root];\n }\n this._pendingTokenRequests[root] = this.fetchAuthorizedDomains().then(function () {\n return request(root + \"/rest/info\", {\n credentials: _this.getDomainCredentials(url),\n })\n .then(function (response) {\n if (response.owningSystemUrl) {\n /**\n * if this server is not owned by this portal\n * bail out with an error since we know we wont\n * be able to generate a token\n */\n if (!isFederated(response.owningSystemUrl, _this.portal)) {\n throw new ArcGISAuthError(url + \" is not federated with \" + _this.portal + \".\", \"NOT_FEDERATED\");\n }\n else {\n /**\n * if the server is federated, use the relevant token endpoint.\n */\n return request(response.owningSystemUrl + \"/sharing/rest/info\", requestOptions);\n }\n }\n else if (response.authInfo &&\n _this.federatedServers[root] !== undefined) {\n /**\n * if its a stand-alone instance of ArcGIS Server that doesn't advertise\n * federation, but the root server url is recognized, use its built in token endpoint.\n */\n return Promise.resolve({\n authInfo: response.authInfo,\n });\n }\n else {\n throw new ArcGISAuthError(url + \" is not federated with any portal and is not explicitly trusted.\", \"NOT_FEDERATED\");\n }\n })\n .then(function (response) {\n return response.authInfo.tokenServicesUrl;\n })\n .then(function (tokenServicesUrl) {\n // an expired token cant be used to generate a new token\n if (_this.token && _this.tokenExpires.getTime() > Date.now()) {\n return generateToken(tokenServicesUrl, {\n params: {\n token: _this.token,\n serverUrl: url,\n expiration: _this.tokenDuration,\n client: \"referer\",\n },\n });\n // generate an entirely fresh token if necessary\n }\n else {\n return generateToken(tokenServicesUrl, {\n params: {\n username: _this.username,\n password: _this.password,\n expiration: _this.tokenDuration,\n client: \"referer\",\n },\n }).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = new Date(response.expires);\n return response;\n });\n }\n })\n .then(function (response) {\n _this.federatedServers[root] = {\n expires: new Date(response.expires),\n token: response.token,\n };\n delete _this._pendingTokenRequests[root];\n return response.token;\n });\n });\n return this._pendingTokenRequests[root];\n };\n /**\n * Returns an unexpired token for the current `portal`.\n */\n UserSession.prototype.getFreshToken = function (requestOptions) {\n var _this = this;\n if (this.token && !this.tokenExpires) {\n return Promise.resolve(this.token);\n }\n if (this.token &&\n this.tokenExpires &&\n this.tokenExpires.getTime() > Date.now()) {\n return Promise.resolve(this.token);\n }\n if (!this._pendingTokenRequests[this.portal]) {\n this._pendingTokenRequests[this.portal] = this.refreshSession(requestOptions).then(function (session) {\n _this._pendingTokenRequests[_this.portal] = null;\n return session.token;\n });\n }\n return this._pendingTokenRequests[this.portal];\n };\n /**\n * Refreshes the current `token` and `tokenExpires` with `username` and\n * `password`.\n */\n UserSession.prototype.refreshWithUsernameAndPassword = function (requestOptions) {\n var _this = this;\n var options = __assign({ params: {\n username: this.username,\n password: this.password,\n expiration: this.tokenDuration,\n } }, requestOptions);\n return generateToken(this.portal + \"/generateToken\", options).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = new Date(response.expires);\n return _this;\n });\n };\n /**\n * Refreshes the current `token` and `tokenExpires` with `refreshToken`.\n */\n UserSession.prototype.refreshWithRefreshToken = function (requestOptions) {\n var _this = this;\n if (this.refreshToken &&\n this.refreshTokenExpires &&\n this.refreshTokenExpires.getTime() < Date.now()) {\n return this.refreshRefreshToken(requestOptions);\n }\n var options = __assign({ params: {\n client_id: this.clientId,\n refresh_token: this.refreshToken,\n grant_type: \"refresh_token\",\n } }, requestOptions);\n return fetchToken(this.portal + \"/oauth2/token\", options).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = response.expires;\n return _this;\n });\n };\n /**\n * Exchanges an unexpired `refreshToken` for a new one, also updates `token` and\n * `tokenExpires`.\n */\n UserSession.prototype.refreshRefreshToken = function (requestOptions) {\n var _this = this;\n var options = __assign({ params: {\n client_id: this.clientId,\n refresh_token: this.refreshToken,\n redirect_uri: this.redirectUri,\n grant_type: \"exchange_refresh_token\",\n } }, requestOptions);\n return fetchToken(this.portal + \"/oauth2/token\", options).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = response.expires;\n _this._refreshToken = response.refreshToken;\n _this._refreshTokenExpires = new Date(Date.now() + (_this.refreshTokenTTL - 1) * 60 * 1000);\n return _this;\n });\n };\n /**\n * ensures that the authorizedCrossOriginDomains are obtained from the portal and cached\n * so we can check them later.\n *\n * @returns this\n */\n UserSession.prototype.fetchAuthorizedDomains = function () {\n var _this = this;\n // if this token is for a specific server or we don't have a portal\n // don't get the portal info because we cant get the authorizedCrossOriginDomains\n if (this.server || !this.portal) {\n return Promise.resolve(this);\n }\n return this.getPortal().then(function (portalInfo) {\n /**\n * Specific domains can be configured as secure.esri.com or https://secure.esri.com this\n * normalizes to https://secure.esri.com so we can use startsWith later.\n */\n if (portalInfo.authorizedCrossOriginDomains &&\n portalInfo.authorizedCrossOriginDomains.length) {\n _this.trustedDomains = portalInfo.authorizedCrossOriginDomains\n .filter(function (d) { return !d.startsWith(\"http://\"); })\n .map(function (d) {\n if (d.startsWith(\"https://\")) {\n return d;\n }\n else {\n return \"https://\" + d;\n }\n });\n }\n return _this;\n });\n };\n return UserSession;\n}());\nexport { UserSession };\n//# sourceMappingURL=UserSession.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { UserSession } from \"@esri/arcgis-rest-auth\";\n/**\n * A thin wrapper around [`UserSession.completeOAuth2()`](https://esri.github.io/arcgis-rest-js/api/auth/UserSession/#completeOAuth2) that sets search tags and other relevant metadata for newly created community users.\n */\n/* istanbul ignore next */\nexport function completeOAuth2(options, win) {\n if (win === void 0) { win = window; }\n var match = win.location.href.match(/access_token=(.+)&expires_in=.+&username=([^&]+)/);\n var token = match[1];\n var user = decodeURIComponent(match[2]);\n var baseUrl = \"https://www.arcgis.com/sharing/rest/community/users/\" + user;\n return request(baseUrl, {\n params: { token: token },\n httpMethod: \"GET\"\n }).then(function (response) {\n if (Date.now() - response.created < 5000) {\n return request(baseUrl + \"/update\", {\n params: {\n token: token,\n tags: [\"hubRole:participant\", \"org:\" + response.orgId],\n access: \"public\"\n }\n }).then(function () {\n return UserSession.completeOAuth2(options);\n });\n }\n else {\n return UserSession.completeOAuth2(options);\n }\n });\n}\n//# sourceMappingURL=auth.js.map","var app = [\n \"Application\",\n \"City Engine Web Scene\",\n \"CityEngine Web Scene\",\n \"Dashboard\",\n \"Insights Page\",\n \"Insights Workbook\",\n \"Operation View\",\n \"Web Mapping Application\",\n \"StoryMap\",\n \"Web Experience\",\n \"Urban Model\",\n];\nvar dataset = [\n \"CSV Collection\",\n \"CSV\",\n \"Feature Collection Template\",\n \"Feature Collection\",\n \"Feature Layer\",\n \"Feature Service\",\n \"File Geodatabase\",\n \"GeoJSON\",\n \"GeoJson\",\n \"KML Collection\",\n \"KML\",\n \"Microsoft Excel\",\n \"Raster Layer\",\n \"Shapefile\",\n \"Stream Service\",\n \"Table\",\n];\nvar document = [\n \"CAD Drawing\",\n \"Document Link\",\n \"Hub Page\",\n \"Site Page\",\n \"Image\",\n \"iWork Keynote\",\n \"iWork Numbers\",\n \"iWork Pages\",\n \"Microsoft Powerpoint\",\n \"Microsoft Visio\",\n \"Microsoft Word\",\n \"Notebook\",\n \"PDF\",\n \"Pro Map\",\n \"Report Template\",\n];\nvar event = [\"Hub Event\"];\nvar feedback = [\"Form\", \"Quick Capture Project\"];\nvar initiative = [\"Hub Initiative\"];\nvar solution = [\"Solution\"];\nvar template = [\"Hub Initiative Template\"];\nvar map = [\n \"Image Collection\",\n \"Image Service\",\n \"Map Service Layer\",\n \"Map Service\",\n \"Scene Service\",\n \"Scene Layer\",\n \"Vector Tile Service\",\n \"Web Map Service\",\n \"Web Map Tile Service\",\n \"Web Map\",\n \"Web Scene\",\n \"WFS\",\n \"WMS\",\n \"WMTS\",\n];\nvar other = [\n \"360 VR Experience\",\n \"AppBuilder Widget Package\",\n \"Application Configuration\",\n \"ArcPad Package\",\n \"Code Attachment\",\n \"Code Sample\",\n \"Desktop Add In\",\n \"Desktop Application Template\",\n \"Desktop Application\",\n \"Desktop Style\",\n \"Explorer Add In\",\n \"Explorer Layer\",\n \"Geocoding Service\",\n \"Geometry Service\",\n \"Geoprocessing Package\",\n \"Geoprocessing Sample\",\n \"Geoprocessing Service\",\n \"Layer File\",\n \"Layer Package\",\n \"Layer Template\",\n \"Layer\",\n \"Layout\",\n \"Locator Package\",\n \"Map Area\",\n \"Map Document\",\n \"Map Package\",\n \"Map Service Definition\",\n \"Map Template\",\n \"Mobile Application\",\n \"Mobile Map Package\",\n \"Native Application\",\n \"Network Analysis Service\",\n \"Operations Dashboard Add In\",\n \"Project Package\",\n \"Project Template\",\n \"Raster Function Template\",\n \"Rule Package\",\n \"Scene Package\",\n \"Service Definition\",\n \"SQLite Geodatabase\",\n \"Style\",\n \"Tile Package\",\n \"Vector Tile Package\",\n \"Workflow Manager Package\",\n];\nvar site = [\"Hub Site Application\", \"Site Application\"];\nexport var collections = {\n app: app,\n dataset: dataset,\n document: document,\n event: event,\n feedback: feedback,\n initiative: initiative,\n template: template,\n solution: solution,\n map: map,\n other: other,\n site: site,\n};\n//# sourceMappingURL=collections.js.map","import { collections } from \"./collections\";\nvar app = collections.app, dataset = collections.dataset, document = collections.document, event = collections.event, feedback = collections.feedback, initiative = collections.initiative, map = collections.map, other = collections.other, site = collections.site;\nvar downloadableTypes = [\n \"360 VR Experience\",\n \"Application\",\n \"CityEngine Web Scene\",\n \"Code Sample\",\n \"CSV Collection\",\n \"CSV\",\n \"CAD Drawing\",\n \"Desktop Application\",\n \"Desktop Application Template\",\n \"Desktop Style\",\n \"File Geodatabase\",\n \"GeoJson\",\n \"Geoprocessing Package\",\n \"Geoprocessing Sample\",\n \"Image\",\n \"iWork Keynote\",\n \"iWork Numbers\",\n \"KML Collection\",\n \"KML\",\n \"Layer\",\n \"Layer File\",\n \"Layer Package\",\n \"Layout\",\n \"Locator Package\",\n \"Map Package\",\n \"Map Service Definition\",\n \"Map Template\",\n \"Microsoft Excel\",\n \"Microsoft Powerpoint\",\n \"Microsoft Visio\",\n \"Microsoft Word\",\n \"Notebook\",\n \"Operations Dashboard Add In\",\n \"PDF\",\n \"Pro Map\",\n \"Project Package\",\n \"Project Template\",\n \"Raster function template\",\n \"Rule Package\",\n \"Service Definition\",\n \"Shapefile\",\n \"Vector Tile Package\",\n \"Workflow Manager Package\",\n];\nvar downloadableTypeKeywords = [\"Data\"];\nvar apiTypes = [\"Feature Service\", \"Map Service\", \"Image Service\"];\n// TODO: remove this at next breaking version\n// we're just keeping this for backwards compatibility\nexport var categories = {\n app: app.concat(feedback),\n dataset: dataset,\n document: document,\n event: event,\n initiative: initiative,\n map: map,\n other: other,\n site: site,\n downloadableTypes: downloadableTypes,\n downloadableTypeKeywords: downloadableTypeKeywords,\n apiTypes: apiTypes,\n};\n// TODO: move this function and supporting arrays to another module\n/**\n * Is the item type downloadable in the Hub app\n * @param item ArcGIS item with type and type keywords\n */\nexport function isDownloadable(item) {\n return (downloadableTypes.indexOf(item.type) !== -1 ||\n (item.typeKeywords &&\n downloadableTypeKeywords.some(function (downloadableTypeKeyword) {\n return item.typeKeywords.some(function (typeKeyword) { return typeKeyword === downloadableTypeKeyword; });\n })));\n}\n//# sourceMappingURL=categories.js.map","import { getProp } from \"./objects\";\nimport { request } from \"@esri/arcgis-rest-request\";\nexport function createExtent(xmin, ymin, xmax, ymax, wkid) {\n if (wkid === void 0) { wkid = 4326; }\n return {\n xmin: xmin,\n ymin: ymin,\n xmax: xmax,\n ymax: ymax,\n // type: 'extent',\n spatialReference: {\n wkid: wkid,\n },\n };\n}\n/**\n * Turns an extent into a bbox\n * @param envelope extent\n */\nexport function extentToBBox(envelope) {\n return [\n [envelope.xmin, envelope.ymin],\n [envelope.xmax, envelope.ymax],\n ];\n}\nexport var GLOBAL_EXTENT = {\n xmin: -180,\n ymin: -90,\n xmax: 180,\n ymax: 90,\n spatialReference: {\n wkid: 4326,\n },\n};\n/**\n * Gets the geographic extent for an org\n * @param hubRequestOptions\n */\nexport function getGeographicOrgExtent(hubRequestOptions) {\n var portal = hubRequestOptions.portalSelf;\n var orgExtent = portal.defaultExtent;\n var geometryServiceUrl = getProp(portal, \"helperServices.geometry.url\");\n // Define a default global extent object\n if (!geometryServiceUrl) {\n return Promise.resolve(GLOBAL_EXTENT);\n }\n if (!orgExtent) {\n return Promise.resolve(GLOBAL_EXTENT);\n }\n var url = geometryServiceUrl + \"/project\";\n // geometry params...\n var geometryParam = {\n geometryType: \"esriGeometryEnvelope\",\n geometries: [orgExtent],\n };\n var options = {\n httpMethod: \"POST\",\n params: {\n geometries: JSON.stringify(geometryParam),\n transformForward: false,\n transformation: \"\",\n inSR: orgExtent.spatialReference.wkid,\n outSR: 4326,\n f: \"json\",\n },\n };\n // add in auth if it's passed\n if (hubRequestOptions.authentication) {\n options.authentication = hubRequestOptions.authentication;\n }\n return request(url, options)\n .then(function (response) {\n var geom = response.geometries[0];\n return {\n xmin: geom.xmin,\n ymin: geom.ymin,\n xmax: geom.xmax,\n ymax: geom.ymax,\n spatialReference: {\n wkid: 4326,\n },\n };\n })\n .catch(function (ex) {\n return GLOBAL_EXTENT;\n });\n}\n/**\n * Get the default org extent as a bbox for use on item.extent\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getOrgExtentAsBBox(hubRequestOptions) {\n return getGeographicOrgExtent(hubRequestOptions).then(function (extent) {\n return extentToBBox(extent);\n });\n}\n/**\n * checks if the extent is a valid BBox (2 element array of coordinate pair arrays)\n * @param extent\n * @returns\n */\nexport var isBBox = function (extent) {\n return (Array.isArray(extent) &&\n Array.isArray(extent[0]) &&\n Array.isArray(extent[1]));\n};\nexport function isExtentCoordinateArray(extent) {\n /* tslint:disable no-console */\n console.warn(\"DEPRECATED: use isBBox() instead\");\n /* tslint:enable no-console */\n return isBBox(extent);\n}\nfunction isExtentJSON(extent) {\n return [\"xmin\", \"ymin\", \"xmax\", \"ymax\"].every(function (key) { return typeof extent[key] === \"number\"; });\n}\n/**\n * Check if the given extent is in a known format\n * @param {Object} extent extent in any format\n * @return {Boolean} indicator\n */\nexport function isValidExtent(extent) {\n return (!!extent &&\n [isExtentCoordinateArray, isExtentJSON].some(function (test) { return test(extent); }));\n}\nexport var bBoxToPolygon = function (bBox) {\n var _a = bBox[0], xmin = _a[0], ymin = _a[1], _b = bBox[1], xmax = _b[0], ymax = _b[1];\n var rings = [\n [\n [xmin, ymin],\n [xmax, ymin],\n [xmax, ymax],\n [xmin, ymax],\n [xmin, ymin],\n ],\n ];\n var wkid = 4326;\n return {\n rings: rings,\n spatialReference: {\n wkid: wkid,\n },\n };\n};\n//# sourceMappingURL=extent.js.map","export var STANDARD_LICENSES = [\n {\n type: \"CC0-1.0\",\n abbr: \"CC0\",\n name: \"Public Domain Dedication\",\n url: \"http://creativecommons.org/publicdomain/zero/1.0\",\n },\n {\n type: \"CC-BY-4.0\",\n abbr: \"CC BY\",\n name: \"Attribution 4.0 International\",\n url: \"http://creativecommons.org/licenses/by/4.0\",\n },\n {\n type: \"CC-BY-3.0\",\n abbr: \"CC BY 3.0\",\n name: \"Attribution 3.0 Unported\",\n url: \"http://creativecommons.org/licenses/by/3.0\",\n },\n {\n type: \"CC-BY-2.5\",\n abbr: \"CC BY 2.5\",\n name: \"Attribution 2.5 Generic\",\n url: \"http://creativecommons.org/licenses/by/2.5\",\n },\n {\n type: \"CC-BY-2.0\",\n abbr: \"CC BY 2.0\",\n name: \"Attribution 2.0 Generic\",\n url: \"http://creativecommons.org/licenses/by/2.0\",\n },\n {\n type: \"CC-BY-1.0\",\n abbr: \"CC BY 1.0\",\n name: \"Attribution 1.0 Generic\",\n url: \"http://creativecommons.org/licenses/by/1.0\",\n },\n {\n type: \"CC-BY-SA-4.0\",\n abbr: \"CC BY-SA\",\n name: \"Attribution-ShareAlike 4.0 International\",\n url: \"http://creativecommons.org/licenses/by-sa/4.0\",\n },\n {\n type: \"CC-BY-SA-3.0\",\n abbr: \"CC BY-SA 3.0\",\n name: \"Attribution-ShareAlike 3.0 Unported\",\n url: \"http://creativecommons.org/licenses/by-sa/3.0\",\n },\n {\n type: \"CC-BY-SA-2.5\",\n abbr: \"CC BY-SA 2.5\",\n name: \"Attribution-ShareAlike 2.5 Generic\",\n url: \"http://creativecommons.org/licenses/by-sa/2.5\",\n },\n {\n type: \"CC-BY-SA-2.0\",\n abbr: \"CC BY-SA 2.0\",\n name: \"Attribution-ShareAlike 2.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-sa/2.0\",\n },\n {\n type: \"CC-BY-SA-1.0\",\n abbr: \"CC BY-SA 1.0\",\n name: \"Attribution-ShareAlike 1.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-sa/1.0\",\n },\n {\n type: \"CC-BY-ND-4.0\",\n abbr: \"CC BY-ND\",\n name: \"Attribution-NoDerivatives 4.0 International\",\n url: \"http://creativecommons.org/licenses/by-nd/4.0\",\n },\n {\n type: \"CC-BY-ND-3.0\",\n abbr: \"CC BY-ND 3.0\",\n name: \"Attribution-NoDerivs 3.0 Unported\",\n url: \"http://creativecommons.org/licenses/by-nd/3.0\",\n },\n {\n type: \"CC-BY-ND-2.5\",\n abbr: \"CC BY-ND 2.5\",\n name: \"Attribution-NoDerivs 2.5 Generic\",\n url: \"http://creativecommons.org/licenses/by-nd/2.5\",\n },\n {\n type: \"CC-BY-ND-2.0\",\n abbr: \"CC BY-ND 2.0\",\n name: \"Attribution-NoDerivs 2.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-nd/2.0\",\n },\n {\n type: \"CC-BY-ND-1.0\",\n abbr: \"CC BY-ND 1.0\",\n name: \"Attribution-NoDerivs 1.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-nd/1.0\",\n },\n {\n type: \"CC-BY-NC-4.0\",\n abbr: \"CC BY-NC\",\n name: \"Attribution-NonCommercial 4.0 International\",\n url: \"https://creativecommons.org/licenses/by-nc/4.0\",\n },\n {\n type: \"CC-BY-NC-3.0\",\n abbr: \"CC BY-NC 3.0\",\n name: \"Attribution-NonCommercial 3.0 Unported\",\n url: \"https://creativecommons.org/licenses/by-nc/3.0\",\n },\n {\n type: \"CC-BY-NC-2.5\",\n abbr: \"CC BY-NC 2.5\",\n name: \"Attribution-NonCommercial 2.5 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc/2.5\",\n },\n {\n type: \"CC-BY-NC-2.0\",\n abbr: \"CC BY-NC 2.0\",\n name: \"Attribution-NonCommercial 2.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc/2.0\",\n },\n {\n type: \"CC-BY-NC-1.0\",\n abbr: \"CC BY-NC 1.0\",\n name: \"Attribution-NonCommercial 1.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc/1.0\",\n },\n {\n type: \"CC-BY-NC-SA-4.0\",\n abbr: \"CC BY-NC-SA\",\n name: \"Attribution-NonCommercial-ShareAlike 4.0 International\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/4.0\",\n },\n {\n type: \"CC-BY-NC-SA-3.0\",\n abbr: \"CC BY-NC-SA 3.0\",\n name: \"Attribution-NonCommercial-ShareAlike 3.0 Unported\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/3.0\",\n },\n {\n type: \"CC-BY-NC-SA-2.5\",\n abbr: \"CC BY-NC-SA 2.5\",\n name: \"Attribution-NonCommercial-ShareAlike 2.5 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/2.5\",\n },\n {\n type: \"CC-BY-NC-SA-2.0\",\n abbr: \"CC BY-NC-SA 2.0\",\n name: \"Attribution-NonCommercial-ShareAlike 2.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/2.0\",\n },\n {\n type: \"CC-BY-NC-SA-1.0\",\n abbr: \"CC BY-NC-SA 1.0\",\n name: \"Attribution-NonCommercial-ShareAlike 1.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/1.0\",\n },\n {\n type: \"CC-BY-NC-ND-4.0\",\n abbr: \"CC BY-NC-ND\",\n name: \"Attribution-NonCommercial-NoDerivatives 4.0 International\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/4.0\",\n },\n {\n type: \"CC-BY-NC-ND-3.0\",\n abbr: \"CC BY-NC-ND 3.0\",\n name: \"Attribution-NonCommercial-NoDerivs 3.0 Unported\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/3.0\",\n },\n {\n type: \"CC-BY-NC-ND-2.5\",\n abbr: \"CC BY-NC-ND 2.5\",\n name: \"Attribution-NonCommercial-NoDerivs 2.5 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/2.5\",\n },\n {\n type: \"CC-BY-NC-ND-2.0\",\n abbr: \"CC BY-NC-ND 2.0\",\n name: \"Attribution-NonCommercial-NoDerivs 2.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/2.0\",\n },\n {\n type: \"CC-BY-NC-ND-1.0\",\n abbr: \"CC BY-NC-ND 1.0\",\n name: \"Attribution-NonCommercial-NoDerivs 1.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/1.0\",\n },\n {\n type: \"PDDL-1.0\",\n abbr: \"PDDL\",\n name: \"ODC Public Domain Dedication and License\",\n url: \"http://opendatacommons.org/licenses/pddl/summary\",\n },\n {\n type: \"ODbL-1.0\",\n abbr: \"ODbL\",\n name: \"ODC Open Database License\",\n url: \"http://opendatacommons.org/licenses/odbl/summary\",\n },\n {\n type: \"ODC-BY-1.0\",\n abbr: \"ODC BY\",\n name: \"ODC Attribution License\",\n url: \"http://opendatacommons.org/licenses/by/summary\",\n },\n];\n/**\n * generates the structured license of an item based on its\n * configured \"licenseInfo\"\n * @param rawLicense an item's raw licenseInfo string\n * @returns {IStructuredLicense}\n */\nexport function getStructuredLicense(rawLicense) {\n var structuredLicense;\n rawLicense = rawLicense || \"\";\n // (1) start by assuming it's either a custom license, or, if there's no\n // raw license, then there's no license at all\n structuredLicense = {\n type: rawLicense ? \"custom\" : \"none\",\n text: rawLicense,\n };\n // (2) Check for standard licenses: If the name, abbr, or url of any standard\n // license is in the raw license text, we assume that is the license.\n var hasStandardLicense = false;\n var matchingStandardLicenses = STANDARD_LICENSES.filter(function (standardLicense) {\n return licenseTextContainsStandardLicenseAttributes(rawLicense, standardLicense);\n });\n if (matchingStandardLicenses.length) {\n hasStandardLicense = true;\n structuredLicense = matchingStandardLicenses.pop();\n }\n // (3) if not a standard license, we check if the raw license is a url or link\n if (!hasStandardLicense) {\n var url = void 0;\n // a. check if the the raw license is simply a url\n if (isParseableAsURL(rawLicense)) {\n url = rawLicense;\n }\n // b. check if the raw license is simply a link (i.e. an anchor tag with an href)\n else if (isSingleAnchorWithHrefAttribute(rawLicense)) {\n var hrefRegex = new RegExp(/href\\s?=\\s?[\"'](.*?)[\"']/);\n var match = rawLicense.match(hrefRegex);\n var href = match[1];\n url = href;\n }\n if (url) {\n structuredLicense.url = url;\n structuredLicense.text = \"\";\n }\n }\n if (!structuredLicense.text)\n delete structuredLicense.text;\n return structuredLicense;\n}\n/**\n * helper function to determine if a raw license is one of the standard licenses.\n * We say it is if the raw license includes the name, url or abbreviation of the\n * standard license\n * @param rawLicense an item's raw licenseInfo string\n * @param standardLicense one of the standard licenses\n * @returns {boolean}\n */\nfunction licenseTextContainsStandardLicenseAttributes(rawLicense, standardLicense) {\n rawLicense = rawLicense.toLowerCase();\n return (rawLicense.includes(standardLicense.name.toLowerCase()) ||\n rawLicense.includes(standardLicense.url.toLowerCase()) ||\n rawLicense.includes(standardLicense.abbr.toLowerCase()));\n}\n/**\n * helper function to determine if an input string can be parsed\n * as a URL with a protocol\n * @param value string to check\n * @returns {boolean}\n */\nfunction isParseableAsURL(value) {\n try {\n var url = new URL(value);\n return !!url.protocol;\n }\n catch (err) {\n // just return fals if the URL couldn't be parsed\n return false;\n }\n}\n/**\n * helper function to determine if the raw license is simply a link, i.e. a single\n * anchor tag with an href attribute: <a href=\"https://google.com\">Click</a> or <a href=\"https://google.com\" />\n * @param rawLicense an item's raw licenseInfo string\n * @returns {boolean}\n */\nfunction isSingleAnchorWithHrefAttribute(rawLicense) {\n var isSingleAnchorTagRegex = new RegExp(/^<a[\\s]+(href\\s?=\\s?[\"'].*?[\"'])+([^>]?)>((?:.(?!\\<\\/a\\>))*.)?<\\/a>$|^<a[\\s]+(href\\s?=\\s?[\"'].*?[\"'])+([^>]?)\\/>/);\n return isSingleAnchorTagRegex.test(rawLicense);\n}\n//# sourceMappingURL=get-structured-license.js.map","/**\n * Use this module for functions that do not need to be used by consumers (yet),\n * but may be shared between hub.js modules, and/or need to be tested\n * to get 100% coverage w/o writing cumbersome tests of higher level functions.\n *\n * Consuming will not be able to import these functions.\n *\n * It's probably a good pattern to add functions here first and then\n * move them to index.ts only when they are needed by a consumer.\n */\nimport { __assign } from \"tslib\";\nimport { bBoxToPolygon, isBBox } from \"../extent\";\n/**\n * Create a new content with updated boundary properties\n * @param content original content\n * @param boundary boundary provenance\n * @returns\n */\nexport var setContentBoundary = function (content, boundary) {\n // update content's item and boundary\n var properties = __assign(__assign({}, (content.item.properties || {})), { boundary: boundary });\n var item = __assign(__assign({}, content.item), { properties: properties });\n var updated = __assign(__assign({}, content), { item: item });\n return __assign(__assign({}, updated), { boundary: getContentBoundary(updated) });\n};\n/**\n * Create a new content with updated extent and derived properties like boundary\n * @param content original content\n * @param extent new extent\n * @returns a new content with the updated extent and boundary\n */\nexport var setContentExtent = function (content, extent) {\n // update content's item and extent\n var item = __assign(__assign({}, content.item), { extent: extent });\n var updated = __assign(__assign({}, content), { item: item, extent: extent });\n // derive boundary from content properties\n var boundary = getContentBoundary(updated);\n return __assign(__assign({}, updated), { boundary: boundary });\n};\nvar getContentBoundary = function (content) {\n var _a;\n var item = content.item;\n var extent = item.extent;\n var isValidItemExtent = isBBox(extent);\n // user specified provenance is stored in item.properties\n var provenance = ((_a = item.properties) === null || _a === void 0 ? void 0 : _a.boundary) ||\n // but we default to item if the item has an extent\n (isValidItemExtent ? \"item\" : undefined);\n var geometry;\n switch (provenance) {\n case \"item\":\n geometry = isValidItemExtent ? bBoxToPolygon(extent) : null;\n break;\n case \"none\":\n geometry = null;\n break;\n // TODO: handle other provenances\n }\n // TODO: derive and return center\n return {\n provenance: provenance,\n geometry: geometry,\n };\n};\n//# sourceMappingURL=_internal.js.map","import { __assign, __spreadArrays } from \"tslib\";\nimport { collections } from \"../collections\";\nimport { categories as allCategories, isDownloadable } from \"../categories\";\nimport { isBBox } from \"../extent\";\nimport { includes, isGuid } from \"../utils\";\nimport { getProp } from \"../objects\";\nimport { getStructuredLicense } from \"../items/get-structured-license\";\nimport { getServiceTypeFromUrl } from \"../urls\";\nimport { setContentExtent } from \"./_internal\";\nfunction collectionToFamily(collection) {\n var overrides = {\n other: \"content\",\n solution: \"template\",\n };\n return overrides[collection] || collection;\n}\nvar cache = {};\n// TODO: remove this at next breaking version\n/**\n * ```js\n * import { getCategory } from \"@esri/hub-common\";\n * //\n * getCategory('Feature Layer')\n * > 'dataset'\n * ```\n * **DEPRECATED: Use getCollection() instead**\n * returns the Hub category for a given item type\n * @param itemType The ArcGIS [item type](https://developers.arcgis.com/rest/users-groups-and-items/items-and-item-types.htm).\n * @returns the category of a given item type.\n */\nexport function getCategory(itemType) {\n if (itemType === void 0) { itemType = \"\"; }\n /* tslint:disable no-console */\n console.warn(\"DEPRECATED: Use getCollection() instead. getCategory will be removed at v10.0.0\");\n /* tslint:enable no-console */\n var collection = getCollection(itemType);\n // for backwards compatibility\n return collection === \"feedback\" ? \"app\" : collection;\n}\n/**\n * ```js\n * import { getTypes } from \"@esri/hub-common\";\n * //\n * getTypes('site')\n * > [ 'hub site application' ]\n * ```\n * To do.\n * @param category The ArcGIS Hub category.\n * @returns all the item types for the given category.\n *\n */\nexport function getTypes(category) {\n if (category === void 0) { category = \"\"; }\n return allCategories[category.toLowerCase()];\n}\n/**\n * ```js\n * import { normalizeItemType } from \"@esri/hub-common\";\n * //\n * normalizeItemType(item)\n * > [ 'Hub Site Application' ]\n * ```\n * @param item Item object.\n * @returns type of the input item.\n *\n */\nexport function normalizeItemType(item) {\n if (item === void 0) { item = {}; }\n var ret = item.type;\n var typeKeywords = item.typeKeywords || [];\n if (item.type === \"Site Application\" ||\n (item.type === \"Web Mapping Application\" &&\n includes(typeKeywords, \"hubSite\"))) {\n ret = \"Hub Site Application\";\n }\n if (item.type === \"Site Page\" ||\n (item.type === \"Web Mapping Application\" &&\n includes(typeKeywords, \"hubPage\"))) {\n ret = \"Hub Page\";\n }\n if (item.type === \"Hub Initiative\" &&\n includes(typeKeywords, \"hubInitiativeTemplate\")) {\n ret = \"Hub Initiative Template\";\n }\n if (item.type === \"Web Mapping Application\" &&\n includes(typeKeywords, \"hubSolutionTemplate\")) {\n ret = \"Solution\";\n }\n return ret;\n}\n/**\n * ```js\n * import { getTypeCategories } from \"@esri/hub-common\";\n * //\n * getTypeCategories(item)\n * > [ 'Hub Site Application' ]\n * ```\n * @param item Item object.\n * @returns typeCategory of the input item.\n *\n */\nexport function getTypeCategories(item) {\n if (item === void 0) { item = {}; }\n var type = normalizeItemType(item);\n var category = getCategory(type);\n if (category) {\n // upper case first letter and return as element in array for backwards compatibility\n var chars = Array.from(category);\n chars[0] = chars[0].toUpperCase();\n return [chars.join(\"\")];\n }\n else {\n return [\"Other\"];\n }\n}\n/**\n * ```js\n * import { getCollection } from \"@esri/hub-common\";\n * //\n * getCollection('Feature Layer')\n * > 'dataset'\n * ```\n * Get the Hub collection for a given item type\n * @param itemType The ArcGIS [item type](https://developers.arcgis.com/rest/users-groups-and-items/items-and-item-types.htm).\n * @returns the Hub collection of a given item type.\n */\nexport function getCollection(itemType) {\n if (itemType === void 0) { itemType = \"\"; }\n if (cache[itemType]) {\n return cache[itemType];\n }\n for (var _i = 0, _a = Object.keys(collections); _i < _a.length; _i++) {\n var collection = _a[_i];\n for (var _b = 0, _c = collections[collection]; _b < _c.length; _b++) {\n var type = _c[_b];\n if (itemType.toLowerCase() === type.toLowerCase()) {\n cache[itemType] = collection;\n return collection;\n }\n }\n }\n}\n/**\n * Case-insensitive check if the type is \"Feature Service\"\n * @param {string} type - item's type\n * @returns {boolean}\n */\nexport var isFeatureService = function (type) {\n return type && type.toLowerCase() === \"feature service\";\n};\n/**\n * parse layer id from a service URL\n * @param {string} url\n * @returns {string} layer id\n */\nexport var getLayerIdFromUrl = function (url) {\n var endsWithNumberSegmentRegEx = /\\/\\d+$/;\n var matched = url && url.match(endsWithNumberSegmentRegEx);\n return matched && matched[0].slice(1);\n};\n/**\n * return the layerId if we can tell that item is a single layer service\n * @param {*} item from AGO\n * @returns {string} layer id\n */\nexport var getItemLayerId = function (item) {\n // try to parse it from the URL, but failing that we check for\n // the Singlelayer typeKeyword, which I think is set when you create the item in AGO\n // but have not verified that, nor that we should alway return '0' in that case\n return (getLayerIdFromUrl(item.url) ||\n (isFeatureService(item.type) &&\n includes(item.typeKeywords, \"Singlelayer\") &&\n \"0\"));\n};\n/**\n * given an item, get the id to use w/ the Hub API\n * @param item\n * @returns Hub API id (hubId)\n */\nexport var getItemHubId = function (item) {\n if (item.access !== \"public\") {\n // the hub only indexes public items\n return;\n }\n var id = item.id;\n var layerId = getItemLayerId(item);\n return layerId ? id + \"_\" + layerId : id;\n};\n/**\n * ```js\n * import { getContentIdentifier } from \"@esri/hub-common\";\n * //\n * getContentIdentifier(content, site)\n * > 'f12hhjk32' // id\n * // OR\n * > 'content-slug' // human-readable slug\n * ```\n * Returns the preferred identifier for a piece of content (determined by content type):\n * - Content from the 'template' and 'feedback' families return the standard id field\n * - Pages that are linked to the site parameter will return the slug defined by the site. Otherwise, the page id will be returned\n * - All other content will return the highest available item in the following hierarchy:\n * 1. slug - includes org prefix if the site parameter is a portal or has an orgKey different from the slug prefix\n * 2. hubId\n * 3. id\n * @param content The IHubContent item\n * @param site The site to compare content against\n * @returns the preferred id for the given content.\n */\nexport function getContentIdentifier(content, site) {\n // We don't currently support slugs for hub initiative templates, solutions or surveys\n if (includes([\"template\", \"feedback\"], content.family)) {\n return content.id;\n }\n // If it is a hub page linked to a site, return the page slug at the\n // site data instead. Because this one is the original one that was used\n // to create the page url (not mutable once created) and the slug (below)\n // generated by the hub-indexer could simply change with page name.\n if (isPageContent(content)) {\n // check if the page is linked to the current site\n var pages = getProp(site, \"data.values.pages\") || [];\n // if so, return the page slug otherwise the page id\n var page = pages.find(function (p) { return p.id === content.id; });\n return page ? page.slug : content.id;\n }\n // If a slug is present, always return it\n if (content.slug) {\n var slug = void 0;\n var orgKey = getProp(site, \"domainInfo.orgKey\");\n // Use namespaced slug when on the umbrella site\n if (getProp(site, \"data.values.isUmbrella\")) {\n slug = content.slug;\n }\n else {\n // Use shortened slug if the slug's namespace is the same as the orgKey\n slug = removeContextFromSlug(content.slug, orgKey);\n }\n return slug;\n }\n return content.hubId || content.id;\n}\n//////////////////////\n// Slug Helpers\n//////////////////////\n/**\n * Parse item ID and layer ID (if any) from dataset record ID\n *\n * @param datasetId Hub API dataset record id ({itemId}_{layerId} or {itemId})\n * @returns A hash with the `itemId` and `layerId` (if any)\n */\nexport function parseDatasetId(datasetId) {\n var _a = datasetId ? datasetId.split(\"_\") : [], itemId = _a[0], layerId = _a[1];\n return { itemId: itemId, layerId: layerId };\n}\n/**\n * Determine if an identifier is a Hub API slug\n *\n * @param identifier Hub API slug ({orgKey}::{title-as-slug} or {title-as-slug})\n * or record id ((itemId}_{layerId} or {itemId})\n * @returns true if the identifier is valid _and_ is **not** a record id\n */\nexport function isSlug(identifier) {\n var itemId = parseDatasetId(identifier).itemId;\n if (!itemId || isGuid(itemId)) {\n // it's either invalid, or an item id, or a dataset id\n return false;\n }\n // otherwise assume it's a slug\n return true;\n}\n/**\n * Add a context (prefix) to slug if it doesn't already have one\n *\n * @param slug Hub API slug (with or without context)\n * @param context usually a portal's orgKey\n * @returns slug with context ({context}::{slug})\n */\nexport function addContextToSlug(slug, context) {\n // the slug has an org key already e.g. dc::crime-incidents\n if (/.+::.+/.test(slug)) {\n return slug;\n // the slug belongs to the org that owns the site e.g. crime-incidents\n }\n else {\n return context + \"::\" + slug;\n }\n}\n/**\n * Remove context (prefix) from a slug\n *\n * @param slug Hub API slug with context\n * @param context usually a portal's orgKey\n * @returns slug without context\n */\nexport function removeContextFromSlug(slug, context) {\n if (context && slug.match(context + \"::\")) {\n return slug.split(context + \"::\")[1];\n }\n else {\n return slug;\n }\n}\n/**\n * Splits item category strings at slashes and discards the \"Categories\" keyword\n *\n * ```\n * [\"/Categories/Boundaries\", \"/Categories/Planning and cadastre/Property records\", \"/Categories/Structure\"]\n * ```\n * Should end up being\n * ```\n * [\"Boundaries\", \"Planning and cadastre\", \"Property records\", \"Structure\"]\n * ```\n *\n * @param categories - an array of strings\n * @private\n */\nexport function parseItemCategories(categories) {\n if (!categories)\n return categories;\n var exclude = [\"categories\", \"\"];\n var parsed = categories.map(function (cat) { return cat.split(\"/\"); });\n var flattened = parsed.reduce(function (acc, arr, _) { return __spreadArrays(acc, arr); }, []);\n return flattened.filter(function (cat) { return !includes(exclude, cat.toLowerCase()); });\n}\n/**\n * return the Hub family given an item's type\n * @param type item type\n * @returns Hub family\n */\nexport function getFamily(type) {\n var family;\n // override default behavior for the rows that are highlighted in yellow here:\n // https://esriis.sharepoint.com/:x:/r/sites/ArcGISHub/_layouts/15/Doc.aspx?sourcedoc=%7BADA1C9DC-4F6C-4DE4-92C6-693EF9571CFA%7D&file=Hub%20Routes.xlsx&nav=MTBfe0VENEREQzI4LUZFMDctNEI0Ri04NjcyLThCQUE2MTA0MEZGRn1fezIwMTIwMEJFLTA4MEQtNEExRC05QzA4LTE5MTAzOUQwMEE1RH0&action=default&mobileredirect=true&cid=df1c874b-c367-4cea-bc13-7bebfad3f2ac\n switch ((type || \"\").toLowerCase()) {\n case \"image service\":\n family = \"dataset\";\n break;\n case \"feature service\":\n case \"raster layer\":\n // TODO: check if feature service has > 1 layer first?\n family = \"map\";\n break;\n case \"microsoft excel\":\n family = \"document\";\n break;\n case \"cad drawing\":\n case \"feature collection template\":\n case \"report template\":\n family = \"content\";\n break;\n default:\n // by default derive from collection\n family = collectionToFamily(getCollection(type));\n }\n return family;\n}\n/**\n * DEPRECATED: Use getFamily() instead.\n *\n * get the HubType for a given item or item type\n *\n * @param itemOrType an item or item.type\n */\nexport function getItemHubType(itemOrType) {\n /* tslint:disable no-console */\n console.warn(\"DEPRECATED: Use getFamily() instead. getItemHubType() will be removed at v10.0.0\");\n /* tslint:enable no-console */\n if (typeof itemOrType === \"string\") {\n itemOrType = { type: itemOrType };\n }\n var itemType = normalizeItemType(itemOrType);\n // TODO: not all categories are Hub types, may need to validate\n return getCollection(itemType);\n}\n/**\n * Convert a Portal item to Hub content\n *\n * @param item Portal Item\n * @returns Hub content\n * @export\n */\nexport function itemToContent(item) {\n var createdDate = new Date(item.created);\n var createdDateSource = \"item.created\";\n var properties = item.properties;\n var content = Object.assign({}, item, {\n identifier: item.id,\n // no server errors when fetching the item directly\n errors: [],\n // store a reference to the item\n item: item,\n // NOTE: this will overwrite any existing item.name, which is\n // The file name of the item for file types. Read-only.\n // presumably there to use as the default file name when downloading\n // we don't store item.name in the Hub API and we use name for title\n name: item.title,\n // TODO: hubType is no longer used, remove it at next breaking change\n hubType: getItemHubType(item),\n categories: parseItemCategories(item.categories),\n itemCategories: item.categories,\n // can we strip HTML from description, and do we need to trim it to a X chars?\n summary: item.snippet || item.description,\n publisher: {\n name: item.owner,\n username: item.owner,\n },\n permissions: {\n visibility: item.access,\n control: item.itemControl || \"view\",\n },\n // Hub app configuration metadata from item properties\n actionLinks: properties && properties.links,\n hubActions: properties && properties.actions,\n metrics: properties && properties.metrics,\n isDownloadable: isDownloadable(item),\n // default boundary from item.extent\n license: { name: \"Custom License\", description: item.accessInformation },\n // dates and sources we will enrich these later...\n createdDate: createdDate,\n createdDateSource: createdDateSource,\n publishedDate: createdDate,\n publishedDateSource: createdDateSource,\n updatedDate: new Date(item.modified),\n updatedDateSource: \"item.modified\",\n structuredLicense: getStructuredLicense(item.licenseInfo),\n });\n return setContentExtent(setContentType(content, item.type), item.extent);\n}\n/**\n * Convert a Hub API dataset resource to Hub Content\n *\n * @param {DatasetResource} Dataset resource\n * @returns {IHubContent} Hub content object\n * @export\n */\nexport function datasetToContent(dataset) {\n // extract item from dataset, create content from the item\n var item = datasetToItem(dataset);\n var content = itemToContent(item);\n // We remove these because the indexer doesn't actually\n // preserve the original item categories so this attribute is invalid\n delete content.itemCategories;\n // overwrite or add enrichments from Hub API\n var hubId = dataset.id, attributes = dataset.attributes;\n var \n // common enrichments\n errors = attributes.errors, boundary = attributes.boundary, extent = attributes.extent, metadata = attributes.metadata, modified = attributes.modified, modifiedProvenance = attributes.modifiedProvenance, slug = attributes.slug, searchDescription = attributes.searchDescription, groupIds = attributes.groupIds, \n // map and feature server enrichments\n server = attributes.server, layers = attributes.layers, \n // NOTE: the Hub API also returns the following server properties\n // but we should be able to get them from the above server object\n // currentVersion, capabilities, tileInfo, serviceSpatialReference\n // maxRecordCount, supportedQueryFormats, etc\n // feature and raster layer enrichments\n layer = attributes.layer, recordCount = attributes.recordCount, statistics = attributes.statistics, \n // NOTE: the Hub API also returns the following layer properties\n // but we should be able to get them from the above layer object\n // supportedQueryFormats, supportsAdvancedQueries, advancedQueryCapabilities, useStandardizedQueries\n // geometryType, objectIdField, displayField, fields,\n // org properties?\n orgId = attributes.orgId, orgName = attributes.orgName, organization = attributes.organization, orgExtent = attributes.orgExtent, \n // NOTE: for layers and tables the Hub API returns the layer type\n // (\"Feature Layer\", \"Table\", \"Raster Layer\") instead of the item type\n type = attributes.type;\n // NOTE: we could throw or return if there are errors\n // to prevent type errors trying to read properties below\n content.errors = errors;\n // common enrichments\n content.boundary = boundary;\n if (!isBBox(item.extent) && extent && isBBox(extent.coordinates)) {\n // we fall back to the extent derived by the API\n // which prefers layer or service extents and ultimately\n // falls back to the org's extent\n content.extent = extent.coordinates;\n }\n // setting this to null signals to enrichMetadata to skip this\n content.metadata = metadata || null;\n if (content.modified !== modified) {\n // capture the enriched modified date\n // NOTE: the item modified date is still available on content.item.modified\n content.modified = modified;\n content.updatedDate = new Date(modified);\n content.updatedDateSource = modifiedProvenance;\n }\n content.slug = slug;\n if (searchDescription) {\n // overwrite default summary (from snippet) w/ search description\n content.summary = searchDescription;\n }\n content.groupIds = groupIds;\n // server enrichments\n content.server = server;\n content.layers = layers;\n // layer enrichments\n content.layer = layer;\n content.recordCount = recordCount;\n content.statistics = statistics;\n // org enrichments\n if (orgId) {\n content.org = {\n id: orgId,\n name: orgName || organization,\n extent: orgExtent,\n };\n }\n // return a content with updated hubId and type\n // along w/ related properties like identifier, family, etc\n return setContentType(setContentHubId(content, hubId), type);\n}\n/**\n * Convert a Hub API dataset resource to a portal item\n *\n * @param {DatasetResource} Dataset resource\n * @returns {IItem} portal item\n * @export\n */\nexport function datasetToItem(dataset) {\n if (!dataset) {\n return;\n }\n var id = dataset.id, attributes = dataset.attributes;\n if (!attributes) {\n return;\n }\n // parse item id\n var itemId = parseDatasetId(id).itemId;\n // read item properties from attributes\n // NOTE: we attempt to read all item properties\n // even though some may not be currently returned\n var \n // start w/ item properties from\n // https://developers.arcgis.com/rest/users-groups-and-items/item.htm\n owner = attributes.owner, orgId = attributes.orgId, created = attributes.created, \n // the Hub API returns item.modified in attributes.itemModified (below)\n modified = attributes.modified, \n // NOTE: we use attributes.name to store the title or the service/layer name\n // but in Portal name is only used for file types to store the file name (read only)\n name = attributes.name, title = attributes.title, type = attributes.type, typeKeywords = attributes.typeKeywords, description = attributes.description, snippet = attributes.snippet, tags = attributes.tags, thumbnail = attributes.thumbnail, \n // the Hub API returns item.extent in attributes.itemExtent (below)\n // extent,\n categories = attributes.categories, contentStatus = attributes.contentStatus, \n // the Hub API doesn't currently return spatialReference\n spatialReference = attributes.spatialReference, \n // the Hub API doesn't currently return accessInformation\n accessInformation = attributes.accessInformation, licenseInfo = attributes.licenseInfo, culture = attributes.culture, url = attributes.url, access = attributes.access, \n // the Hub API doesn't currently return proxyFilter\n proxyFilter = attributes.proxyFilter, properties = attributes.properties, \n // the Hub API doesn't currently return appCategories, industries,\n // languages, largeThumbnail, banner, screenshots, listed, ownerFolder\n appCategories = attributes.appCategories, industries = attributes.industries, languages = attributes.languages, largeThumbnail = attributes.largeThumbnail, banner = attributes.banner, screenshots = attributes.screenshots, listed = attributes.listed, ownerFolder = attributes.ownerFolder, size = attributes.size, \n // the Hub API doesn't currently return protected\n isProtected = attributes.protected, commentsEnabled = attributes.commentsEnabled, \n // the Hub API doesn't currently return numComments, numRatings,\n // avgRating, numViews, itemControl, scoreCompleteness\n numComments = attributes.numComments, numRatings = attributes.numRatings, avgRating = attributes.avgRating, numViews = attributes.numViews, itemControl = attributes.itemControl, scoreCompleteness = attributes.scoreCompleteness, \n // additional attributes we'll need\n // to derive the above values when missing\n itemExtent = attributes.itemExtent, itemModified = attributes.itemModified, modifiedProvenance = attributes.modifiedProvenance, serviceSpatialReference = attributes.serviceSpatialReference;\n // layer datasets will get their type from the layer\n // so we will need to derive the item type from the URL\n var serviceType = url && getServiceTypeFromUrl(url);\n // build and return an item from properties\n // NOTE: we currently do NOT provide default values\n // (i.e. null for scalar attributes, [] for arrays, etc)\n // for attributes that are not returned by the Hub API\n // this helps distinguish an item that comes from the API\n // but forces all consumers to do handle missing properties\n return {\n id: itemId,\n owner: owner,\n orgId: orgId,\n created: created,\n // for feature layers, modified will usually come from the layer so\n // we prefer itemModified, but fall back to modified if it came from the item\n modified: (itemModified ||\n (modifiedProvenance === \"item.modified\" && modified)),\n title: (title || name),\n type: serviceType || type,\n typeKeywords: typeKeywords,\n description: description,\n tags: tags,\n snippet: snippet,\n thumbnail: thumbnail,\n extent: itemExtent ||\n /* istanbul ignore next: API should always return itemExtent, but we default to [] just in case */ [],\n categories: categories,\n contentStatus: contentStatus,\n spatialReference: spatialReference || serviceSpatialReference,\n accessInformation: accessInformation,\n licenseInfo: licenseInfo,\n culture: culture,\n url: url,\n access: access,\n size: size,\n protected: isProtected,\n proxyFilter: proxyFilter,\n properties: properties,\n appCategories: appCategories,\n industries: industries,\n languages: languages,\n largeThumbnail: largeThumbnail,\n banner: banner,\n screenshots: screenshots,\n listed: listed,\n ownerFolder: ownerFolder,\n commentsEnabled: commentsEnabled,\n numComments: numComments,\n numRatings: numRatings,\n avgRating: avgRating,\n numViews: numViews,\n itemControl: itemControl,\n scoreCompleteness: scoreCompleteness,\n };\n}\n/**\n * returns a new content that has the specified type and\n * and updated related properties like normalizedType, family, etc\n * @param content orignal content\n * @param type new type\n * @returns new content\n */\nexport var setContentType = function (content, type) {\n // get family and normalized type based on new type\n var normalizedType = normalizeItemType(__assign(__assign({}, content.item), { type: type }));\n var family = getFamily(normalizedType);\n // TODO: don't we need to update content.item.type too?\n var updated = __assign(__assign({}, content), { type: type, family: family, normalizedType: normalizedType });\n // update the relative URL to the content\n // which is based on type and family\n return appendContentUrls(updated, {\n relative: getContentRelativeUrl(updated),\n });\n};\n/**\n * returns a new content that has the specified hubId and updated identifier\n * @param content orignal content\n * @param hubId new hubId\n * @returns new content\n */\nexport var setContentHubId = function (content, hubId) {\n var id = content.id, slug = content.slug;\n // get the identifier which is based on hubId\n var identifier = slug || hubId || id;\n var updated = __assign(__assign({}, content), { hubId: hubId, identifier: identifier });\n // update the relative URL to the content\n // which is based on identifier\n return appendContentUrls(updated, {\n relative: getContentRelativeUrl(updated),\n });\n};\n/**\n * Calculates the relative and absolute urls for a given content on a specific site\n *\n * @param content\n * @param siteModel\n * @returns relative and absolute urls\n */\nexport var getContentSiteUrls = function (content, siteModel) {\n // compute relative URL using a site specific identifier\n var siteIdentifier = getContentIdentifier(content, siteModel);\n var relative = getContentRelativeUrl(content, siteIdentifier);\n // get the absolute URL to this content on the site\n var siteUrl = getProp(siteModel, \"item.url\").replace(/\\/$/, \"\");\n var absolute = \"\" + siteUrl + relative;\n return { relative: relative, absolute: absolute };\n};\n/**\n * append the absolute URL to the content on the site\n * also updates the relative URL in case the\n * @param content\n * @param siteModel\n * @returns\n */\nexport var setContentSiteUrls = function (content, siteModel) {\n var _a = getContentSiteUrls(content, siteModel), relative = _a.relative, site = _a.absolute;\n // append the updated URLs to a new content\n return appendContentUrls(content, {\n relative: relative,\n site: site,\n });\n};\n// URL helpers\nvar appendContentUrls = function (content, newUrls) {\n // merge new urls into existing ones and return a new content\n var urls = __assign(__assign({}, content.urls), newUrls);\n return __assign(__assign({}, content), { urls: urls });\n};\nvar getContentRelativeUrl = function (content, siteIdentifier) {\n var family = content.family;\n // prefer site specific identifier if passed in\n var identifier = siteIdentifier || content.identifier;\n // solution types have their own logic\n var contentUrl = getSolutionUrl(content);\n if (!contentUrl) {\n var pluralizedFamilies = [\n \"app\",\n \"dataset\",\n \"document\",\n \"map\",\n \"template\",\n ];\n // default to the catchall content route\n var path = \"/content\";\n if (content.family === \"feedback\") {\n // exception\n path = \"/feedback/surveys\";\n }\n else if (isPageContent(content)) {\n // pages are in the document family,\n // but instead of showing the page's metadata on /documents/about\n // but we render the page on the pages route\n path = \"/pages\";\n }\n else if (pluralizedFamilies.indexOf(family) > -1) {\n // the rule\n path = \"/\" + family + \"s\";\n }\n contentUrl = path + \"/\" + identifier;\n }\n return contentUrl;\n};\nvar getSolutionUrl = function (content) {\n var _a;\n var hubUrl;\n var normalizedType = content.normalizedType, identifier = content.identifier;\n if (normalizedType === \"Solution\") {\n // NOTE: as per the above spreadsheet,\n // solution types are now in the Template family\n // but we don't send them to the route for initiative templates\n if (((_a = content.typeKeywords) === null || _a === void 0 ? void 0 : _a.indexOf(\"Deployed\")) > 0) {\n // deployed solutions go to the generic content route\n hubUrl = \"/content/\" + identifier;\n }\n // others go to the solution about route\n hubUrl = \"/templates/\" + identifier + \"/about\";\n }\n return hubUrl;\n};\n// page helpers\n// TODO: we check both \"Hub Page\" and \"Site Page\" because we don't know whether the site is a portal or not\n// In the future, the site object will have a site.isPortal() function that we can leverage\n// instead of hardcoding the types here.\n// TODO: should this be based on normalizedType instead?\nvar isPageContent = function (content) {\n return includes([\"Hub Page\", \"Site Page\"], content.type);\n};\n//# sourceMappingURL=index.js.map","\"use strict\";\n\n/**\n * Implementation of atob() according to the HTML and Infra specs, except that\n * instead of throwing INVALID_CHARACTER_ERR we return null.\n */\nfunction atob(data) {\n // Web IDL requires DOMStrings to just be converted using ECMAScript\n // ToString, which in our case amounts to using a template literal.\n data = `${data}`;\n // \"Remove all ASCII whitespace from data.\"\n data = data.replace(/[ \\t\\n\\f\\r]/g, \"\");\n // \"If data's length divides by 4 leaving no remainder, then: if data ends\n // with one or two U+003D (=) code points, then remove them from data.\"\n if (data.length % 4 === 0) {\n data = data.replace(/==?$/, \"\");\n }\n // \"If data's length divides by 4 leaving a remainder of 1, then return\n // failure.\"\n //\n // \"If data contains a code point that is not one of\n //\n // U+002B (+)\n // U+002F (/)\n // ASCII alphanumeric\n //\n // then return failure.\"\n if (data.length % 4 === 1 || /[^+/0-9A-Za-z]/.test(data)) {\n return null;\n }\n // \"Let output be an empty byte sequence.\"\n let output = \"\";\n // \"Let buffer be an empty buffer that can have bits appended to it.\"\n //\n // We append bits via left-shift and or. accumulatedBits is used to track\n // when we've gotten to 24 bits.\n let buffer = 0;\n let accumulatedBits = 0;\n // \"Let position be a position variable for data, initially pointing at the\n // start of data.\"\n //\n // \"While position does not point past the end of data:\"\n for (let i = 0; i < data.length; i++) {\n // \"Find the code point pointed to by position in the second column of\n // Table 1: The Base 64 Alphabet of RFC 4648. Let n be the number given in\n // the first cell of the same row.\n //\n // \"Append to buffer the six bits corresponding to n, most significant bit\n // first.\"\n //\n // atobLookup() implements the table from RFC 4648.\n buffer <<= 6;\n buffer |= atobLookup(data[i]);\n accumulatedBits += 6;\n // \"If buffer has accumulated 24 bits, interpret them as three 8-bit\n // big-endian numbers. Append three bytes with values equal to those\n // numbers to output, in the same order, and then empty buffer.\"\n if (accumulatedBits === 24) {\n output += String.fromCharCode((buffer & 0xff0000) >> 16);\n output += String.fromCharCode((buffer & 0xff00) >> 8);\n output += String.fromCharCode(buffer & 0xff);\n buffer = accumulatedBits = 0;\n }\n // \"Advance position by 1.\"\n }\n // \"If buffer is not empty, it contains either 12 or 18 bits. If it contains\n // 12 bits, then discard the last four and interpret the remaining eight as\n // an 8-bit big-endian number. If it contains 18 bits, then discard the last\n // two and interpret the remaining 16 as two 8-bit big-endian numbers. Append\n // the one or two bytes with values equal to those one or two numbers to\n // output, in the same order.\"\n if (accumulatedBits === 12) {\n buffer >>= 4;\n output += String.fromCharCode(buffer);\n } else if (accumulatedBits === 18) {\n buffer >>= 2;\n output += String.fromCharCode((buffer & 0xff00) >> 8);\n output += String.fromCharCode(buffer & 0xff);\n }\n // \"Return output.\"\n return output;\n}\n/**\n * A lookup table for atob(), which converts an ASCII character to the\n * corresponding six-bit number.\n */\n\nconst keystr =\n \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\";\n\nfunction atobLookup(chr) {\n const index = keystr.indexOf(chr);\n // Throw exception if character is not in the lookup string; should not be hit in tests\n return index < 0 ? undefined : index;\n}\n\nmodule.exports = atob;\n","\"use strict\";\n\n/**\n * btoa() as defined by the HTML and Infra specs, which mostly just references\n * RFC 4648.\n */\nfunction btoa(s) {\n let i;\n // String conversion as required by Web IDL.\n s = `${s}`;\n // \"The btoa() method must throw an \"InvalidCharacterError\" DOMException if\n // data contains any character whose code point is greater than U+00FF.\"\n for (i = 0; i < s.length; i++) {\n if (s.charCodeAt(i) > 255) {\n return null;\n }\n }\n let out = \"\";\n for (i = 0; i < s.length; i += 3) {\n const groupsOfSix = [undefined, undefined, undefined, undefined];\n groupsOfSix[0] = s.charCodeAt(i) >> 2;\n groupsOfSix[1] = (s.charCodeAt(i) & 0x03) << 4;\n if (s.length > i + 1) {\n groupsOfSix[1] |= s.charCodeAt(i + 1) >> 4;\n groupsOfSix[2] = (s.charCodeAt(i + 1) & 0x0f) << 2;\n }\n if (s.length > i + 2) {\n groupsOfSix[2] |= s.charCodeAt(i + 2) >> 6;\n groupsOfSix[3] = s.charCodeAt(i + 2) & 0x3f;\n }\n for (let j = 0; j < groupsOfSix.length; j++) {\n if (typeof groupsOfSix[j] === \"undefined\") {\n out += \"=\";\n } else {\n out += btoaLookup(groupsOfSix[j]);\n }\n }\n }\n return out;\n}\n\n/**\n * Lookup table for btoa(), which converts a six-bit number into the\n * corresponding ASCII character.\n */\nconst keystr =\n \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\";\n\nfunction btoaLookup(index) {\n if (index >= 0 && index < 64) {\n return keystr[index];\n }\n\n // Throw INVALID_CHARACTER_ERR exception here -- won't be hit in the tests.\n return undefined;\n}\n\nmodule.exports = btoa;\n","\"use strict\";\n\nconst atob = require(\"./lib/atob\");\nconst btoa = require(\"./lib/btoa\");\n\nmodule.exports = {\n atob,\n btoa\n};\n","import { SearchQueryBuilder } from \"@esri/arcgis-rest-portal\";\nimport { btoa } from \"abab\";\nimport { flattenArray } from \"../util\";\nexport var WGS84_WKID = \"4326\";\nexport var PORTAL_EXPORT_TYPES = {\n csv: {\n name: \"CSV\",\n itemTypes: [\"CSV\", \"CSV Collection\"],\n supportsProjection: true,\n },\n kml: {\n name: \"KML\",\n itemTypes: [\"KML\", \"KML Collection\"],\n supportsProjection: false,\n },\n shapefile: {\n name: \"Shapefile\",\n itemTypes: [\"Shapefile\"],\n supportsProjection: true,\n },\n fileGeodatabase: {\n name: \"File Geodatabase\",\n itemTypes: [\"File Geodatabase\"],\n supportsProjection: true,\n },\n geojson: {\n name: \"GeoJson\",\n itemTypes: [\"GeoJson\"],\n supportsProjection: false,\n },\n excel: {\n name: \"Excel\",\n itemTypes: [\"Microsoft Excel\"],\n supportsProjection: true,\n },\n featureCollection: {\n name: \"Feature Collection\",\n itemTypes: [\"Feature Collection\"],\n supportsProjection: true,\n },\n};\n/**\n * Puts a spatial reference into a serialized format that can be used\n * for item typeKeywords.\n *\n * **Note**: discards \"latestWkid\"\n *\n * In the past we used `JSON.stringify`, but that causes problems because\n * it can include commas which are interpreted by the portal [update item call](https://developers.arcgis.com/rest/users-groups-and-items/update-item.htm)\n * as being separate typekeywords. With `JSON.stringify`, equality was also\n * dependent on the order of the properties in the spatial reference.\n *\n * Check https://developers.arcgis.com/web-map-specification/objects/spatialReference/\n * for more details on what this object looks like.\n */\nexport function serializeSpatialReference(spatialReference) {\n if (typeof spatialReference === \"object\") {\n var wkid = spatialReference.wkid, wkt = spatialReference.wkt;\n return wkid ? wkid + \"\" : btoa(wkt);\n }\n else {\n return spatialReference;\n }\n}\n/**\n * spatialRefId can currently take the form of either a WKID string or a\n * serialized ISpatialReference object.\n *\n * TODO - we shouldn't need this function. Instead, spatialRefId should\n * always be consistent, maybe by using serializeSpatialReference\n *\n * @private\n */\nfunction parseSpatialRefId(spatialRefId) {\n var _spatialRefId;\n try {\n _spatialRefId = JSON.parse(spatialRefId);\n }\n catch (_a) {\n _spatialRefId = spatialRefId;\n }\n return _spatialRefId;\n}\n/**\n * Builds the Portal API query string to search for exports from a given dataset\n *\n * @param itemId - The dataset ID\n * @param options - A set of options including item types, layerId, and spatialRefId\n * @returns\n */\nexport function buildExistingExportsPortalQuery(itemId, options) {\n var _a = maybeExtractOptions(options), onlyTypes = _a.onlyTypes, layerId = _a.layerId, spatialRefId = _a.spatialRefId;\n var formatInfos = Object.keys(PORTAL_EXPORT_TYPES).map(function (key) { return PORTAL_EXPORT_TYPES[key]; });\n var noProjectionItemTypes = new Set(flattenArray(formatInfos\n .filter(function (info) { return !info.supportsProjection; })\n .map(function (info) { return info.itemTypes; })));\n var types;\n if (!onlyTypes) {\n types = flattenArray(formatInfos.map(function (info) { return info.itemTypes; }));\n }\n else {\n types = onlyTypes;\n }\n var queryBuilder = new SearchQueryBuilder()\n .startGroup()\n .match(getExportItemTypeKeyword(itemId))\n .in(\"typekeywords\")\n .and()\n .match(getExportLayerTypeKeyword(layerId))\n .in(\"typekeywords\")\n .endGroup()\n .and()\n .startGroup();\n buildExportTypesClause(queryBuilder, {\n types: types,\n spatialRefId: spatialRefId,\n noProjectionItemTypes: noProjectionItemTypes,\n });\n queryBuilder.endGroup();\n return queryBuilder.toParam();\n}\nfunction maybeExtractOptions(options) {\n if (options) {\n return {\n onlyTypes: options.onlyTypes,\n layerId: options.layerId,\n spatialRefId: options.spatialRefId,\n };\n }\n return {};\n}\nfunction buildExportTypesClause(builder, options) {\n var types = options.types, noProjectionItemTypes = options.noProjectionItemTypes, spatialRefId = options.spatialRefId;\n var getSpatialRefIdWithDefaults = function (_spatialRefId, itemType) {\n var ret = WGS84_WKID;\n if (_spatialRefId && !noProjectionItemTypes.has(itemType)) {\n ret = _spatialRefId;\n }\n return ret;\n };\n var buildQueryForType = function (type, _builder) {\n _builder\n .startGroup()\n .match(/\\s/g.test(type) ? type : \"\\\"\" + type + \"\\\"\") // temporary logic until https://github.com/Esri/arcgis-rest-js/issues/916 is resolved\n .in(\"type\")\n .and()\n .match(getSpatialRefTypeKeyword(getSpatialRefIdWithDefaults(spatialRefId, type)))\n .in(\"typekeywords\")\n .endGroup();\n };\n types.forEach(function (type, i) {\n buildQueryForType(type, builder);\n if (i < types.length - 1) {\n builder.or();\n }\n });\n}\n/**\n * Generates typekeyword for identifying which spatialRefId an export is\n * @param spatialRefId - either a WKID, WKT, or stringified ISpatialReference\n * @private\n */\nexport function getSpatialRefTypeKeyword(spatialRefId) {\n var parsedSpatialReference = parseSpatialRefId(spatialRefId);\n var serializedSpatialReference = serializeSpatialReference(parsedSpatialReference);\n return \"spatialRefId:\" + serializedSpatialReference;\n}\n/**\n * Returns the keyword identifying exports by the item they originate from\n * @param itemId - ID for the item from which the export originated\n * @private\n */\nexport function getExportItemTypeKeyword(itemId) {\n return \"exportItem:\" + itemId;\n}\n/**\n * Returns the keyword identifying exports by the layer they originate from\n * @param layerId - ID for the layer from which the export originated\n * @private\n */\nexport function getExportLayerTypeKeyword(layerId) {\n // NOTE - Layer Id's need to be padded with \"0\" so that /search results are predictable. Searches for typeKeywords:\"exportLayer:1\" don't work.\n // See https://github.com/Esri/hub.js/pull/472 for more information.\n // TODO - use `filter` when Enterprise Sites adds support.\n return layerId ? \"exportLayer:0\" + layerId : \"exportLayer:null\";\n}\n//# sourceMappingURL=build-existing-exports-portal-query.js.map","import { failSafe } from \"../utils\";\nimport { unprotectGroup, removeGroup } from \"@esri/arcgis-rest-portal\";\n/**\n * Unprotect and Remove a Group.\n * Assumed caller has checked that the current user should be able\n * to unprotect and remove the group. Underlying calls are failsafe\n * so a failure to unprotect or remove the group will not reject\n * @param {IUserGroupOptions} userGroupOptions id and authentication\n * @private\n */\nexport function _unprotectAndRemoveGroup(userGroupOptions) {\n var failSafeUnprotect = failSafe(unprotectGroup, { success: true });\n var failSafeRemove = failSafe(removeGroup, { success: true });\n return failSafeUnprotect(userGroupOptions).then(function () {\n return failSafeRemove(userGroupOptions);\n });\n}\n//# sourceMappingURL=_unprotect-and-remove-group.js.map","import { getWithDefault } from \"../../../objects/get-with-default\";\n/**\n * @private\n */\nexport function _consolidateResults(context) {\n var autoAddResult = context.autoAddResult, inviteResult = context.inviteResult, primaryEmailResult = context.primaryEmailResult, secondaryEmailResult = context.secondaryEmailResult;\n var combinedEmailResults;\n if (primaryEmailResult || secondaryEmailResult) {\n var validResults = [primaryEmailResult, secondaryEmailResult].filter(function (r) { return r; });\n var combinedSuccess = validResults.every(function (r) { return r.success; });\n var combinedErrors = validResults.reduce(function (collection, r) { return collection.concat(getWithDefault(r, \"errors\", [])); }, []);\n combinedEmailResults = {\n success: combinedSuccess\n };\n if (combinedErrors.length) {\n combinedEmailResults.errors = combinedErrors;\n }\n }\n var overallSuccess = [autoAddResult, inviteResult, combinedEmailResults]\n .filter(function (r) { return r; })\n .every(function (r) { return r.success; });\n return {\n success: overallSuccess,\n autoAdd: autoAddResult,\n invite: inviteResult,\n email: combinedEmailResults\n };\n}\n//# sourceMappingURL=_consolidate-results.js.map","import { ArcGISRequestError } from \"@esri/arcgis-rest-request\";\nimport { getProp } from \"../../../objects/get-prop\";\nimport { includes } from \"../../../utils\";\n/**\n * @private\n *\n * Coerce autoAdd response into a more similar interface as\n * the other rest calls.\n *\n * If any users are not auto added, an error is added to the response\n * and unadded users are placed into the invitation list\n */\nexport function _formatAutoAddResponse(rawResponse, context) {\n if (rawResponse) {\n var success = !getProp(rawResponse, \"notAdded.length\") && !rawResponse.errors;\n context.autoAddResult = { success: success };\n if (!success) {\n var errors = rawResponse.errors || [];\n if (getProp(rawResponse, \"notAdded.length\")) {\n errors.push(new ArcGISRequestError(\"Users not auto-added: \" + rawResponse.notAdded.join(\", \")));\n }\n context.autoAddResult.errors = errors;\n // Move unadded users to invite list;\n var unaddedUsers = context.usersToAutoAdd.filter(function (user) {\n return includes(rawResponse.notAdded, user.username);\n });\n context.usersToInvite = context.usersToInvite.concat(unaddedUsers);\n }\n }\n return context;\n}\n//# sourceMappingURL=_format-auto-add-response.js.map","/**\n * @private\n *\n * returns whether or not the users are in the same org\n */\nexport function _canEmailUser(recipient, sender) {\n return recipient.orgId === sender.orgId;\n}\n//# sourceMappingURL=_can-email-user.js.map","/**\n * @private\n */\nexport function _isOrgAdmin(user) {\n return user.role === \"org_admin\" && !user.roleId;\n}\n//# sourceMappingURL=_is-org-admin.js.map","import { createOrgNotification } from \"@esri/arcgis-rest-portal\";\n/**\n * Attempts to email members of the requesting user's organization.\n *\n * @param {IUser[]} users Users to email (must be in the same org as the requesting user)\n * @param {IEmail} email\n * @param {IAuthenticationManager} authentication\n * @param {boolean} isOrgAdmin // Whether the requesting user in an org admin\n *\n * @returns {object|null} A promise that resolves to the result of the transaction (null if no users are passed in)\n */\nexport function emailOrgUsers(users, email, authentication, isOrgAdmin) {\n var response = Promise.resolve(null);\n if (users.length) {\n var args = {\n authentication: authentication,\n message: email.body,\n subject: email.subject,\n notificationChannelType: \"email\",\n users: users.map(function (u) { return u.username; })\n };\n if (!isOrgAdmin) {\n args.batchSize = 1;\n }\n response = createOrgNotification(args);\n }\n return response;\n}\n//# sourceMappingURL=email-org-users.js.map","import { _canEmailUser } from \"../../add-users-workflow/utils/_can-email-user\";\nimport { _isOrgAdmin } from \"../../add-users-workflow/utils/_is-org-admin\";\nimport { getProp, getWithDefault } from \"../../../objects\";\nimport { emailOrgUsers } from \"../workflow-sections/email-org-users\";\n/**\n * @private\n *\n * If a secondary authentication is passed in AND\n * an email object is passed in AND\n * the previous invitation call was successful:\n *\n * Send an email notification to the invited\n * users that are part of the secondary authentication's org\n */\nexport function _processSecondaryEmail(context) {\n var response = Promise.resolve(context);\n // If secondaryRO provided, send email to the invited users in the secondaryRO's org (typically a community org)\n if (context.email &&\n context.secondaryRO &&\n getProp(context, \"inviteResult.success\")) {\n var secondaryUser_1 = getWithDefault(context, \"secondaryRO.portalSelf.user\", {});\n var secondaryOrgUsersToEmail = context.usersToInvite.filter(function (u) {\n return _canEmailUser(u, secondaryUser_1);\n });\n response = emailOrgUsers(secondaryOrgUsersToEmail, context.email, context.secondaryRO.authentication, _isOrgAdmin(secondaryUser_1)).then(function (result) {\n context.secondaryEmailResult = result;\n return context;\n });\n }\n return response;\n}\n//# sourceMappingURL=_process-secondary-email.js.map","import { addGroupUsers } from \"@esri/arcgis-rest-portal\";\n/**\n *\n * Attempts to auto-add users to a group\n *\n * @param {string} id ID of the group the users will be added to\n * @param {IUser[]} users\n * @param {IAuthenticationManager} authentication\n *\n * @returns {IAddGroupUsersResult|null} Result of the transaction (null if no users are passed in)\n */\nexport function autoAddUsers(id, users, authentication) {\n var response = Promise.resolve(null);\n if (users.length) {\n var args = {\n id: id,\n users: users.map(function (u) { return u.username; }),\n authentication: authentication\n };\n response = addGroupUsers(args);\n }\n return response;\n}\n//# sourceMappingURL=auto-add-users.js.map","import { getProp } from \"../../../objects/get-prop\";\nimport { autoAddUsers } from \"../workflow-sections/auto-add-users\";\nimport { _formatAutoAddResponse } from \"./_format-auto-add-response\";\n/**\n * @private\n */\nexport function _processAutoAdd(context) {\n return autoAddUsers(getProp(context, \"groupId\"), getProp(context, \"usersToAutoAdd\"), getProp(context, \"primaryRO.authentication\")).then(function (rawResponse) { return _formatAutoAddResponse(rawResponse, context); });\n}\n//# sourceMappingURL=_process-auto-add.js.map","import { inviteGroupUsers, } from \"@esri/arcgis-rest-portal\";\n/**\n *\n * Attempts to invite users to a group\n *\n * @param {string} id ID of the group the users will be invited to\n * @param {object[]} users\n * @param {object} authentication\n * @param {number} expiration How long the invite will be active (in minutes)\n * @param {string} role What role should they be added as. Defaults to group member\n *\n * @returns {object|null} Result of the transaction (null if no users are passed in)\n */\nexport function inviteUsers(id, users, authentication, expiration, // default to 2 week expiration TODO: is this actually 2 weeks?\nrole // default to group member, but allow for team_admin as well\n) {\n if (expiration === void 0) { expiration = 20160; }\n if (role === void 0) { role = \"group_member\"; }\n var response = Promise.resolve(null);\n if (users.length) {\n var args = {\n id: id,\n users: users.map(function (u) { return u.username; }),\n authentication: authentication,\n role: role,\n expiration: expiration,\n };\n response = inviteGroupUsers(args);\n }\n return response;\n}\n//# sourceMappingURL=invite-users.js.map","import { getProp } from \"../../../objects/get-prop\";\nimport { inviteUsers } from \"../workflow-sections/invite-users\";\n/**\n * @private\n */\nexport function _processInvite(context) {\n return inviteUsers(getProp(context, \"groupId\"), getProp(context, \"usersToInvite\"), getProp(context, \"primaryRO.authentication\")).then(function (result) {\n context.inviteResult = result;\n return context;\n });\n}\n//# sourceMappingURL=_process-invite.js.map","import { getProp } from \"../../../objects/get-prop\";\nimport { _isOrgAdmin } from \"../utils/_is-org-admin\";\nimport { emailOrgUsers } from \"../workflow-sections/email-org-users\";\n/**\n * @private\n *\n * Send email notification if an email object is present and\n * the previous invitation call was successful\n */\nexport function _processPrimaryEmail(context) {\n var response = Promise.resolve(context);\n // Email users if invite succeeds\n if (context.email && getProp(context, \"inviteResult.success\")) {\n response = emailOrgUsers(context.usersToEmail, context.email, context.primaryRO.authentication, _isOrgAdmin(context.requestingUser)).then(function (result) {\n context.primaryEmailResult = result;\n return context;\n });\n }\n return response;\n}\n//# sourceMappingURL=_process-primary-email.js.map","/**\n * @private\n *\n * A user can be auto-added if they are part of the requesting user's e-org\n * or c-org and the requesting user has the assignToGroups privilege\n */\nexport function _getAutoAddUsers(users, requestingUser) {\n var usersToAutoAdd = [];\n if (requestingUser.privileges.indexOf(\"portal:admin:assignToGroups\") !== -1) {\n var orgIds_1 = [requestingUser.orgId, requestingUser.cOrgId].filter(function (o) { return o; });\n usersToAutoAdd = users.filter(function (u) { return orgIds_1.indexOf(u.orgId) !== -1; });\n }\n return usersToAutoAdd;\n}\n//# sourceMappingURL=_get-auto-add-users.js.map","import { _getAutoAddUsers } from \"./_get-auto-add-users\";\n/**\n * @private\n *\n * A user will be invited if they cannot be auto-added\n */\nexport function _getInviteUsers(users, requestingUser) {\n var autoAddedUsers = _getAutoAddUsers(users, requestingUser);\n return users.filter(function (user) { return !autoAddedUsers.some(function (aau) { return aau.username === user.username; }); });\n}\n//# sourceMappingURL=_get-invite-users.js.map","import { _canEmailUser } from \"./_can-email-user\";\nimport { _getInviteUsers } from \"./_get-invite-users\";\n/**\n * @private\n *\n * A user can be emailed if they are invited (not auto-added)\n * and the _canEmailUser condition is met\n */\nexport function _getEmailUsers(users, requestingUser, includeSelf) {\n if (includeSelf === void 0) { includeSelf = false; }\n var invitedUsers = _getInviteUsers(users, requestingUser);\n var emailUsers = invitedUsers.filter(function (user) {\n return _canEmailUser(user, requestingUser);\n });\n if (includeSelf) {\n emailUsers.push(requestingUser);\n }\n return emailUsers;\n}\n//# sourceMappingURL=_get-email-users.js.map","import { getProp } from \"../../objects/get-prop\";\nimport { getWithDefault } from \"../../objects/get-with-default\";\nimport { cloneObject } from \"../../util\";\nimport { _consolidateResults } from \"./output-processors/_consolidate-results\";\nimport { _processAutoAdd } from \"./output-processors/_process-auto-add\";\nimport { _processInvite } from \"./output-processors/_process-invite\";\nimport { _processPrimaryEmail } from \"./output-processors/_process-primary-email\";\nimport { _processSecondaryEmail } from \"./output-processors/_process-secondary-email\";\nimport { _getAutoAddUsers } from \"./utils/_get-auto-add-users\";\nimport { _getEmailUsers } from \"./utils/_get-email-users\";\nimport { _getInviteUsers } from \"./utils/_get-invite-users\";\n/**\n * Adds, invites or emails users about joining a group\n * based on the permissions of the requesting user. The\n * function returns a hash of results indicating which\n * operations were attempted and whether they were successful.\n *\n * In general, this algorithm will auto-add all the users\n * that it can, invite the others, and send emails to eligible\n * invited users (See below for more details)\n *\n * Here are a couple caveats to be aware of:\n * 1) If the requestingUser can auto-add to the group (A.K.A. has\n * portal:admin:assignToGroups) no email will be sent, period.\n * 2) Emails can only be sent to members of the same org as the\n * requesting user if they have been invited (not auto-added)\n * to the group. If emails must to be sent to invited members\n * of a second org (e.g a community org), an authenticated user\n * of the second org must be passed in (see secondaryRO)\n * 3) If no email is passed in, no email will be sent\n * 4) If auto-adding fails, the unadded users will be invited\n *\n * @param {string} groupId\n * @param {IUser[]} allUsers\n * @param {IHubRequestOptions} primaryRO Info and authentication for the requesting user\n * @param {IEmail} [email] Email to be sent (if qualifying users are passed in)\n * @param {IHubRequestOptions} [secondaryRO] Info and authentication for emailing members of a secondary organization (typically a community org)\n *\n * @returns {IConsolidatedResult} The operations attempted, whether they were successful and any errors\n */\nexport function addUsersToGroup(groupId, allUsers, primaryRO, email, secondaryRO) {\n // Extract requesting user\n var requestingUser = cloneObject(getWithDefault(primaryRO, \"portalSelf.user\", {}));\n requestingUser.cOrgId = getProp(primaryRO, \"portalSelf.portalProperties.hub.settings.communityOrg.orgId\");\n // Context for each process segment\n var context = {\n groupId: groupId,\n allUsers: allUsers,\n primaryRO: primaryRO,\n email: email,\n secondaryRO: secondaryRO,\n requestingUser: requestingUser,\n usersToAutoAdd: _getAutoAddUsers(allUsers, requestingUser),\n usersToInvite: _getInviteUsers(allUsers, requestingUser),\n usersToEmail: _getEmailUsers(allUsers, requestingUser, getProp(email, \"copyMe\"))\n };\n return _processAutoAdd(context)\n .then(_processInvite)\n .then(_processPrimaryEmail)\n .then(_processSecondaryEmail)\n .then(_consolidateResults);\n}\n//# sourceMappingURL=add-users-to-group.js.map","import { unprotectItem, removeItem } from \"@esri/arcgis-rest-portal\";\nimport { failSafe } from \"../utils\";\n/**\n * Unprotect and Remove an Item\n * Assumes caller has checked that the curernt user should be able to\n * unprotect and remove the item. Underlying calls are failsafe\n * so a failure to unprotect or temove the item will not reject.\n * @param {IUserItemOptions} userItemOptions id and authentication\n * @private\n */\nexport function _unprotectAndRemoveItem(userItemOptions) {\n var failSafeUnprotect = failSafe(unprotectItem, { success: true });\n var failSafeRemove = failSafe(removeItem, { success: true });\n return failSafeUnprotect(userItemOptions).then(function () {\n return failSafeRemove(userItemOptions);\n });\n}\n//# sourceMappingURL=_unprotect-and-remove-item.js.map","/**\n * Apply a hash of properties to an array of items.\n * Extracted to simplify testing.\n * @param {array} items Array of items to apply the properties to\n * @param {object} props hash of properties to apply to the item\n */\nexport function applyPropertiesToItems(items, props) {\n return items.map(function (item) {\n if (!item.properties) {\n item.properties = {};\n }\n Object.assign(item.properties, props);\n return item;\n });\n}\n//# sourceMappingURL=apply-properties-to-items.js.map","/**\n * Delete a property from an object using a deep path\n * MODIFIES PASSED TARGET\n * @param {Object} target Object from which we want to delete the property\n * @param {string} path Dotted path to the property we want to delete\n */\nexport function deleteProp(target, lookupStr) {\n if (typeof target !== \"object\" || target === null)\n return;\n if (typeof lookupStr !== \"string\")\n return;\n var lookupKeys = lookupStr.split(\".\");\n for (var i = 0; i < lookupKeys.length - 1; i++) {\n if (!target.hasOwnProperty(lookupKeys[i]))\n return;\n target = target[lookupKeys[i]];\n }\n delete target[lookupKeys[lookupKeys.length - 1]];\n}\n//# sourceMappingURL=delete-prop.js.map","import { cloneObject } from \"../util\";\n/**\n * Given a model, return a serialized clone that can be sent to\n * the items api\n * @param {Object} model Item model {item:{}, data:{}}\n */\nexport function serializeModel(model) {\n var serialized = cloneObject(model.item);\n serialized.text = JSON.stringify(model.data);\n return serialized;\n}\n//# sourceMappingURL=serialize-model.js.map","import { updateItem } from \"@esri/arcgis-rest-portal\";\nimport { serializeModel } from \"./serialize-model\";\nimport { failSafe } from \"../utils\";\n/**\n * Update a model's item, wrapped in a failSafe so this will not blow up if\n * the user lacks rights somehow. This should be used in places where there is\n * a high-probability that the current user CAN update the item.\n * @param {Object} model Model object to be updated\n * @param {IRequestOptions} requestOptions\n */\nexport function failSafeUpdate(model, requestOptions) {\n var failSafedUpdate = failSafe(updateItem, {\n id: model.item.id,\n success: true\n });\n var opts = Object.assign({ item: serializeModel(model) }, requestOptions);\n return failSafedUpdate(opts);\n}\n//# sourceMappingURL=fail-safe-update.js.map","import { getItem, getItemData } from \"@esri/arcgis-rest-portal\";\n/**\n * Gets the full item/data model for an item\n * @param {string} id Id of the item to fetch\n * @param {Object} requestOptions\n */\nexport function getModel(id, requestOptions) {\n return Promise.all([\n getItem(id, requestOptions),\n getItemData(id, requestOptions)\n ]).then(function (result) {\n // shape this into a model\n return {\n item: result[0],\n data: result[1]\n };\n });\n}\n//# sourceMappingURL=get-model.js.map","import { failSafe } from \"../utils\";\nimport { getModel } from \"./get-model\";\n/**\n * To streamline passing of either a model id or the model itself, we use this function\n * to extract the model or fetch it, and return it. It uses `failSafe` and if the item\n * is not accessible for whatever reason, will return a model-ish object with `isMissing: true`\n * It is up to the caller to take approriate action\n * @param {String} modelType the type of model to extract from the options hash\n * @param {Object} options Something that extends IRequestOptions\n */\nexport function getModelFromOptions(modelType, options) {\n var modelProp = modelType + \"Model\";\n var idProp = modelType + \"Id\";\n // if the options hash has the model, return it\n if (options[modelProp]) {\n return Promise.resolve(options[modelProp]);\n }\n else {\n if (options[idProp]) {\n var failSafeModel = failSafe(getModel, {\n item: { id: options[idProp] },\n isMissing: true\n });\n return failSafeModel(options[idProp], options);\n }\n else {\n throw new Error(\"getModelFromOptions requires either a .\" + modelProp + \" or .\" + idProp + \" property.\");\n }\n }\n}\n//# sourceMappingURL=get-model-from-options.js.map","/**\n* adlib - v3.0.6 - Thu Dec 17 2020 17:08:08 GMT-0800 (Pacific Standard Time)\n* Copyright (c) 2017-2020 Dave Bouwman / Esri\n* Apache-2.0\n*/\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * Return the value of a deep property, using a path.\n */\nvar getWithDefault = function (obj, path, defaultValue) {\n if ( defaultValue === void 0 ) defaultValue = undefined;\n\n return path\n .split('.')\n .reduce(function (o, p) { return o ? o[p] : defaultValue; }, obj);\n};\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * Simply Map over the props of an object\n */\nfunction mapValues (obj, fn) {\n var keys = Object.keys(obj);\n // console.info(`keys: ${keys}`);\n var newObject = keys.reduce(function(acc, currentKey) {\n // console.log(` acc: ${JSON.stringify(acc)} curKey: ${currentKey}`);\n acc[currentKey] = fn(obj[currentKey], currentKey, obj);\n return acc;\n }, {});\n // console.info(` output: ${JSON.stringify(newObject)}`);\n return newObject;\n}\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\nvar isDate = function (v) { return v instanceof Date; };\n\nvar isFunction = function (v) { return typeof v === 'function'; };\n\nvar isObject = function (v) { return typeof v === 'object'; };\n\nvar isRegExp = function (v) { return v instanceof RegExp; };\n\nfunction deepMapValues(object, callback, propertyPath) {\n propertyPath = propertyPath || '';\n if(Array.isArray(object)){\n return object.map(deepMapValuesIteratee);\n }\n else if(object && isObject(object) && !isDate(object) && !isRegExp(object) && !isFunction(object)){\n return Object.assign({}, object, mapValues(object, deepMapValuesIteratee));\n }\n else {\n var output = callback(object, propertyPath);\n return output;\n }\n\n function deepMapValuesIteratee(value, key){\n var valuePath = propertyPath ? propertyPath + '.' + key : key;\n return deepMapValues(value, callback, valuePath);\n }\n}\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\nvar isObject$1 = function (v) { return typeof v === 'object'; };\n\n/**\n * Trim a tree decorated with `{{delete:NNN}}`\n */\nfunction arborist (object, propertyPath) {\n\n if(Array.isArray(object)){\n // filter out any nulls...\n var arrResults = object.map(iteratee).filter(function (entry) {\n // need to ensure entry is actually NULL vs just falsey\n return entry !== null && entry !== undefined;\n });\n return pruneArray(arrResults);\n\n } if(object && isObject$1(object) ) {\n\n return pruneObject(mapValues(object, iteratee));\n\n } else {\n\n return getPropertyValue(object);\n }\n\n function iteratee(value, key){\n return arborist(value);\n }\n}\n\n/**\n * Prune an array\n * For all the entries in the array...\n * if the entry is a naked string and contains `{{delete:NNN}}`\n * get maximum NNN value\n * then\n * if maxN === 0\n * return an empty array\n * if maxN > 0\n * return `{{delete:maxN-1}}`\n * else\n * return array\n */\nfunction pruneArray (arrResults) {\n var res = arrResults;\n // is any entry a string w/ {{delete}}?\n var maxLevel = arrResults.reduce(function (maxLevel, e) {\n if (isString(e) && hasDelete(e)) {\n var lvl = getLevel(e);\n if (lvl > maxLevel) {\n maxLevel = lvl;\n }\n }\n return maxLevel;\n }, -1);\n\n if (maxLevel > -1) {\n if (maxLevel === 0) {\n res = [];\n } else {\n res = \"{{delete:\" + (maxLevel - 1) + \"}}\";\n }\n }\n\n return res;\n}\n\n\nfunction pruneObject (objResults) {\n // console.log(` pruneObject:: working on ${JSON.stringify(objResults)}`);\n var startVal = {obj: {}, maxLevel: -1 };\n var res;\n // cook a new clone object, and track the maxLevel\n var reduction = Object.keys(objResults).reduce(function (acc, key) {\n var val = objResults[key];\n if (isString(val) && hasDelete(val)) {\n var lvl = getLevel(val);\n if (lvl > acc.maxLevel) {\n acc.maxLevel = lvl;\n }\n } else {\n // only add the prop if it's not a `{{delete:NNN}}`\n acc.obj[key] = val;\n }\n return acc;\n }, startVal);\n // if -1, we return entire object...\n // if 0 we just remove the prop...\n // if 1 we return undefined...\n // if > 1 we return the deleteVal\n if (reduction.maxLevel > 0 ) {\n if (reduction.maxLevel === 1) {\n res = undefined;\n } else {\n res = \"{{delete:\" + (reduction.maxLevel - 1) + \"}}\";\n }\n } else {\n res = reduction.obj;\n }\n\n // console.log(` returning ${JSON.stringify(res)}`);\n return res;\n}\n\n/**\n * Get a value for a property, handling the `{{delete:NNN}}` syntax\n */\nfunction getPropertyValue (val){\n var output = val;\n\n if (typeof val === 'string') {\n if (hasDelete(val)) {\n output = getDeleteValue(val);\n }\n }\n return output;\n}\n\n/**\n * Given a string with `{{delete:NNN}}`\n * if NNN === 0 return undefined\n * else return `{{delete:NNN - 1}}`\n */\nfunction getDeleteValue (val) {\n var output = val;\n var level = getLevel(val);\n if (level === 0) {\n output = undefined;\n } else {\n output = \"{{delete:\" + level + \"}}\";\n }\n return output;\n}\n\n/**\n * Extract the level from a `{{delete:NNN}}`\n */\nvar getLevel = function (value) { return parseInt(value.replace(/{|}/g, '').split(':')[1]); };\n\n/**\n * Simple check if a value has `{{delete` in it\n */\nfunction hasDelete (value) {\n if (value && typeof value === 'string') {\n return value.indexOf('{{delete') > -1;\n } else {\n return false;\n }\n}\n\nvar isString = function (v) { return typeof v === 'string'; };\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * Optional Transform\n * Supports a declarative syntax for optional template properties\n *\n * {{some.object.key:optional:2}}\n *\n * In this example, if defined, the value of `some.object.key` is used.\n * If not defined, then the optional transform is utilized\n * and a post-processing step is executed which will remove two parent levels\n * from the output structure\n */\n\nfunction optionalTransform(key, value, settings, level) {\n if ( level === void 0 ) level = 0;\n\n // console.log(`optional: ${key}, ${value}, ${level}`);\n var val = value;\n if (!value) {\n val = \"{{delete:\" + level + \"}}\";\n }\n return val;\n}\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * ```js\n * import { cloneObject } from \"./cloneObject\";\n * const original = { foo: \"bar\" }\n * const copy = cloneObject(original)\n * copy.foo // \"bar\"\n * copy === original // false\n * ```\n * Make a deep clone, including arrays. Does not handle functions!\n *\n * Copied from @esri/hub-common to avoid bringing along that package's\n * dependencies, @esri/hub-common should be made a dependency if more\n * functions are needed from it in the future\n */\nvar cloneObject = function (obj) {\n var clone = {};\n // first check array\n if (Array.isArray(obj)) {\n clone = obj.map(cloneObject);\n } else if (typeof obj === \"object\") {\n for (var i in obj) {\n if (obj[i] != null && typeof obj[i] === \"object\") {\n clone[i] = cloneObject(obj[i]);\n } else {\n clone[i] = obj[i];\n }\n }\n } else {\n clone = obj;\n }\n return clone;\n};\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\nvar HANDLEBARS = /{{\\s*?[\\w].*?}}/g;\n\nvar isString$1 = function (v) { return typeof v === 'string'; };\n\nfunction _swap(parameter, settings, transforms) {\n var value;\n // console.info(`_swap: param: ${parameter}`);\n // Parameters can optionally call transform functions\n // e.g. \"{{ipsum:translateLatin}}\"\n // so extract {{<parameter>:<transformFunction>:<key||value>}}\n var transformCheck = parameter.split(':');\n if (transformCheck.length > 1) {\n // we have a request to use a transform...\n var key = transformCheck[0];\n var fn = transformCheck[1];\n // we default to using the value...\n var param;\n if (transformCheck[2]){\n param = transformCheck[2];\n }\n if(transforms && transforms[fn] && typeof transforms[fn] === 'function') {\n // get the value from the param\n value = getWithDefault(settings, key);\n // transform it...\n value = transforms[fn](key, value, settings, param);\n } else {\n throw new Error((\"Attempted to apply non-existant transform \" + fn + \" on \" + key + \" with params \" + parameter));\n }\n } else {\n // we just get the value\n value = getWithDefault(settings, parameter);\n }\n return value;\n}\n\n/**\n * Does a propertyPath exist on a target\n */\nfunction _propertyPathExists (propertyPath, target) {\n // remove any transforms\n var cleanPath = propertyPath.split(':')[0];\n var value = getWithDefault(target, cleanPath, null);\n if (value !== null && value !== undefined) {\n return true;\n } else {\n return false;\n }\n}\n\n/**\n * Is the value considered valid\n */\nfunction _isValue (val) {\n return val || val === '' || val === 0;\n}\n\n// Combine a Template with Settings\nfunction adlib (template, settings, transforms) {\n if ( transforms === void 0 ) transforms = null;\n\n transforms = cloneObject(transforms) || {};\n if (transforms.optional) {\n throw new Error('Please do not pass in an `optional` transform; adlib provides that internally.');\n } else {\n transforms.optional = optionalTransform;\n }\n\n var res = deepMapValues(template, function(templateValue, templatePath){\n // Only string templates\n if (!isString$1(templateValue)) {\n return templateValue;\n }\n\n // When we match \"{{layer.fields..}}\"\n var settingsValue;\n\n var hbsEntries = templateValue.match(HANDLEBARS);\n\n if (hbsEntries && hbsEntries.length) {\n // console.log(`Got a ${hbsEntries.length} handlebar entries...`);\n // iterate over the entries...\n var values = hbsEntries.map(function (entry) {\n var isStaticValue = false;\n // console.info(`Matched ${entry}...`);\n // strip off the curlies and trim any leading/trailing whitespace...\n var path = entry.replace(/{|}/g, '').trim();\n // check for || which indicate a hiearchy\n if (path.indexOf('||') > -1) {\n var paths = path.split('||').map(function (path) { return path.trim(); });\n var numberOfPaths = paths.length;\n // here we check each option, in order, and return the first with a value in the hash, OR the last\n path = paths.find(function (pathOption, idx) {\n // console.info(`Checking to see if ${pathOption} is in settings hash...`);\n var exists = _propertyPathExists(pathOption, settings);\n if (!exists) {\n if ((idx + 1) === numberOfPaths) {\n // console.info(`Got to last entry, and still did not find anything... assuming ${pathOption} is a static value...`);\n isStaticValue = true;\n // check if we can convert this into a number...\n if (!isNaN(pathOption)) {\n pathOption = parseInt(pathOption);\n }\n return pathOption;\n } else {\n return false;\n }\n } else {\n return pathOption;\n }\n });\n }\n // setup the return value...\n var result = {\n key: entry,\n value: path\n };\n // if we have a valid object path, value comes from _swap\n if (!isStaticValue) {\n var swap = _swap(path, settings, transforms);\n result.value = _isValue(swap) ? swap : entry;\n }\n // console.info(`Value: ${JSON.stringify(result)}`);\n return result;\n });\n\n values.forEach(function (v) {\n // console.log(`Comparing ${templateValue} with ${v.key}`)\n if (templateValue === v.key) {\n // console.log(`template matches key, returning ${v.value}`);\n // if the value is a string...\n if (typeof v.value === 'string') {\n // and it's numeric-ish\n if(!isNaN(v.value) && v.value !== '') {\n // and has a . in it...\n if (v.value.indexOf('.') > -1) {\n // parse as a float...\n v.value = parseFloat(v.value);\n } else {\n // parse as an int\n v.value = parseInt(v.value);\n }\n }\n }\n settingsValue = v.value;\n } else {\n // a little extra regex dance to match the '||' because '|'\n // is a Very Special Regex Character and we need to super\n // escape them for the regex to work\n // console.log(`KEY ${v.key}`);\n // console.log(`TEMPLATE ${templateValue}`);\n templateValue = templateValue.replace(v.key, v.value);\n // console.log(`template did not match key, interpolating value ${v.value} into template to produce ${templateValue}`);\n }\n });\n\n // if we have a value, let's return that...\n if (_isValue(settingsValue)) {\n // console.log(`We found a value so we return it ${settingsValue}`);\n return settingsValue;\n } else {\n // console.log(`We did not find a value so we return the template ${templateValue}`);\n // but if we don't, lets return the template itself\n return templateValue;\n }\n } else {\n // console.log(`We did not find a hbs match, so we return the template ${templateValue}`);\n // no match, return the templateValue...\n return templateValue;\n }\n });\n return arborist(res);\n}\n\n// read a template and spit out unique values\nfunction listDependencies (template) {\n if (typeof template !== 'string') {\n template = JSON.stringify(template);\n }\n\n try {\n return Array.from(\n new Set(\n template.match(HANDLEBARS)\n )\n )\n .map(function (term) {\n return term.replace(/^{{/g, '').replace(/}}$/g, '').replace(/:.+$/, '')\n // Node > 10 and browsers support this w/ a lookahead\n // won't need to use the replace\n // /(?<={{)[\\w].*?(?=}})/g\n })\n } catch (e) {\n console.error(e);\n }\n}\n\nexport { adlib, arborist, deepMapValues, getPropertyValue, getWithDefault, listDependencies, mapValues, optionalTransform, pruneArray, pruneObject };\n","import { adlib } from \"adlib\";\n/**\n * Interpolates handlebars-style placeholders on an object graph\n * @param template\n * @param settings\n * @param transforms\n */\nexport function interpolate(template, settings, transforms) {\n return adlib(template, settings, transforms);\n}\n//# sourceMappingURL=interpolate.js.map","import { interpolate } from \"./interpolate\";\n/**\n * Interpolate the item id back into any {{appid}} instances\n * in the item. Allows for self-referencing in templates\n * @param {object} model Item Model\n */\nexport function interpolateItemId(model) {\n var settings = { item: { id: model.item.id }, appid: model.item.id };\n var transforms = {\n toISO: function (_, v) {\n return v;\n }\n };\n return interpolate(model, settings, transforms);\n}\n//# sourceMappingURL=interpolate-item-id.js.map","import { cloneObject } from \"../util\";\nexport var itemPropsNotInTemplates = [\n \"id\",\n \"isOrgItem\",\n \"proxyFilter\",\n \"ownerFolder\",\n \"protected\",\n \"owner\",\n \"created\",\n \"modified\",\n \"guid\",\n \"name\",\n \"access\",\n \"size\",\n \"listed\",\n \"numComments\",\n \"numRatings\",\n \"avgRating\",\n \"numViews\",\n \"scoreCompleteness\",\n \"groupDesignations\",\n \"listed\",\n \"screenshots\",\n \"banner\",\n \"appCategories\",\n \"industries\",\n \"languages\",\n \"largeThumbnail\"\n];\n/**\n * Given an item, remove a standard set of properties not needed in a template\n * TODO: This should land in a templating helper lib in hub.js\n * @param {Object} item Item to be normalized\n */\nexport function normalizeSolutionTemplateItem(item) {\n var template = cloneObject(item);\n itemPropsNotInTemplates.forEach(function (prop) {\n delete template[prop];\n });\n // set a bunch of things we do want\n template.extent = \"{{organization.defaultExtentBBox}}\";\n return template;\n}\n//# sourceMappingURL=normalize-solution-template-item.js.map","import { cloneObject } from \"../util\";\nimport { deepStringReplace } from \"../objects\";\n/**\n * Replaces instances of item ids on an item model\n * @param {Object} obj Object graph to traverse\n * @param {string} itemId id to replace with `{{appid}}`\n */\nexport function replaceItemId(obj, itemId, replacement) {\n if (replacement === void 0) { replacement = \"{{appid}}\"; }\n var clone = cloneObject(obj);\n var re = new RegExp(itemId, \"g\");\n return deepStringReplace(clone, re, replacement);\n}\n//# sourceMappingURL=replace-item-id.js.map","import { shareItemWithGroup, } from \"@esri/arcgis-rest-portal\";\n/**\n * Share an item to a set of groups\n * @param {String} itemId Iten Id to share to the groups\n * @param {Array} groups Array of group id's to which the item will be shared\n * @param {String} owner optional Owner username to determine which endpoint to hit\n * @param {*} requestOptions\n */\nexport function shareItemToGroups(itemId, groups, requestOptions, owner) {\n return Promise.all(groups.map(function (groupId) {\n var opt = Object.assign({}, { id: itemId, groupId: groupId }, requestOptions);\n if (owner) {\n opt.owner = owner;\n }\n return shareItemWithGroup(opt);\n }));\n}\n//# sourceMappingURL=share-item-to-groups.js.map","import { unprotectItem } from \"@esri/arcgis-rest-portal\";\n/**\n * Given a model, determine if it is protected, and unprotect it if it is.\n * Otherwise, just resolve with the same result.\n * @param {Object} model Model Object\n * @param {IRequestOptions} requestOptions\n */\nexport function unprotectModel(model, requestOptions) {\n if (model.item.protected) {\n var opts = Object.assign({ id: model.item.id }, requestOptions);\n return unprotectItem(opts);\n }\n else {\n // act as though we did it\n return Promise.resolve({ success: true });\n }\n}\n//# sourceMappingURL=unprotect-model.js.map","import { unshareItemWithGroup, } from \"@esri/arcgis-rest-portal\";\n/**\n * Unshare an item from a set of groups\n * @param {String} itemId Item Id to unshare from groups\n * @param {Array} groups Array of group id's from which the item will be unshared\n * @param {String} owner optional Owner username to determine which endpoint to hit\n * @param {IRequestOptions} requestOptions\n */\nexport function unshareItemFromGroups(itemId, groups, requestOptions, owner) {\n return Promise.all(groups.map(function (groupId) {\n var opt = Object.assign({}, { id: itemId, groupId: groupId }, requestOptions);\n if (owner) {\n opt.owner = owner;\n }\n return unshareItemWithGroup(opt);\n }));\n}\n//# sourceMappingURL=unshare-item-from-groups.js.map","import { searchItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Check if a site/page exists with a specific name\n */\nexport function doesItemExistWithTitle(itemTitle, options, authMgr) {\n // if options have multiple properties, put them into one string separated with 'AND'\n var optionsQuery = Object.keys(options)\n .map(function (key) {\n return key + \":\\\"\" + options[key] + \"\\\"\";\n })\n .join(\" AND \");\n var opts = {\n q: \"title:\\\"\" + itemTitle + \"\\\" AND \" + optionsQuery,\n authentication: authMgr\n };\n return searchItems(opts)\n .then(function (searchResponse) { return searchResponse.results.length > 0; })\n .catch(function (e) {\n throw Error(\"Error in doesItemExistWithTitle \" + e);\n });\n}\n//# sourceMappingURL=does-item-exist-with-title.js.map","import { doesItemExistWithTitle } from \"./does-item-exist-with-title\";\n/**\n * Given a title, construct a site/page title that is unique\n * if that title exists, this fn will add a number on the end, and increment until\n * an available title is found\n * @param {string} title site/page title to ensure if unique\n * @param {object} options an object that can be passed in to the q, eg. typekeywords, type\n * @param {object} authMgr auth info tells the function what url to use for the \"root\" of the API,\n * if missing, it will search against PROD\n * @param {number} step Number to increment. Defaults to 0\n */\nexport function getUniqueItemTitle(title, options, authMgr, step) {\n if (step === void 0) { step = 0; }\n var combinedName = title;\n if (step) {\n combinedName = title + \" \" + step;\n }\n return doesItemExistWithTitle(combinedName, options, authMgr)\n .then(function (result) {\n if (result) {\n step++;\n return getUniqueItemTitle(title, options, authMgr, step);\n }\n else {\n return combinedName;\n }\n })\n .catch(function (e) {\n throw Error(\"Error in getUniqueItemTitle \" + e);\n });\n}\n//# sourceMappingURL=get-unique-item-title.js.map","import { __assign, __spreadArrays } from \"tslib\";\nimport { batch } from \"../utils/batch\";\nvar MAX_NUM = 100;\n/**\n * Fetches all the pages in a search request\n * @param {SearchFunction} searchFunc\n * @param {ISearchOptions} opts\n * @param {number} limit\n * @param {batchSize} number of concurrent requests at a time\n * @returns {Promise<SearchableType[]>}\n */\nexport function fetchAllPages(searchFunc, opts, limit, batchSize) {\n if (limit === void 0) { limit = -1; }\n var pageSize = opts.num || MAX_NUM;\n var firstStart = opts.start || 1;\n // If a limit is provided, we don't have to use the first request to get the\n // total count before sending things off to batch(). So instead we fake the first\n // response just to set things up.\n var promise = limit === -1\n ? searchFunc(__assign(__assign({}, opts), { num: pageSize, start: firstStart }))\n : Promise.resolve({\n nextStart: firstStart,\n total: limit,\n results: [],\n num: pageSize\n });\n return promise\n .then(function (firstResponse) {\n // no more requests needed, return the first response\n if (firstResponse.nextStart === -1)\n return [firstResponse];\n // generate batch requests for the remaining pages to fetch\n var starts = [];\n for (var i = firstResponse.nextStart; i <= firstResponse.total; i += pageSize) {\n starts.push(i);\n }\n var batchSearchFunc = function (start) {\n return searchFunc(__assign(__assign({}, opts), { start: start, num: pageSize }));\n };\n return batch(starts, batchSearchFunc, batchSize).then(function (responses) { return __spreadArrays([\n firstResponse\n ], responses); });\n })\n .then(function (responses) {\n // merge all the search results into a single array\n var results = responses.reduce(function (acc, response) { return __spreadArrays(acc, response.results); }, []);\n // discard results beyond the limit if applicable\n var clipLimit = limit === -1 ? results.length : limit;\n return results.slice(0, clipLimit);\n });\n}\n//# sourceMappingURL=fetch-all-pages.js.map","/**\n * Add a token to the resource request if the request is to the portal\n * @param {string} url Resource Url\n * @param {IRequestOptions} requestOptions\n * @private\n */\nexport function _addTokenToResourceUrl(url, requestOptions) {\n var result = url;\n if (url.indexOf(\"token\") === -1) {\n // no token\n // Note: authentication.portal is a fully org url\n // i.e. https://dcdev.maps.arcgis.com/sharing/rest\n // this may need to be smarter to handle non-public solutions\n // shared across orgs\n if (url.indexOf(requestOptions.authentication.portal) > -1) {\n // is the portal\n result = url + \"?token=\" + requestOptions.authentication.token;\n }\n }\n return result;\n}\n//# sourceMappingURL=_add-token-to-resource-url.js.map","import { getPortalApiUrl } from \"../urls\";\n/**\n * Convert the resources array on an individual template in a solution\n * into an assets array that can be used to upload the resources to\n * the newly created item.\n * @param {object} template Template from a Solution\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function convertSolutionTemplateResourcesToAssets(template, hubRequestOptions) {\n var assets = [];\n if (template.resources && template.bundleItemId) {\n var portalRestUrl = getPortalApiUrl(hubRequestOptions.portalSelf);\n // the resources are stored on the solution item, and that Id is attached\n // into the template as .bundleItemId\n var solutionItemUrl_1 = portalRestUrl + \"/content/items/\" + template.bundleItemId;\n // the resources on the solution are prefixed with the item id of the item the\n // template was created from, which is stored as .itemId\n var prefix_1 = template.itemId;\n // map over the resources and convert them into assets\n assets = template.resources.map(function (name) {\n // we fetch the resource from .url property\n // and we upload it using the .name property\n return {\n name: name,\n type: \"resource\",\n url: solutionItemUrl_1 + \"/resources/\" + prefix_1 + \"-\" + name\n };\n });\n }\n return assets;\n}\n//# sourceMappingURL=convert-solution-template-resources-to-assets.js.map","/**\n * Given a url to an image, return it as a blob\n * @param {String} url Url to fetch the image from. Must have token if it's a non-publi item resource url\n * @param {Object} options additional optinos\n */\nexport function fetchImageAsBlob(url, options) {\n if (options === void 0) { options = {}; }\n if (!options.credentials) {\n options.credentials = \"same-origin\";\n }\n // We use fetch intentionally as the url may or may not be for an item url, so we don't\n // want this to run thru the main request logic\n return fetch(url, options).then(function (response) {\n return response.blob();\n });\n}\n//# sourceMappingURL=fetch-image-as-blob.js.map","import { addItemResource } from \"@esri/arcgis-rest-portal\";\nimport { fetchImageAsBlob } from \"./fetch-image-as-blob\";\n/**\n * Fetch image from a url, and upload as a resource\n * @param {Object} options {id, owner, fileName, url, authentication}\n */\nexport function fetchAndUploadResource(options) {\n // first fetch it as a blob...\n return fetchImageAsBlob(options.url).then(function (file) {\n // upload it to the item...\n return addItemResource({\n id: options.id,\n owner: options.owner,\n name: options.fileName,\n resource: file,\n authentication: options.authentication\n });\n });\n}\n//# sourceMappingURL=fetch-and-upload-resource.js.map","import { fetchImageAsBlob } from \"./fetch-image-as-blob\";\nimport { updateItem } from \"@esri/arcgis-rest-portal\";\n/**\n * Fetch image from a url, then upload to an item as it's thumbnail\n * @param {object} options\n */\nexport function fetchAndUploadThumbnail(options) {\n // first fetch it as a blob...\n return fetchImageAsBlob(options.url)\n .then(function (file) {\n return updateItem({\n item: {\n id: options.id,\n owner: options.owner\n },\n params: {\n fileName: options.fileName,\n thumbnail: file\n },\n authentication: options.authentication\n }).catch(function (_) {\n // resolve b/c this is not crtical\n return Promise.resolve();\n });\n })\n .catch(function (_) {\n return Promise.resolve();\n });\n}\n//# sourceMappingURL=fetch-and-upload-thumbnail.js.map","import { getItemApiUrl } from \"../urls/get-item-api-url\";\n/**\n * Get the fully qualified URL for an item's thumbnail\n * @param item w/ id, thumbnail, and access\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @param optionsOrToken options including width and/or token for the current user's session; will only be appended as a query parameter if the item's access is **not** `public`\n * @returns URL to the item's thumbnail, defaults to `https://www.arcgis.com/sharing/rest/content/items/{item.id}/info/{item.thumbnail}`. Returns `null` if the item does not have a thumbnail assigned.\n */\nexport function getItemThumbnailUrl(item, portalUrlOrObject, optionsOrToken) {\n if (!item || !item.thumbnail) {\n // TODO: handle image types by returning the image (item data) itself?\n return null;\n }\n // tslint:disable-next-line prefer-const\n var _a = optionsOrToken || {}, token = _a.token, width = _a.width;\n // TODO: at the next breaking change drop support for passing token as string\n if (!token && typeof optionsOrToken === \"string\") {\n token = optionsOrToken;\n }\n var itemApiUrl = getItemApiUrl(item, portalUrlOrObject, token);\n var _b = itemApiUrl.split(\"?\"), baseUrl = _b[0], search = _b[1];\n var searchParams = new URLSearchParams(search);\n searchParams.delete(\"f\");\n if (width) {\n searchParams.append(\"w\", width + \"\");\n }\n var newSearch = searchParams.toString();\n var url = baseUrl + \"/info/\" + item.thumbnail;\n return newSearch ? url + \"?\" + newSearch : url;\n}\n//# sourceMappingURL=get-item-thumbnail-url.js.map","import { getPortalApiUrl } from \"../urls\";\nimport { getItemThumbnailUrl } from \"./get-item-thumbnail-url\";\nimport { getItemResources } from \"@esri/arcgis-rest-portal\";\n/**\n * Given an item, return an array of assets that includes\n * all the resources, as well as the thumbnail\n * @param {object} item Item\n * @param {IHubRequestOptions} IHubRequestOptions\n */\nexport function getItemAssets(item, hubRequestOptions) {\n var portalRestUrl = getPortalApiUrl(hubRequestOptions.portalSelf);\n var itemUrl = portalRestUrl + \"/content/items/\" + item.id;\n // if construct the asset for the thumbnail\n var thumbnailUrl = getItemThumbnailUrl(item, hubRequestOptions);\n var assets = [];\n if (thumbnailUrl) {\n assets.push({\n name: item.thumbnail,\n url: thumbnailUrl,\n type: \"thumbnail\"\n });\n }\n // get all the other resources\n // TODO: see how this works w/ folders\n return getItemResources(item.id, hubRequestOptions).then(function (response) {\n var resourceAssets = response.resources.map(function (e) {\n return {\n name: e.resource,\n type: \"resource\",\n url: itemUrl + \"/resources/\" + e.resource\n };\n });\n return assets.concat(resourceAssets);\n });\n}\n//# sourceMappingURL=get-item-assets.js.map","/**\n * Given a string, return it as a blob\n * NOTE: USE objectToJsonBlob if you're saving a JSON resource!!!\n * NOTE: This is not currently supported in Node\n * @param {string} the string\n */\nexport function stringToBlob(s, type) {\n if (type === void 0) { type = \"application/octet-stream\"; }\n /* istanbul ignore next */\n if (typeof Blob !== \"undefined\") {\n var bytes = [];\n for (var i = 0; i < s.length; i++) {\n bytes[i] = s.charCodeAt(i);\n }\n var encoded = new Uint8Array(bytes);\n return new Blob([encoded], { type: type });\n }\n else {\n throw new Error(\"stringToBlob is not currently supported on Node\");\n }\n}\n//# sourceMappingURL=string-to-blob.js.map","import { fetchAndUploadResource } from \"./fetch-and-upload-resource\";\nimport { fetchAndUploadThumbnail } from \"./fetch-and-upload-thumbnail\";\nimport { _addTokenToResourceUrl } from \"./_add-token-to-resource-url\";\n/**\n * Given an Item and an array of resources, upload them\n * @param {Object} itemModel Item add the resource to\n * @param {Array} resources Array of resources, with urls, to upload to the item\n * @param {Object} requestOptions {authentication}\n */\nexport function uploadResourcesFromUrl(itemModel, resources, requestOptions) {\n if (Array.isArray(resources)) {\n var resourcePromises = resources.reduce(function (acc, resource) {\n if (resource.url) {\n var opts = {\n id: itemModel.item.id,\n owner: itemModel.item.owner,\n fileName: resource.name,\n url: _addTokenToResourceUrl(resource.url, requestOptions),\n authentication: requestOptions.authentication\n };\n if (resource.type === \"thumbnail\") {\n acc.push(fetchAndUploadThumbnail(opts));\n }\n else {\n // treat as a resource\n acc.push(fetchAndUploadResource(opts));\n }\n }\n return acc;\n }, []);\n // Let them resolve...\n return Promise.all(resourcePromises);\n }\n else {\n return Promise.resolve([]);\n }\n}\n//# sourceMappingURL=upload-resources-from-url.js.map","import { getPortalApiUrl } from \"../urls\";\n/**\n * Add a url property to the entries in the assets hash\n * @param {IModelTemplate} template\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function addSolutionResourceUrlToAssets(template, hubRequestOptions) {\n /* istanbul ignore next */\n var assets = template.assets || template.resources || [];\n if (template.bundleItemId) {\n var portalRestUrl = getPortalApiUrl(hubRequestOptions.portalSelf);\n // the resources are stored on the solution item, and that Id is attached\n // into the template as .bundleItemId\n var solutionItemUrl_1 = portalRestUrl + \"/content/items/\" + template.bundleItemId;\n // the resources on the solution are prefixed with the item id of the item the\n // template was created from, which is stored as .itemId\n var prefix_1 = template.itemId;\n // map over the resources and convert them into assets\n assets = assets.map(function (asset) {\n // we fetch the resource from .url property\n // and we upload it using the .name property\n return {\n name: asset.name,\n type: asset.type || \"resource\",\n url: solutionItemUrl_1 + \"/resources/\" + prefix_1 + \"-\" + asset.name\n };\n });\n }\n return assets;\n}\n//# sourceMappingURL=add-solution-resource-url-to-assets.js.map","/**\n * Convert an object to a Blob with type 'application/json'\n * @param {*} obj\n * @returns Blob\n */\nexport function objectToJsonBlob(obj) {\n /* istanbul ignore next */\n if (typeof Blob !== \"undefined\") {\n return new Blob([JSON.stringify(obj)], { type: \"application/json\" });\n }\n else {\n throw new Error(\"objectToJsonBlob is not currently supported on Node\");\n }\n}\n//# sourceMappingURL=object-to-json-blob.js.map","import { __assign } from \"tslib\";\nimport { hubApiRequest } from \"..\";\n/**\n * Search the Hub API\n *\n * @param requestOptions\n * @returns JSONAPI response\n */\nexport function hubApiSearch(requestOptions) {\n // derive default headers if authentication\n var authentication = requestOptions.authentication;\n var headers = authentication &&\n authentication.serialize && { authentication: authentication.serialize() };\n var defaults = {\n headers: headers,\n httpMethod: \"POST\",\n };\n return hubApiRequest(\"/search\", __assign(__assign({}, defaults), requestOptions));\n}\n//# sourceMappingURL=hub-api-search.js.map","/* Copyright (c) 2018-2021 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __spreadArrays } from \"tslib\";\nimport { UserSession } from \"@esri/arcgis-rest-auth\";\nimport { cloneObject, unique } from \"../util\";\n/**\n * Well known APIs\n * Short-forms for specifying common APIs\n * We will likely deprecate this\n */\nexport var SEARCH_APIS = {\n arcgis: {\n label: \"ArcGIS Online\",\n url: \"https://www.arcgis.com\",\n type: \"arcgis\",\n },\n arcgisQA: {\n label: \"ArcGIS Online QAEXT\",\n url: \"https://qaext.arcgis.com\",\n type: \"arcgis\",\n },\n arcgisDEV: {\n label: \"ArcGIS Online DEVEXT\",\n url: \"https://devext.arcgis.com\",\n type: \"arcgis\",\n },\n hub: {\n label: \"ArcGIS Hub\",\n url: \"https://hub.arcgis.com/api\",\n type: \"arcgis-hub\",\n },\n hubDEV: {\n label: \"ArcGIS Hub DEV\",\n url: \"https://hubdev.arcgis.com/api\",\n type: \"arcgis-hub\",\n },\n hubQA: {\n label: \"ArcGIS Hub QA\",\n url: \"https://hubqa.arcgis.com/api\",\n type: \"arcgis-hub\",\n },\n};\n/**\n * @private\n * Convert array of api \"names\" into full ApiDefinitions\n * @param apis\n * @returns\n */\nexport function expandApis(apis) {\n return apis.map(expandApi);\n}\n/**\n * @private\n * Convert an api \"name\" into a full ApiDefinition\n * @param api\n * @returns\n */\nexport function expandApi(api) {\n if (typeof api === \"string\" && api in SEARCH_APIS) {\n return SEARCH_APIS[api];\n }\n else {\n // it's an object, so we trust that it's well formed\n return api;\n }\n}\n/**\n * @private\n * Merge two date ranges by taking the longest span\n * @param dr1\n * @param dr2\n * @returns\n */\nexport function mergeDateRange(dr1, dr2) {\n var result = cloneObject(dr1);\n // feels like there is a more concise way to do this...\n if (dr2.from < dr1.from) {\n result.from = dr2.from;\n }\n if (dr2.to > dr1.to) {\n result.to = dr2.to;\n }\n return result;\n}\n/**\n * @private\n * Merge two [`MatchOptions`](../MatchOptions)\n *\n * Currently a naieve implementation where the arrays are simply merged\n *\n * @param mo1\n * @param mo2\n * @returns\n */\nexport function mergeMatchOptions(mo1, mo2) {\n var result = {};\n // None of these props are required, so we can't just\n // use Object.keys/.entries\n var props = [\"any\", \"all\", \"not\", \"exact\"];\n props.forEach(function (prop) {\n var key = prop;\n var merged = __spreadArrays(getMatchValue(mo1, key), getMatchValue(mo2, key));\n if (merged.length) {\n // remove any dupes and set on the return\n result[key] = merged.filter(unique);\n }\n });\n return result;\n}\n/**\n * Get the value of a property on an IMatchOptions\n *\n * This is complex b/c all the props are optional, and\n * they could be a simple string, or an array of strings.\n *\n * This function normalizes all that and returns an array,\n * which may or may not be empty\n * @param option\n * @param key\n * @returns\n */\nfunction getMatchValue(option, key) {\n var matchValue = [];\n if (option[key]) {\n var val = option[key];\n if (Array.isArray(val)) {\n matchValue = val;\n }\n else {\n matchValue = [val];\n }\n }\n return matchValue;\n}\n/**\n * @private\n * Convert a field value into a MatchOptions if it's not already one\n * @param value\n * @returns\n */\nexport function valueToMatchOptions(value) {\n var result = {};\n if (Array.isArray(value)) {\n result = {\n any: value,\n };\n }\n else {\n if (typeof value === \"string\") {\n result = {\n any: [value],\n };\n }\n if (typeof value === \"object\") {\n result = value;\n }\n }\n return result;\n}\n/**\n * @private\n * Convert a RelativeDate to a DateRange<number>\n * @param relative\n * @returns\n */\nexport function relativeDateToDateRange(relative) {\n // hash of offsets\n var offsetMs = {\n min: 1000 * 60,\n hours: 1000 * 60 * 60,\n days: 1000 * 60 * 60 * 24,\n weeks: 1000 * 60 * 60 * 24 * 7,\n };\n var now = new Date();\n // default\n var result = {\n type: \"date-range\",\n from: now.getTime(),\n to: now.getTime(),\n };\n //\n switch (relative.unit) {\n case \"hours\":\n case \"days\":\n case \"weeks\":\n result.from = result.to - offsetMs[relative.unit] * relative.num;\n break;\n case \"months\":\n // get the current month and subtract num\n now.setMonth(now.getMonth() - relative.num);\n result.from = now.getTime();\n break;\n case \"years\":\n now.setFullYear(now.getFullYear() - relative.num);\n result.from = now.getTime();\n break;\n }\n return result;\n}\n/**\n * @private\n * As a final `ISearchOptions` object gets created, many such objects are created, and\n * need to be systematically \"merged\" so as to return consistently structured `q` and `filter`\n * values.\n * @param so1\n * @param so2\n * @param join\n * @returns\n */\nexport function mergeSearchOptions(so1, so2, join) {\n var result = cloneObject(so1);\n var q = so2.q, filter = so2.filter;\n if (q) {\n result.q = (result.q ? \" (\" + result.q + \" \" + join + \" \" + q + \")\" : q).trim();\n }\n if (filter) {\n result.filter = (result.filter ? \"(\" + result.filter + \" \" + join + \" \" + filter + \")\" : filter).trim();\n }\n return result;\n}\n/**\n * @private\n * Serialize a `MatchOptions` into `q` or `filter` on an `ISearchOptions`\n * @param key\n * @param opts\n * @returns\n */\nexport function serializeMatchOptions(key, opts) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n if (opts.exact) {\n // defined separately for refactoring later\n var userFilterableFields = [\n \"username\",\n \"firstname\",\n \"lastname\",\n \"fullname\",\n \"email\",\n ];\n var itemFilterableFields = [\n \"title\",\n \"tags\",\n \"typekeywords\",\n \"type\",\n \"name\",\n \"owner\",\n ];\n var groupFilterableFields = [\"title\", \"typekeywords\", \"owner\"];\n var filterableFields = __spreadArrays(userFilterableFields, itemFilterableFields, groupFilterableFields);\n if (filterableFields.includes(key)) {\n result.filter = serializeStringOrArray(\"AND\", key, opts.exact);\n }\n else {\n // Treat it the same as .all\n if (typeof opts.exact === \"string\") {\n if (!opts.all) {\n opts.all = [];\n }\n if (typeof opts.all === \"string\") {\n opts.all = [opts.all];\n }\n opts.all.push(opts.exact);\n }\n if (Array.isArray(opts.exact)) {\n if (!opts.all) {\n opts.all = [];\n }\n if (typeof opts.all === \"string\") {\n opts.all = [opts.all];\n }\n opts.all = opts.all.concat(opts.exact);\n }\n }\n }\n // Handle the other props\n if (opts.any) {\n result.q = serializeStringOrArray(\"OR\", key, opts.any);\n }\n if (opts.all) {\n result.q =\n (result.q ? result.q + \" AND \" : \"\") +\n serializeStringOrArray(\"AND\", key, opts.all);\n }\n if (opts.not) {\n // negate the entries if they are not\n result.q =\n (result.q ? result.q + \" AND \" : \"\") +\n serializeStringOrArray(\"OR\", \"-\" + key, opts.not);\n }\n return result;\n}\n/**\n * @private\n * Serialize a DateRange<number> into a Portal Query string\n * @param key\n * @param range\n * @returns\n */\nexport function serializeDateRange(key, range) {\n return {\n q: key + \":[\" + range.from + \" TO \" + range.to + \"]\",\n filter: \"\",\n };\n}\n/**\n * @private\n * Serialize a `string` or `string[]` into a string\n * @param join\n * @param key\n * @param value\n * @returns\n */\nexport function serializeStringOrArray(join, key, value) {\n var q = \"\";\n if (Array.isArray(value)) {\n q = \"(\" + key + \":\\\"\" + value.join(\"\\\" \" + join + \" \" + key + \":\\\"\") + \"\\\")\";\n }\n else {\n q = key + \":\\\"\" + value + \"\\\"\";\n }\n return q;\n}\n/**\n * Create a `.next()` function for a type\n * @param request\n * @param nextStart\n * @param total\n * @param fn\n * @returns\n */\nexport function getNextFunction(request, nextStart, total, fn) {\n var clonedRequest = cloneObject(request);\n // clone will not handle authentication so we do it manually\n if (request.authentication) {\n clonedRequest.authentication = UserSession.deserialize(request.authentication.serialize());\n }\n // figure out the start\n clonedRequest.start = nextStart > -1 ? nextStart : total + 1;\n return function (authentication) {\n if (authentication) {\n clonedRequest.authentication = authentication;\n }\n return fn(clonedRequest);\n };\n}\n/**\n * Construct a the full url to a group thumbnail\n *\n * - If the group has a thumbnail, construct the full url\n * - If the group is not public, append on the token\n * @param portalUrl\n * @param group\n * @param token\n * @returns\n */\nexport function getGroupThumbnailUrl(portalUrl, group, token) {\n var thumbnailUrl = null;\n if (group.thumbnail) {\n thumbnailUrl = portalUrl + \"/community/groups/\" + group.id + \"/info/\" + group.thumbnail;\n if (token && group.access !== \"public\") {\n thumbnailUrl = thumbnailUrl + \"?token=\" + token;\n }\n }\n return thumbnailUrl;\n}\n/**\n * Construct a the full url to a user thumbnail\n *\n * - If the user has a thumbnail, construct the full url\n * - If the user is not public, append on the token\n * @param portalUrl\n * @param user\n * @param token\n * @returns\n */\nexport function getUserThumbnailUrl(portalUrl, user, token) {\n var thumbnailUrl = null;\n if (user.thumbnail) {\n thumbnailUrl = portalUrl + \"/community/users/\" + user.username + \"/info/\" + user.thumbnail;\n if (token && user.access !== \"public\") {\n thumbnailUrl = thumbnailUrl + \"?token=\" + token;\n }\n }\n return thumbnailUrl;\n}\n//# sourceMappingURL=utils.js.map","import { __spreadArrays } from \"tslib\";\nimport { cloneObject } from \"..\";\nimport { mergeDateRange, mergeMatchOptions, mergeSearchOptions, relativeDateToDateRange, serializeDateRange, serializeMatchOptions, valueToMatchOptions, } from \"./utils\";\n// TODO: Implement $dataset\nvar ContentFilterExpansions = {\n $apps: [\n {\n type: {\n any: [\n \"Code Sample\",\n \"Web Mapping Application\",\n \"Mobile Application\",\n \"Application\",\n \"Desktop Application Template\",\n \"Desktop Application\",\n \"Operation View\",\n \"Dashboard\",\n \"Operations Dashboard Extension\",\n \"Workforce Project\",\n \"Insights Workbook\",\n \"Insights Page\",\n \"Insights Model\",\n \"Hub Page\",\n \"Hub Initiative\",\n \"Hub Site Application\",\n \"StoryMap\",\n \"Web Experience\",\n \"Web Experience Template\",\n \"Form\",\n ],\n not: [\n \"Code Attachment\",\n \"Featured Items\",\n \"Symbol Set\",\n \"Color Set\",\n \"Windows Viewer Add In\",\n \"Windows Viewer Configuration\",\n \"Map Area\",\n \"Indoors Map Configuration\",\n ],\n },\n typekeywords: {\n not: [\"MapAreaPackage\", \"SMX\"],\n },\n },\n ],\n $storymap: [\n {\n type: \"StoryMap\",\n },\n {\n type: \"Web Mapping Application\",\n typekeywords: [\"Story Map\"],\n },\n ],\n $dashboard: [\n {\n type: \"Dashboard\",\n typekeywords: {\n any: [\"Dashboard\"],\n not: [\"ArcGIS Operation View\", \"Add In\", \"Extension\"],\n },\n },\n ],\n $dataset: [],\n $experience: [\n {\n type: {\n any: [\"Web Experience\"],\n not: [\"Web Experience Template\"],\n },\n },\n ],\n $site: [\n {\n type: [\"Hub Site Application\", \"Site Application\"],\n },\n {\n type: [\"Web Mapping Application\"],\n typekeywords: [\"hubSite\"],\n },\n ],\n $initiative: [\n {\n type: {\n any: \"Hub Initiative\",\n not: \"Hub Initiative Template\",\n },\n },\n ],\n $document: [\n {\n typekeywords: {\n any: \"Document\",\n not: [\"MapAreaPackage\", \"SMX\"],\n },\n type: {\n any: [\n \"Image\",\n \"Layout\",\n \"Desktop Style\",\n \"Project Template\",\n \"Report Template\",\n \"Pro Report\",\n \"Statistical Data Collection\",\n \"360 VR Experience\",\n \"netCDF\",\n \"PDF\",\n \"CSV\",\n \"Administrative Report\",\n \"Raster function template\",\n ],\n not: [\n \"Image Service\",\n \"Explorer Document\",\n \"Explorer Map\",\n \"Globe Document\",\n \"Scene Document\",\n \"Code Attachment\",\n \"Featured Items\",\n \"Symbol Set\",\n \"ColorSet\",\n \"Windows Viewer Add In\",\n \"Windows Viewer Configuration\",\n \"Map Area\",\n \"Indoors Map Configuration\",\n ],\n },\n },\n ],\n};\n/**\n * @private\n * Convert portal search response to items\n * @param response\n * @returns\n */\nexport function convertPortalResponseToFacets(response) {\n var _a;\n var result = [];\n if ((_a = response.aggregations) === null || _a === void 0 ? void 0 : _a.counts) {\n response.aggregations.counts.forEach(function (entry) {\n var facet = {\n label: entry.fieldName,\n attribute: entry.fieldName,\n type: \"multi-select\",\n };\n var options = [];\n entry.fieldValues.forEach(function (fv) {\n var filter = {\n filterType: \"content\",\n };\n filter[entry.fieldName] = fv.value;\n var fo = {\n label: fv.value,\n value: fv.value,\n count: fv.count,\n selected: false,\n filter: filter,\n };\n options.push(fo);\n });\n facet.options = options;\n result.push(facet);\n });\n }\n return result;\n}\n/**\n * Merge `Filter<\"content\">` objects\n *\n * Useful in components which may get partial filters from a variety of\n * sub-components, which are then combined into a single filter prior\n * to executing the search.\n * @param filters\n * @returns\n */\nexport function mergeContentFilter(filters) {\n // expand all the filters so all prop types are consistent\n var expanded = filters.map(expandContentFilter);\n // now we can merge based on fields\n var dateFields = [\"created\", \"modified\"];\n var specialFields = __spreadArrays([\"filterType\", \"subFilters\", \"term\"], dateFields);\n var result = expanded.reduce(function (acc, entry) {\n // process fields\n Object.entries(entry).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n if (acc.hasOwnProperty(key)) {\n /* istanbul ignore else */\n if (!specialFields.includes(key)) {\n acc[key] = mergeMatchOptions(acc[key], value);\n }\n else if (dateFields.includes(key)) {\n acc[key] = mergeDateRange(acc[key], value);\n }\n else if (key === \"term\") {\n acc[key] = acc[key] + \" \" + value;\n }\n else if (key === \"subFilters\") {\n acc[key] = mergeSubFilters(acc[key], value);\n }\n }\n else {\n acc[key] = cloneObject(value);\n }\n });\n return acc;\n }, {});\n result.filterType = \"content\";\n return result;\n}\nfunction mergeSubFilters(sf1, sf2) {\n // Simplistic implementation: we just merge the arrays\n // in the future we may try to de-dupe things as a safeguard\n return __spreadArrays(sf1, sf2);\n}\n/**\n * Prior to serialization into the query syntax for the backing APIs, we first expand [Filters](../Filter)\n *\n * Filter's can express their intent in a very terse form, but to ensure consistent structures\n * we expand them into their more verbose form.\n *\n * i.e. `title: \"Water\"` expands into `title: { any: [\"Water\"]}`\n *\n * - \"well known\" type values are expanded\n * - i.e. `type: \"$storymap\"` expands into two `subFilter` entries\n * - Fields defined as `string | string[] | MatchOptions` will be converted to a `MatchOptions`\n * - RelativeDate fields are converted to DateRange<number>\n *\n * @param filter\n * @returns\n */\nexport function expandContentFilter(filter) {\n // Expand filter.type first\n var expandedTypeFilter = expandTypeField(filter);\n // Expand subfilters\n // Guard - JS Clients could send in anything...\n if (Array.isArray(filter.subFilters)) {\n // Convert any strings into the coresponding ContentFilterDefinition\n expandedTypeFilter.subFilters = expandedTypeFilter.subFilters.reduce(function (acc, entry) {\n if (typeof entry === \"string\") {\n // if the entry is not a key of ContentFilterExpansions\n // we just skip over it\n if (ContentFilterExpansions[entry]) {\n acc = acc.concat(ContentFilterExpansions[entry]);\n }\n }\n else {\n acc.push(entry); // should be a ContentFilterDefinition\n }\n return acc;\n }, []);\n }\n // Convert all props into MatchOptions/DateRanges\n return convertContentDefinitionToFilter(expandedTypeFilter);\n}\n/**\n * @private\n * Expand from a well-known \"type\" into it's longer form\n *\n * i.e. `type: \"$storymap\"` expands into two subFilters entries\n *\n * @param filter\n * @returns\n */\nexport function expandTypeField(filter) {\n var clone = cloneObject(filter);\n // ensure subFilters is defined as an array\n clone.subFilters = clone.subFilters || [];\n if (clone.type) {\n // if .type is an Array...\n if (Array.isArray(clone.type)) {\n // remove any well-known-keys and move their expansions into subfilters\n clone.type = clone.type.reduce(function (acc, entry) {\n if (isWellKnownType(entry)) {\n // working with dynamic objects in typescript requires some assertions\n var key = entry;\n clone.subFilters = clone.subFilters.concat(lookupTypeFilters(key));\n }\n else {\n acc.push(entry);\n }\n return acc;\n }, []);\n }\n else if (isWellKnownType(clone.type)) {\n var key = clone.type;\n clone.subFilters = clone.subFilters.concat(lookupTypeFilters(key));\n delete clone.type;\n }\n else {\n // Future?: implement \"expansions\" inside MatchOptions\n // For now, we only attempt expansions for filter.type\n // if it's a string, or for strings inside an array\n // Unclear if it's of value to allow short-cuts inside MatchOptions\n }\n }\n return clone;\n}\n/**\n * Is the argument a well-known type \"key\"\n *\n * Accepts `string`, `string[]` or `IMatchOptions`\n * but only string values can possibly be properties\n * on `ContentFilterExpansions`\n * @param key\n * @returns\n */\nfunction isWellKnownType(key) {\n var result = false;\n if (typeof key === \"string\") {\n result = key in ContentFilterExpansions;\n }\n return result;\n}\nfunction lookupTypeFilters(key) {\n return ContentFilterExpansions[key];\n}\n/**\n * @private\n * Convert a `ContentFilterDefinition` to a `ContentFilter`\n *\n * ContentFilter is a narrower version of ContentFilterDefinition, without\n * the union types. Using a ContentFilter makes working with the structure\n * in typescript much easier.\n *\n * @param filter\n * @returns\n */\nexport function convertContentDefinitionToFilter(filter) {\n var result = {};\n if (filter.term) {\n result.term = filter.term;\n }\n var dateProps = [\"created\", \"modified\"];\n // Some properties should not get converted to MatchOptions\n var specialProps = __spreadArrays([\"filterType\", \"subFilters\", \"term\"], dateProps);\n // Do the conversion\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n if (!specialProps.includes(key)) {\n result[key] = valueToMatchOptions(value);\n }\n });\n // Special Cases\n // subFilters; Array of ContentFilterDefinitions\n if (filter.subFilters && Array.isArray(filter.subFilters)) {\n // downcast - would be nice to skip this or use some other constuct\n var sf = filter.subFilters;\n result.subFilters = sf.map(convertContentDefinitionToFilter);\n }\n // Dates; Ensure they are all DateRange<number>\n dateProps.forEach(function (fld) {\n if (filter[fld]) {\n if (filter[fld].type === \"relative-date\") {\n result[fld] = relativeDateToDateRange(filter[fld]);\n }\n else {\n result[fld] = cloneObject(filter[fld]);\n }\n }\n });\n return result;\n}\n/**\n * @private\n * Serialize a `ContentFilter` into an `ISearchOptions` for use with `searchItems`\n * @param filter\n * @returns\n */\nexport function serializeContentFilterForPortal(filter) {\n var searchOptions = convertContentFilterToSearchOptions(filter);\n if (filter.subFilters) {\n var subFilterOptions = filter.subFilters.reduce(function (acc, entry) {\n // Next guard is present b/c this can be used from javascript\n // but our tests are written in typescript which prevents us\n // from hitting the else\n /* istanbul ignore else */\n if (typeof entry === \"object\") {\n acc = mergeSearchOptions(acc, convertContentFilterToSearchOptions(entry), \"OR\");\n }\n return acc;\n }, { q: \"\", filter: \"\" });\n // merge with searchOptions using AND\n searchOptions = mergeSearchOptions(searchOptions, subFilterOptions, \"AND\");\n }\n // term is always last, and pre-pended on searchOptions.q\n if (filter.term) {\n searchOptions.q = (filter.term + \" \" + searchOptions.q).trim();\n }\n return searchOptions;\n}\n/**\n * @private\n * Convert a ContentFilter to a SearchOptions\n *\n * @param filter\n * @returns\n */\nexport function convertContentFilterToSearchOptions(filter) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n var dateProps = [\"created\", \"modified\"];\n var specialProps = __spreadArrays([\"filterType\", \"subFilters\", \"term\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // MatchOptions may go into either q or filter\n if (!specialProps.includes(key)) {\n result = mergeSearchOptions(result, serializeMatchOptions(key, value), \"AND\");\n }\n // Dates only go into q\n if (dateProps.includes(key)) {\n result = mergeSearchOptions(result, serializeDateRange(key, value), \"AND\");\n }\n });\n return result;\n}\n//# sourceMappingURL=content-utils.js.map","import { __spreadArrays } from \"tslib\";\nimport { mergeDateRange, mergeMatchOptions, mergeSearchOptions, relativeDateToDateRange, serializeDateRange, serializeMatchOptions, valueToMatchOptions, } from \".\";\nimport { cloneObject, getProp, setProp } from \"..\";\n/**\n *\n * Merge `Filter<\"group\">` objects\n *\n * Useful in components which may get partial filters from a variety of\n * sub-components, which are then combined into a single filter prior\n * to executing the search.\n * @param filters\n * @returns\n */\nexport function mergeGroupFilters(filters) {\n // expand all the filters so all prop types are consistent\n var expanded = filters.map(expandGroupFilter);\n // now we can merge based on fields\n var dateFields = [\"created\", \"modified\"];\n var specialFields = __spreadArrays([\"filterType\", \"term\"], dateFields);\n // acc is initialized as Filter<group> but also needs it\n // in the function signature... for reasons?!\n var result = expanded.reduce(function (acc, entry) {\n // process fields\n Object.entries(entry).forEach(function (_a) {\n // Note: getProp/setProp are used to get around\n // typescript issues with string indexing\n var key = _a[0], value = _a[1];\n if (acc.hasOwnProperty(key)) {\n var existingValue = getProp(acc, key);\n // if the key is not to a special field\n if (!specialFields.includes(key)) {\n // treat as an IMatchOptions\n setProp(key, mergeMatchOptions(existingValue, value), acc);\n }\n else if (dateFields.includes(key)) {\n // treat as IDateRange\n setProp(key, mergeDateRange(existingValue, value), acc);\n }\n else if (key === \"term\") {\n // append terms\n acc[key] = acc[key] + \" \" + value;\n }\n }\n else {\n // Acc does not have an entry for this yet\n // so just clone it\n setProp(key, cloneObject(value), acc);\n }\n });\n return acc;\n }, {\n filterType: \"group\",\n });\n return result;\n}\n/**\n * Prior to serialization into the query syntax for the backing APIs, we first expand [Filters](../Filter)\n *\n * Filter's can express their intent in a very terse form, but to ensure consistent structures\n * we expand them into their more verbose form.\n *\n * i.e. `title: \"Water\"` expands into `title: { any: [\"Water\"]}`\n *\n * - Fields defined as `string | string[] | MatchOptions` will be converted to a `MatchOptions`\n * - RelativeDate fields are converted to DateRange<number>\n *\n * @param filter\n * @returns\n */\nexport function expandGroupFilter(filter) {\n var result = {};\n var dateProps = [\"created\", \"modified\"];\n // Some properties should not get converted to MatchOptions\n var specialProps = __spreadArrays([\"term\", \"searchUserAccess\"], dateProps);\n // Do the conversion\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // handle Matchish fields\n if (!specialProps.includes(key)) {\n // setProp side-steps typescript complaining\n setProp(key, valueToMatchOptions(value), result);\n }\n // Handle date fields\n if (dateProps.includes(key)) {\n var dateFieldValue = cloneObject(getProp(filter, key));\n if (getProp(filter, key + \".type\") === \"relative-date\") {\n setProp(key, relativeDateToDateRange(dateFieldValue), result);\n }\n else {\n setProp(key, dateFieldValue, result);\n }\n }\n });\n // searchUserAccess is boolean, so we check if the prop exists\n // vs checking if the value is truthy\n if (filter.hasOwnProperty(\"searchUserAccess\")) {\n result.searchUserAccess = filter.searchUserAccess;\n }\n if (filter.term) {\n result.term = filter.term;\n }\n return result;\n}\n/**\n * @private\n * Serialize an `IGroupFilterDefinition` into an `ISearchOptions` for use\n * with `searchGroups`\n * @param filter\n * @returns\n */\nexport function serializeGroupFilterForPortal(filter) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n var dateProps = [\"created\", \"modified\"];\n var specialProps = __spreadArrays([\"term\", \"searchUserAccess\", \"filterType\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // MatchOptions fields\n if (!specialProps.includes(key)) {\n result = mergeSearchOptions(result, serializeMatchOptions(key, value), \"AND\");\n }\n // Dates only go into q\n if (dateProps.includes(key)) {\n result = mergeSearchOptions(result, serializeDateRange(key, value), \"AND\");\n }\n });\n // searchUserAccess is also a top-level property\n if (filter.hasOwnProperty(\"searchUserAccess\")) {\n result.searchUserAccess = filter.searchUserAccess;\n }\n // add the term\n if (filter.term) {\n result.q = (filter.term + \" \" + result.q).trim();\n }\n return result;\n}\n//# sourceMappingURL=group-utils.js.map","import { __spreadArrays } from \"tslib\";\nimport { cloneObject, getProp, mergeDateRange, mergeMatchOptions, mergeSearchOptions, relativeDateToDateRange, serializeDateRange, serializeMatchOptions, setProp, valueToMatchOptions, } from \"..\";\n/**\n *\n * Merge `Filter<\"user\">` objects\n *\n * Useful in components which may get partial filters from a variety of\n * sub-components, which are then combined into a single filter prior\n * to executing the search.\n * @param filters\n * @returns\n */\nexport function mergeUserFilters(filters) {\n // expand all the filters so all prop types are consistent\n var expanded = filters.map(expandUserFilter);\n // now we can merge based on fields\n var dateFields = [\"created\", \"modified\", \"lastlogin\"];\n var specialFields = __spreadArrays([\"disabled\", \"term\", \"filterType\"], dateFields);\n // acc is initialized as Filter<group> but also needs it\n // in the function signature... for reasons?!\n var result = expanded.reduce(function (acc, entry) {\n // process fields\n Object.entries(entry).forEach(function (_a) {\n // Note: getProp/setProp are used to get around\n // typescript issues with string indexing\n var key = _a[0], value = _a[1];\n if (acc.hasOwnProperty(key)) {\n var existingValue = getProp(acc, key);\n // if the key is not to a special field\n if (!specialFields.includes(key)) {\n // treat as an IMatchOptions\n setProp(key, mergeMatchOptions(existingValue, value), acc);\n }\n else if (dateFields.includes(key)) {\n // treat as IDateRange\n setProp(key, mergeDateRange(existingValue, value), acc);\n }\n else if (key === \"term\") {\n // append terms\n acc[key] = acc[key] + \" \" + value;\n }\n }\n else {\n // Acc does not have an entry for this yet\n // so just clone it\n setProp(key, cloneObject(value), acc);\n }\n });\n return acc;\n }, {\n filterType: \"user\",\n });\n return result;\n}\n/**\n * Prior to serialization into the query syntax for the backing APIs, we first expand [Filters](../Filter)\n *\n * Filter's can express their intent in a very terse form, but to ensure consistent structures\n * we expand them into their more verbose form.\n *\n * i.e. `firstname: \"John\"` expands into `firstname: { any: [\"John\"]}`\n *\n * - Fields defined as `string | string[] | MatchOptions` will be converted to a `MatchOptions`\n * - RelativeDate fields are converted to DateRange<number>\n * @param filter\n * @returns\n */\nexport function expandUserFilter(filter) {\n var result = {};\n var dateProps = [\"created\", \"modified\", \"lastlogin\"];\n var specialProps = __spreadArrays([\"disabled\", \"term\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // handle Matchish fields\n if (!specialProps.includes(key)) {\n // setProp side-steps typescript complaining\n setProp(key, valueToMatchOptions(value), result);\n }\n // Handle date fields\n if (dateProps.includes(key)) {\n var dateFieldValue = cloneObject(getProp(filter, key));\n if (getProp(filter, key + \".type\") === \"relative-date\") {\n setProp(key, relativeDateToDateRange(dateFieldValue), result);\n }\n else {\n setProp(key, dateFieldValue, result);\n }\n }\n });\n // disabled is boolean, so we check if the prop exists\n // vs checking if the value is truthy\n if (filter.hasOwnProperty(\"disabled\")) {\n result.disabled = filter.disabled;\n }\n if (filter.term) {\n result.term = filter.term;\n }\n return result;\n}\n/**\n * @private\n * Serialize an `IUserFilterDefinition` into an `ISearchOptions` for use\n * with `searchUsers`\n * @param filter\n * @returns\n */\nexport function serializeUserFilterForPortal(filter) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n var dateProps = [\"created\", \"modified\", \"lastlogin\"];\n var specialProps = __spreadArrays([\"term\", \"filterType\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // MatchOptions fields\n if (!specialProps.includes(key)) {\n result = mergeSearchOptions(result, serializeMatchOptions(key, value), \"AND\");\n }\n // Dates only go into q\n if (dateProps.includes(key)) {\n result = mergeSearchOptions(result, serializeDateRange(key, value), \"AND\");\n }\n });\n // disabled is also a top-level property\n if (filter.hasOwnProperty(\"disabled\")) {\n result.disabled = filter.disabled;\n }\n // add the term\n if (filter.term) {\n // Note: this is slightly different from other types\n result.q = (\"(\" + filter.term + \") \" + result.q).trim();\n }\n return result;\n}\n//# sourceMappingURL=user-utils.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { expandContentFilter, serializeContentFilterForPortal, convertPortalResponseToFacets, } from \"./content-utils\";\nimport { searchItems } from \"@esri/arcgis-rest-portal\";\nimport { expandApi, getNextFunction } from \".\";\nimport { cloneObject, itemToContent, setContentSiteUrls, } from \"..\";\n/**\n * Search for content via the Portal or Hub API\n * @param filter\n * @param options\n */\nexport function _searchContent(filter, options) {\n var _a;\n return __awaiter(this, void 0, void 0, function () {\n var expanded, api, searchPromise, so;\n return __generator(this, function (_b) {\n expanded = expandContentFilter(filter);\n api = expandApi(options.api || \"arcgis\");\n // map over the apis, depending on the type we issue the queries\n // const searchPromises = apis.map((api) => {\n // Portal Search\n if (api.type === \"arcgis\") {\n so = serializeContentFilterForPortal(expanded);\n // pass auth forward\n if (options.authentication) {\n so.authentication = options.authentication;\n }\n else {\n so.portal = api.url + \"/sharing/rest\";\n }\n // Aggregations\n if ((_a = options.aggregations) === null || _a === void 0 ? void 0 : _a.length) {\n so.countFields = options.aggregations.join(\",\");\n so.countSize = 200;\n }\n // copy over various options\n // TODO: Dry this up - typscript makes this... inconvenient\n if (options.num) {\n so.num = options.num;\n }\n if (options.sortField) {\n so.sortField = options.sortField;\n }\n if (options.sortOrder) {\n so.sortOrder = options.sortOrder;\n }\n if (options.site) {\n so.site = cloneObject(options.site);\n }\n searchPromise = searchPortal(so);\n }\n else {\n // Hub API Search\n // TODO: Implement hub api content search\n searchPromise = Promise.resolve({\n total: 0,\n results: [],\n facets: [],\n hasNext: false,\n next: function () {\n Promise.resolve(null);\n },\n });\n }\n // });\n // return for results\n return [2 /*return*/, searchPromise];\n });\n });\n}\n/**\n * Internal portal search, which then converts items to Content, and\n * if a Site was passed, also sets urls\n *\n * @param searchOptions\n * @param site\n * @returns\n */\nfunction searchPortal(searchOptions) {\n return searchItems(searchOptions).then(function (resp) {\n var hasNext = resp.nextStart > -1;\n var content = resp.results.map(itemToContent);\n if (searchOptions.site) {\n content = content.map(function (entry) {\n return setContentSiteUrls(entry, searchOptions.site);\n });\n }\n // convert aggregations into facets\n var facets = convertPortalResponseToFacets(resp);\n return {\n total: resp.total,\n results: content,\n facets: facets,\n hasNext: hasNext,\n next: getNextFunction(searchOptions, resp.nextStart, resp.total, searchPortal),\n };\n });\n}\n//# sourceMappingURL=_searchContent.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { searchGroups as portalGroupSearch } from \"@esri/arcgis-rest-portal\";\nimport { expandApi, getNextFunction } from \".\";\nimport { expandGroupFilter, serializeGroupFilterForPortal, } from \"./group-utils\";\nimport { cloneObject, getGroupThumbnailUrl } from \"..\";\n/**\n * Search Groups using Filter<\"group\">\n *\n * Currently just returns ISearchResult<IGroup>\n * @param filter\n * @param options\n * @returns\n */\nexport function _searchGroups(filter, options) {\n var _a;\n return __awaiter(this, void 0, void 0, function () {\n var expanded, api, so, token, us, portalUrl;\n return __generator(this, function (_b) {\n expanded = expandGroupFilter(filter);\n api = expandApi(options.api || \"arcgis\");\n if (api.type === \"arcgis\") {\n so = serializeGroupFilterForPortal(expanded);\n token = \"\";\n // if we have auth, pass it forward\n // otherwise set the portal property\n if (options.authentication) {\n so.authentication = options.authentication;\n us = options.authentication;\n token = us.token;\n }\n else {\n so.portal = api.url + \"/sharing/rest\";\n }\n // TODO: Dry this up - typscript makes this... inconvenient\n if (options.num) {\n so.num = options.num;\n }\n if (options.sortField) {\n so.sortField = options.sortField;\n }\n if (options.sortOrder) {\n so.sortOrder = options.sortOrder;\n }\n portalUrl = api.url + \"/sharing/rest\";\n if ((_a = so.authentication) === null || _a === void 0 ? void 0 : _a.portal) {\n portalUrl = so.authentication.portal;\n }\n if (options.site) {\n so.site = cloneObject(options.site);\n }\n return [2 /*return*/, searchPortalGroups(so)];\n }\n else {\n throw new Error(\"_searchGroups is not implemented for non-arcgis apis\");\n }\n return [2 /*return*/];\n });\n });\n}\n/**\n * Internal function that searches for groups using the ArcGIS Portal API\n * @param searchOptions\n * @returns\n */\nfunction searchPortalGroups(searchOptions) {\n var _a;\n var teamLinkify = function (group) {\n group.siteTeamUrl = searchOptions.site.item.url + \"/teams/\" + group.id + \"/about\";\n return group;\n };\n var portalUrl = ((_a = searchOptions.authentication) === null || _a === void 0 ? void 0 : _a.portal) ||\n \"https://www.arcgis.com/sharing/rest\";\n var token;\n if (searchOptions.authentication) {\n var us = searchOptions.authentication;\n token = us.token;\n }\n var thumbnailify = function (group) {\n group.thumbnailUrl = getGroupThumbnailUrl(portalUrl, group, token);\n return group;\n };\n // execute the search\n return portalGroupSearch(searchOptions).then(function (response) {\n var _a, _b;\n var hasNext = response.nextStart > -1;\n // upgrade thumbnail url\n var results = response.results.map(thumbnailify);\n // generate the site team url if site url is provided\n if ((_b = (_a = searchOptions.site) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.url) {\n results = response.results.map(teamLinkify);\n }\n return {\n hasNext: hasNext,\n total: response.total,\n results: results,\n next: getNextFunction(searchOptions, response.nextStart, response.total, searchPortalGroups),\n };\n });\n}\n//# sourceMappingURL=_searchGroups.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { cloneObject, expandApi, expandUserFilter, getNextFunction, getUserThumbnailUrl, serializeUserFilterForPortal, } from \"..\";\nimport { searchUsers as portalUserSearch, } from \"@esri/arcgis-rest-portal\";\n/**\n * Search for Users via the Portal API.\n *\n * **Note** Authentication is required\n *\n * Note: in the future, there may be options to search via\n * a Hub specific API\n * @param filter\n * @param options\n * @returns\n */\nexport function _searchUsers(filter, options) {\n return __awaiter(this, void 0, void 0, function () {\n var expanded, api, searchOptions;\n return __generator(this, function (_a) {\n // JS Clients may not pass in authentication\n if (!options.authentication) {\n throw new Error(\"Authentication required to search for users.\");\n }\n expanded = expandUserFilter(filter);\n api = expandApi(options.api || \"arcgis\");\n if (api.type === \"arcgis\") {\n searchOptions = serializeUserFilterForPortal(expanded);\n // carry the auth forward\n searchOptions.authentication = options.authentication;\n // TODO: Dry this up - typscript makes this... inconvenient\n if (options.num) {\n searchOptions.num = options.num;\n }\n if (options.sortField) {\n searchOptions.sortField = options.sortField;\n }\n if (options.sortOrder) {\n searchOptions.sortOrder = options.sortOrder;\n }\n if (options.site) {\n searchOptions.site = cloneObject(options.site);\n }\n return [2 /*return*/, searchPortalUsers(searchOptions)];\n }\n else {\n throw new Error(\"_searchUsers is not implemented for non-arcgis apis\");\n }\n return [2 /*return*/];\n });\n });\n}\n/**\n * Internal function that executes the user search along with\n * some simple enrichments\n * @param searchOptions\n * @returns\n */\nfunction searchPortalUsers(searchOptions) {\n var portalUrl = searchOptions.authentication.portal;\n var token = searchOptions.authentication.token;\n // Partially applied functions for mapping over the results\n var userLinkify = function (user) {\n user.profileUrl = searchOptions.site.item.url + \"/people/\" + user.username + \"/profile\";\n return user;\n };\n var thumbnailify = function (user) {\n if (user.thumbnail) {\n user.thumbnailUrl = getUserThumbnailUrl(portalUrl, user, token);\n }\n return user;\n };\n return portalUserSearch(searchOptions).then(function (response) {\n var _a, _b;\n var hasNext = response.nextStart > -1;\n // upgrade thumbnail url\n var results = response.results.map(thumbnailify);\n // generate the site team url if site url is provided\n if ((_b = (_a = searchOptions.site) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.url) {\n results = response.results.map(userLinkify);\n }\n return {\n hasNext: hasNext,\n total: response.total,\n results: results,\n next: getNextFunction(searchOptions, response.nextStart, response.total, searchPortalUsers),\n };\n });\n}\n//# sourceMappingURL=_searchUsers.js.map","import { __awaiter, __generator } from \"tslib\";\n/**\n * Parse a response object, and throw if it contains an error.\n * Just a wrapper to hide some platform idiosyncracies\n * @param {Response} response Response object to parse\n * @private\n */\nexport function _checkStatusAndParseJson(response) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (response.status >= 200 && response.status < 300) {\n // don't try to parse the body if it's empty\n // if (response.body) { // the fetch polyfill for IE... does not expose a body property... :(\n return [2 /*return*/, response.json()];\n // }\n }\n else {\n // we're gonna throw, but we need to construct the error\n return [2 /*return*/, response.json().then(function (json) {\n if (json.error) {\n var error = new Error(json.error.title + \" :: \" + json.error.detail + \" :: \" + response.status);\n throw error;\n }\n else {\n throw new Error(\"Got \" + response.status + \" \" + response.statusText);\n }\n })];\n }\n return [2 /*return*/];\n });\n });\n}\n//# sourceMappingURL=_check-status-and-parse-json.js.map","import { getProp } from \"../../objects\";\n/**\n * Construct the auth header from a hub request options\n * @param {IHubRequestOptions} hubRequestOptions\n * @private\n */\nexport function _getAuthHeader(hubRequestOptions) {\n var result = {};\n var token = getProp(hubRequestOptions, \"authentication.token\");\n if (token) {\n result.Authorization = token;\n }\n return result;\n}\n//# sourceMappingURL=_get-auth-header.js.map","/**\n * Extract the domain service from the request options\n * @param {string} hubApiUrl\n * @private\n */\nexport function _getDomainServiceUrl(hubApiUrl) {\n var base = hubApiUrl || \"https://hub.arcgis.com\";\n return base + \"/api/v3/domains\";\n}\n//# sourceMappingURL=_get-domain-service-url.js.map","import { searchItems } from \"@esri/arcgis-rest-portal\";\nimport { includes } from \"../../utils\";\n/**\n * Lookup a domain in Portal\n * @param {string} hostname to locate the site for\n * @param {IRequestOptions} requestOptions\n * @private\n */\nexport function _lookupPortal(hostname, requestOptions) {\n // for portal we search for a site w/ `hubsubdomain|<domain>` type keyword\n var subdomain = hostname;\n // if this subdomain has a hash in it, knock that off\n if (hostname.indexOf(\"#/\") > -1) {\n subdomain = hostname.split(\"#/\")[1];\n }\n var queryTerm = \"hubsubdomain|\" + subdomain;\n var opts = Object.assign({\n q: \"typekeywords: \" + queryTerm,\n }, requestOptions);\n return searchItems(opts)\n .then(function (res) {\n // since the search api stems the terms, we need to verify\n // by looking at the results\n return res.results.filter(function (r) {\n return includes(r.typeKeywords, queryTerm);\n })[0];\n })\n .then(function (site) {\n if (!site)\n throw new Error(\"site not found\");\n return {\n hostname: site.url,\n siteId: site.id,\n };\n });\n}\n//# sourceMappingURL=_lookup-portal.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Create an entry in the domain system\n * @param {IHubDomain} domainEntry Domain hash to be stored\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function addDomain(domainEntry, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"addDomain is not available in ArcGIS Enterprise. Instead, edit the hubdomain typekeyword on the item\");\n }\n var headers = _getAuthHeader(hubRequestOptions);\n headers[\"Content-Type\"] = \"application/json\";\n var url = \"\" + _getDomainServiceUrl(hubRequestOptions.hubApiUrl);\n // handle case of siteTitle being numeric\n var title = domainEntry.siteTitle;\n if (typeof title === \"number\") {\n domainEntry.siteTitle = title.toString();\n }\n return fetch(url, {\n method: \"POST\",\n headers: headers,\n mode: \"cors\",\n body: JSON.stringify(domainEntry),\n }).then(_checkStatusAndParseJson);\n}\n//# sourceMappingURL=add-domain.js.map","import { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _getAuthHeader } from \"./_get-auth-header\";\nimport { stripProtocol } from \"../../urls\";\n/**\n * Check if a domain entry exists. Different from lookupDomain\n * in that this will return true/false, where as lookupDomain will\n * return the domain entry or throw. However, lookupDomain can work\n * with ArcGIS Enterprise.\n * Will throw if used in Portal.\n * @param {string} hostname Domain entry to check for\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function domainExists(hostname, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"domainExists is not available in ArcGIS Enterprise.\");\n }\n hostname = stripProtocol(hostname);\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + hostname;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" }).then(function (response) { return response.status !== 404; });\n}\n//# sourceMappingURL=domain-exists.js.map","import { _lookupPortal } from \"./_lookup-portal\";\n/**\n * Check if an item exists with the specified domain keyword\n * @param {String} hostname to check for\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function domainExistsPortal(hostname, hubRequestOptions) {\n return _lookupPortal(hostname, hubRequestOptions)\n .then(function (_) {\n return true;\n })\n .catch(function (_) {\n return false;\n });\n}\n//# sourceMappingURL=domain-exists-portal.js.map","import { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _getAuthHeader } from \"./_get-auth-header\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Get a list\n * @param {string} siteId Item id of the Site\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getDomainsForSite(siteId, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n return Promise.resolve([]);\n }\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"?siteId=\" + siteId;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" })\n .then(_checkStatusAndParseJson)\n .catch(function (err) {\n throw Error(\"Error in getDomainsForSite \" + err);\n });\n}\n//# sourceMappingURL=get-domains-for-site.js.map","import { domainExists } from \"./domain-exists\";\n/**\n * Ensure a unique domain name by checking for and incrementing\n * a subdomain\n * @param {String} subdomain Subdomain to ensure is unique\n * @param {String} baseHostname base hostname\n * @param hubRequestOptions\n * @param {Number} step Step number\n */\nexport function getUniqueDomainName(subdomain, baseHostname, hubRequestOptions, step) {\n if (step === void 0) { step = 0; }\n var combinedName = subdomain;\n if (step) {\n combinedName = subdomain + \"-\" + step;\n }\n var hostname = combinedName + \"-\" + baseHostname;\n return domainExists(hostname, hubRequestOptions).then(function (exists) {\n // if result === true, then we need to step the name...\n if (exists) {\n var nextStep = step + 1;\n return getUniqueDomainName(subdomain, baseHostname, hubRequestOptions, nextStep);\n }\n else {\n return combinedName;\n }\n });\n}\n//# sourceMappingURL=get-unique-domain-name.js.map","import { domainExistsPortal } from \"./domain-exists-portal\";\n/**\n * Ensure a unique domain name by checking for and incrementing\n * a subdomain\n * @param {String} subdomain Subdomain to ensure is unique\n * @param {IHubRequestOptions} hubRequestOptions\n * @param {*} step Step number\n */\nexport function getUniqueDomainNamePortal(subdomain, hubRequestOptions, step) {\n if (step === void 0) { step = 0; }\n var combinedName = subdomain;\n if (step) {\n combinedName = subdomain + \"-\" + step;\n }\n // now we search for existing items w/ this...\n return domainExistsPortal(combinedName, hubRequestOptions).then(function (exists) {\n if (exists) {\n var nextStep = step + 1;\n return getUniqueDomainNamePortal(subdomain, hubRequestOptions, nextStep);\n }\n else {\n return combinedName;\n }\n });\n}\n//# sourceMappingURL=get-unique-domain-name-portal.js.map","import { isGuid } from \"../../utils\";\n/**\n * Determine if a domain entry belongs to a legacy site.\n * This is used to allow customers to \"reclaim\" domains that\n * were associated with legacy sites which can no longer be\n * edited.\n * @param {IHubDomain} domainEntry Domain Info record\n */\nexport function isDomainForLegacySite(domainEntry) {\n return !isGuid(domainEntry.siteId);\n}\n//# sourceMappingURL=is-domain-for-legacy-site.js.map","import { _lookupPortal } from \"./_lookup-portal\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _getAuthHeader } from \"./_get-auth-header\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Fetch a the information about a domain.\n * Different implementation for Portal vs AGO\n * @param {string} hostname of domain record to locate\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function lookupDomain(hostname, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n return _lookupPortal(hostname, hubRequestOptions);\n }\n else {\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + hostname;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" }).then(_checkStatusAndParseJson);\n }\n}\n//# sourceMappingURL=lookup-domain.js.map","import { lookupDomain } from \"./lookup-domain\";\n/**\n * Check to see if a domain is in use by any site other than the\n * one passed in. This is used in various validators while the\n * user is editing properties of the site.\n * @param {string} hostname to check\n * @param {string} siteId Site Id we are checking for\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function isDomainUsedElsewhere(hostname, siteId, hubRequestOptions) {\n return lookupDomain(hostname, hubRequestOptions)\n .then(function (domainEntry) {\n return domainEntry.siteId !== siteId;\n })\n .catch(function () {\n // domain entry not found, ergo not used on another site\n return false;\n });\n}\n//# sourceMappingURL=is-domain-used-elsewhere.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \".\";\n/**\n * Validate a custom domain\n * @param {string} hostname to validate\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function isValidDomain(hostname, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"isValidDomain is not available in ArcGIS Enterprise.\");\n }\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/validate?hostname=\" + hostname;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" })\n .then(function (response) {\n return response.json();\n })\n .catch(function (e) {\n return {\n success: false,\n input: hostname,\n error: {\n code: 400,\n detail: e,\n message: \"lookupFailed\",\n },\n };\n });\n}\n//# sourceMappingURL=is-valid-domain.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Remove a domain entry.\n * User must be a member of the org that owns the domain entry.\n * @param {int} domainId Id of the domain entry to remove\n * @param {IHubRequestOptions} hubRequestOptions`dom\n */\nexport function removeDomain(domainId, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"removeDomain is not available in ArcGIS Enterprise. Instead, edit the hubdomain typekeyword on the item\");\n }\n var headers = _getAuthHeader(hubRequestOptions);\n headers[\"Content-Type\"] = \"application/json\";\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + domainId;\n return fetch(url, { method: \"DELETE\", headers: headers, mode: \"cors\" }).then(_checkStatusAndParseJson);\n}\n//# sourceMappingURL=remove-domain.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Update an entry in the domain system\n * @param {IHubDomain} domainEntry Doman object to be updated\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function updateDomain(domainEntry, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"updateDomain is not available in ArcGIS Enterprise. Instead, edit the hubdomain typekeyword on the item\");\n }\n var headers = _getAuthHeader(hubRequestOptions);\n headers[\"Content-Type\"] = \"application/json\";\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + domainEntry.id;\n // handle case of siteTitle being numeric\n var title = domainEntry.siteTitle;\n if (typeof title === \"number\") {\n domainEntry.siteTitle = title.toString();\n }\n return fetch(url, {\n method: \"PUT\",\n headers: headers,\n mode: \"cors\",\n body: JSON.stringify(domainEntry),\n }).then(_checkStatusAndParseJson);\n}\n//# sourceMappingURL=update-domain.js.map","import { cloneObject } from \"../../util\";\nimport { generateRandomString } from \"../../utils\";\n/**\n * Ensure that a subdomain is not greater than 63 characters in length\n * Subdomains are prep-ended on the org's url key, and the combined\n * length can not exceed 63 chars as per rules of domains.\n * If the requested subdomain + the url key is > 63 chars, we\n * strip off the last 6 chars and replace that w/ random characeters\n * This was an actual reported bug.\n * @param {String} subdomain Proposed subdomain\n * @param {String} urlKey Org url key\n * @private\n */\nexport function _ensureSafeDomainLength(subdomain, urlKey) {\n var result = cloneObject(subdomain);\n var max = 63;\n if (urlKey)\n max = max - (urlKey.length + 1);\n if (result.length > max) {\n result = result.slice(0, max - 6) + \"-\" + generateRandomString(5);\n }\n return result;\n}\n//# sourceMappingURL=_ensure-safe-domain-length.js.map","import { getUniqueDomainNamePortal } from \"./get-unique-domain-name-portal\";\nimport { getUniqueDomainName } from \"./get-unique-domain-name\";\nimport { _ensureSafeDomainLength } from \"./_ensure-safe-domain-length\";\nimport { stripProtocol } from \"../../urls\";\nimport { getHubApiUrl } from \"../..\";\n/**\n * Given a subdomain, ensure that we have a unique hostname\n * incrementing if needed\n * @param {String} subdomain Subdomain to unique-ify\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function ensureUniqueDomainName(subdomain, hubRequestOptions) {\n var prms;\n if (hubRequestOptions.isPortal) {\n prms = getUniqueDomainNamePortal(subdomain, hubRequestOptions);\n }\n else {\n var baseDomain = hubRequestOptions.portalSelf.urlKey + \".\" + stripProtocol(getHubApiUrl(hubRequestOptions));\n prms = getUniqueDomainName(subdomain, baseDomain, hubRequestOptions);\n }\n return prms.then(function (uniqueDomain) {\n return _ensureSafeDomainLength(uniqueDomain, hubRequestOptions.portalSelf.urlKey);\n });\n}\n//# sourceMappingURL=ensure-unique-domain-name.js.map","import { upgradeSiteSchema } from \".\";\nimport { getModel } from \"..\";\n/**\n * Get a Site Model by it's Item Id, and apply schema upgrades\n * @param {String} id Site Item Id\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getSiteById(id, hubRequestOptions) {\n return getModel(id, hubRequestOptions).then(upgradeSiteSchema);\n}\n//# sourceMappingURL=get-site-by-id.js.map","import { mergeObjects } from \"../..\";\n/**\n * Builds a draft with a subset of the model properties\n * @param {*} model - item model\n * @param {*} includeList - list of property paths to include in draft object\n */\nexport function buildDraft(model, includeList) {\n return mergeObjects(model, {}, includeList);\n}\n//# sourceMappingURL=build-draft.js.map","import { getProp, cloneObject, deleteProp, setProp } from \"..\";\n/**\n * Add telemetry config object\n * @private\n * @param {object} model Site Model\n * @returns {object}\n */\nexport function _ensureTelemetry(model) {\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.4)\n return model;\n var clone = cloneObject(model);\n var gacode = getProp(clone, \"data.values.gacode\");\n clone.data.values.telemetry = {\n consentNotice: {\n isTheme: true,\n consentText: \"\",\n policyURL: \"\",\n },\n customAnalytics: {\n ga: {\n customerTracker: {\n enabled: Boolean(gacode),\n id: gacode,\n },\n },\n },\n };\n deleteProp(clone, \"data.values.gacode\");\n setProp(\"item.properties.schemaVersion\", 1.4, clone);\n return clone;\n}\n//# sourceMappingURL=_ensure-telemetry.js.map","export var SITE_SCHEMA_VERSION = 1.5;\n//# sourceMappingURL=site-schema-version.js.map","import { getProp } from \"../objects\";\nimport { cloneObject } from \"../util\";\n/**\n * Apply the first schema version to the item\n * @param {Object} model Site Model\n * @private\n */\nexport function _applySiteSchema(model) {\n // if this has already been thru this step... skip it...\n if (getProp(model, \"item.properties.schemaVersion\") >= 1)\n return model;\n var clone = cloneObject(model);\n // proactively purge old properties\n [\"groupId\", \"title\"].forEach(function (prop) {\n delete clone.data.values[prop];\n });\n // ensure item.properties\n if (!clone.item.properties) {\n clone.item.properties = {};\n }\n clone.item.properties.schemaVersion = 1;\n // Groups!\n if (clone.data.values.groups && Array.isArray(clone.data.values.groups)) {\n // we have some groups arrays in prod where the contents are a mix of strings and objects.\n // we need to ensure this is just an array of groupIds...\n var groupIds = clone.data.values.groups\n .map(function (entry) {\n if (typeof entry === \"object\") {\n return entry.id;\n }\n else {\n return entry;\n }\n })\n .filter(function (entry) { return !!entry; });\n // now assign this back to the groups\n clone.data.values.groups = groupIds;\n }\n return clone;\n}\n//# sourceMappingURL=_apply-site-schema.js.map","import { getProp, cloneObject } from \"..\";\n/**\n * Enforce lowercase domains\n * @param {Object} model Site Model\n * @private\n */\nexport function _enforceLowercaseDomains(model) {\n // exit if this has been applied...\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.1)\n return model;\n var clone = cloneObject(model);\n // all the possible domain properties must be lower case\n [\n \"subdomain\",\n \"defaultHostname\",\n \"internalUrl\",\n \"customHostname\",\n \"externalUrl\",\n ].forEach(function (prop) {\n if (clone.data.values[prop] &&\n typeof clone.data.values[prop] === \"string\") {\n clone.data.values[prop] = clone.data.values[prop].toLowerCase();\n }\n });\n // bump the schemaVersion\n clone.item.properties.schemaVersion = 1.1;\n return clone;\n}\n//# sourceMappingURL=_enforce-lowercase-domains.js.map","import { getProp, cloneObject } from \"..\";\n/**\n * Move the data.values.groups array into the\n * data.catalog object\n * @param {Object} model Site Model\n * @private\n */\nexport function _ensureCatalog(model) {\n // early exit\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.2)\n return model;\n var clone = cloneObject(model);\n var catalog = getProp(clone, \"data.catalog\") || {};\n if (getProp(clone, \"data.values.groups\")) {\n catalog.groups = cloneObject(clone.data.values.groups);\n delete clone.data.values.groups;\n }\n clone.data.catalog = catalog;\n // bump the schemaVersion\n clone.item.properties.schemaVersion = 1.2;\n return clone;\n}\n//# sourceMappingURL=_ensure-catalog.js.map","import { getProp, cloneObject, isGuid } from \"..\";\n/**\n * Remove any non-guid entries from the data catalog groups array\n * @param {object} model Site Model\n * @private\n */\nexport function _purgeNonGuidsFromCatalog(model) {\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.3)\n return model;\n var clone = cloneObject(model);\n var groups = getProp(clone, \"data.catalog.groups\") || [];\n clone.data.catalog.groups = groups.filter(isGuid);\n clone.item.properties.schemaVersion = 1.3;\n return clone;\n}\n//# sourceMappingURL=_purge-non-guids-from-catalog.js.map","import { cloneObject, getProp } from \"..\";\n/**\n * Migrates the site so it can store configurations for multiple feed formats\n * (dcat-us-1.1, dcat-ap-2.0.1, etc.). If the site has an existing custom\n * configuration for dcat-us 1.1, a copy of that configuration will be modified\n * to use values from the v3 api instead of values from the index.\n *\n * Structural Impacts:\n * - site.data.feeds will be added.\n * - site.data.feeds.dcatUS11 will be added if site.data.values.dcatConfig exists.\n *\n * @param {object} model Site Model\n * @private\n */\nexport function _migrateFeedConfig(model) {\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.5)\n return model;\n var clone = cloneObject(model);\n var oldDcatUS11Config = clone.data.values.dcatConfig;\n clone.data.feeds = {};\n if (oldDcatUS11Config) {\n clone.data.feeds.dcatUS11 = _migrateToV3Values(oldDcatUS11Config);\n }\n clone.item.properties.schemaVersion = 1.5;\n return clone;\n}\nvar indexValueToV3Value = {\n // Defaults\n \"{{default.name}}\": \"{{name}}\",\n \"{{default.description}}\": \"{{description}}\",\n \"{{item.tags}}\": \"{{tags}}\",\n \"{{item.created:toISO}}\": \"{{created:toISO}}\",\n \"{{item.modified:toISO}}\": \"{{modified:toISO}}\",\n \"{{default.source.source}}\": \"{{source}}\",\n \"{{item.owner}}\": \"{{owner}}\",\n \"{{org.portalProperties.links.contactUs.url}}\": \"{{orgContactEmail}}\",\n // Custom Values\n \"{{org.name}}\": \"{{orgName}}\",\n \"{{item.categories}}\": \"{{categories}}\",\n \"{{item.licenseInfo}}\": \"{{licenseInfo}}\",\n \"{{item.modified}}\": \"{{modified}}\",\n \"{{enrichments.categories}}\": \"{{categories}}\",\n \"{{default.id}}\": \"{{id}}\",\n \"{{item.licenseInfo || No License}}\": \"{{licenseInfo || No License}}\",\n \"{{org.portalProperties.links.contactUs.url || mailto:data@tempe.gov}}\": \"{{orgContactEmail || mailto:data@tempe.gov}}\",\n \"{{default.description || No Description}}\": \"{{description || No Description}}\",\n \"{{item.id}}\": \"{{id}}\",\n};\nfunction _migrateToV3Values(originalConfig) {\n var migratedConfigString = JSON.stringify(originalConfig);\n var supportedIndexValues = Object.keys(indexValueToV3Value);\n supportedIndexValues.forEach(function (indexValue) {\n // Replace all occurrences of indexValue with the corresponding v3Value\n var v3Value = indexValueToV3Value[indexValue];\n migratedConfigString = migratedConfigString.split(indexValue).join(v3Value);\n });\n return JSON.parse(migratedConfigString);\n}\n//# sourceMappingURL=_migrate-feed-config.js.map","import { getProp } from \"../objects\";\nimport { SITE_SCHEMA_VERSION } from \"./site-schema-version\";\nimport { _applySiteSchema } from \"./_apply-site-schema\";\nimport { _enforceLowercaseDomains } from \"./_enforce-lowercase-domains\";\nimport { _ensureCatalog } from \"./_ensure-catalog\";\nimport { _purgeNonGuidsFromCatalog } from \"./_purge-non-guids-from-catalog\";\nimport { _ensureTelemetry } from \"./_ensure-telemetry\";\nimport { _migrateFeedConfig } from \"./_migrate-feed-config\";\n/**\n * Upgrades the schema upgrades\n * @param model IModel\n */\nexport function upgradeSiteSchema(model) {\n if (getProp(model, \"item.properties.schemaVersion\") === SITE_SCHEMA_VERSION) {\n return model;\n }\n else {\n // apply upgrade functions in order...\n model = _applySiteSchema(model);\n model = _enforceLowercaseDomains(model);\n model = _ensureCatalog(model);\n model = _purgeNonGuidsFromCatalog(model);\n model = _ensureTelemetry(model);\n model = _migrateFeedConfig(model);\n // WARNING - If you are writing a site schema migration,\n // you probably need to apply it to site drafts as well!\n // See https://github.com/Esri/hub.js/issues/498 for more details.\n return model;\n }\n}\n//# sourceMappingURL=upgrade-site-schema.js.map","import { stripProtocol } from \"../urls\";\nimport { isGuid } from \"../utils\";\nimport { lookupDomain } from \"./domains\";\nimport { getSiteById } from \"./get-site-by-id\";\n/**\n * Returns site model given various kinds of identifier\n *\n * @param identifier - a site item ID, site hostname, enterprise site slug, or full site URL\n * @param hubRequestOptions\n */\nexport function fetchSite(identifier, hubRequestOptions) {\n var prms;\n if (isGuid(identifier)) {\n prms = getSiteById(identifier, hubRequestOptions);\n }\n else {\n var hostnameOrSlug = identifier;\n // get down the the hostname\n hostnameOrSlug = stripProtocol(hostnameOrSlug);\n hostnameOrSlug = hostnameOrSlug.split(\"/\")[0];\n prms = lookupDomain(hostnameOrSlug, hubRequestOptions).then(function (_a) {\n var siteId = _a.siteId;\n return getSiteById(siteId, hubRequestOptions);\n });\n }\n return prms;\n}\nexport * from \"./domains\";\nexport * from \"./drafts\";\nexport * from \"./_ensure-telemetry\";\nexport * from \"./get-site-by-id\";\nexport * from \"./site-schema-version\";\nexport * from \"./upgrade-site-schema\";\n//# sourceMappingURL=index.js.map","/**\n * Locales supported by the hub\n */\nexport var HUB_LOCALES = [\n \"ar\",\n \"bs\",\n \"ca\",\n \"cs\",\n \"da\",\n \"de\",\n \"en\",\n \"es\",\n \"et\",\n \"el\",\n \"fi\",\n \"fr\",\n \"hr\",\n \"he\",\n \"hu\",\n \"it\",\n \"id\",\n \"ja\",\n \"ko\",\n \"lt\",\n \"lv\",\n \"nb\",\n \"nl\",\n \"pl\",\n \"pt\",\n \"pt-br\",\n \"pt-pt\",\n \"ro\",\n \"ru\",\n \"sl\",\n \"sr\",\n \"sv\",\n \"th\",\n \"tr\",\n \"uk\",\n \"vi\",\n \"zh\",\n \"zh-cn\",\n \"zh-tw\",\n \"zh-hk\"\n];\n//# sourceMappingURL=hub-locales.js.map","import { HUB_LOCALES } from \"./hub-locales\";\n/**\n * Convert a requested locale into a locale we support.\n * i.e. en-ca => en\n * If the requested locale is not available, en will be returned\n * @param {string} requestedLocale Locale we want\n */\nexport function convertToWellKnownLocale(requestedLocale) {\n if (requestedLocale === void 0) { requestedLocale = \"en\"; }\n var wellKnownKey = \"en\";\n // ensure downcase\n requestedLocale = requestedLocale.toLowerCase();\n // see if it's in the hub translations as-is\n if (HUB_LOCALES.indexOf(requestedLocale) > -1) {\n wellKnownKey = requestedLocale;\n }\n else {\n // if we split the requested locale, see if we have the root in the list\n var parts = requestedLocale.split(\"-\");\n if (parts.length > 1 && HUB_LOCALES.indexOf(parts[0]) > -1) {\n wellKnownKey = parts[0];\n }\n }\n return wellKnownKey;\n}\n//# sourceMappingURL=convert-to-well-known-locale.js.map","import { getHubLocaleAssetUrl } from \"../urls/get-hub-locale-asset-url\";\n/**\n * Fetch the Hub translation file for a given locale\n * These are all public urls and should never require auth/tokens etc\n * @param {String} locale Locale code - i.e. `es`\n * @param {Object} portal Portal Self\n */\nexport function fetchHubTranslation(locale, portal, mode) {\n if (mode === void 0) { mode = \"cors\"; }\n var assetBase = getHubLocaleAssetUrl(portal);\n var url = (assetBase + \"/locales/\" + locale + \".json\").toLocaleLowerCase();\n // to support web-tier auth, we must always send same-origin credentials\n var options = {\n method: \"GET\",\n credentials: \"same-origin\",\n mode: mode\n };\n return fetch(url, options)\n .then(function (response) { return response.json(); })\n .catch(function (err) {\n throw Error(\"Attempt to fetch locale \" + locale + \" from \" + url + \" failed: \" + JSON.stringify(err));\n });\n}\n//# sourceMappingURL=fetch-hub-translation.js.map","import { getProp } from \"../objects\";\n/**\n * Return the culture from the Hub Request Options\n * In priority order: user.culture, portal.culture, en-us\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getCulture(hubRequestOptions) {\n return (getProp(hubRequestOptions, \"portalSelf.user.culture\") ||\n getProp(hubRequestOptions, \"portalSelf.culture\") ||\n \"en-us\");\n}\n//# sourceMappingURL=get-culture.js.map","import { __assign, __extends } from \"tslib\";\nimport { getHubApiUrl } from \".\";\nimport { buildUrl } from \"./urls/build-url\";\n/**\n * remote server error\n */\nvar RemoteServerError = /** @class */ (function (_super) {\n __extends(RemoteServerError, _super);\n function RemoteServerError(message, url, status) {\n var _this = _super.call(this, message) || this;\n _this.status = status;\n _this.url = url;\n return _this;\n }\n return RemoteServerError;\n}(Error));\nexport { RemoteServerError };\n/**\n * ```js\n * import { hubApiRequest } from \"@esri/hub-common\";\n * //\n * hubApiRequest(\n * \"/datasets\",\n * requestOptions\n * })\n * .then(response);\n * ```\n * make a request to the Hub API\n * @param route API route\n * @param requestOptions request options\n */\nexport function hubApiRequest(route, requestOptions) {\n // merge in default request options\n var options = __assign({ \n // why do we default to GET w/ our API?\n httpMethod: \"GET\" }, requestOptions);\n // use fetch override if any\n var _fetch = options.fetch || fetch;\n // merge in default headers\n var headers = __assign({ \"Content-Type\": \"application/json\" }, options.headers);\n // build query params/body based on requestOptions.params\n var query;\n var body;\n if (options.httpMethod === \"GET\") {\n // pass params in query string\n query = options.params;\n }\n else {\n // pass params in request body\n body = JSON.stringify(options.params);\n }\n // build Hub API URL\n var url = buildUrl({\n host: getHubApiUrl(options),\n path: (\"/api/v3/\" + route).replace(/\\/\\//g, \"/\"),\n query: query,\n });\n return _fetch(url, {\n method: options.httpMethod,\n headers: headers,\n body: body,\n }).then(function (resp) {\n if (resp.ok) {\n return resp.json();\n }\n else {\n throw new RemoteServerError(resp.statusText, url, resp.status);\n }\n });\n}\n//# sourceMappingURL=request.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Gets the primary input Feature Service for the given\n * Form ID. This will be the Fieldworker view, if it exists,\n * otherwise the source Feature Service.\n * @param {string} formId The Form ID\n * @param requestOptions The request options\n * @returns {Promise<IModel>}\n */\nexport var getInputFeatureServiceModel = function (formId, requestOptions) {\n return getRelatedItems(__assign({ id: formId, relationshipType: \"Survey2Service\", direction: \"forward\" }, requestOptions)).then(function (_a) {\n var featureService = _a.relatedItems[0];\n var model;\n if (featureService) {\n model = { item: featureService };\n }\n return model;\n });\n};\n//# sourceMappingURL=get-input-feature-service-model.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Fetches a Survey's source Feature Service from a given\n * Fieldworker View ID\n * @param {string} fieldworkerId The Fieldworker View ID\n * @param {IRequestOptions} requestOptions The request options\n * @returns {Promise<IModel>}\n */\nexport var getSourceFeatureServiceModelFromFieldworker = function (fieldworkerId, requestOptions) {\n return getRelatedItems(__assign({ id: fieldworkerId, relationshipType: \"Service2Data\", direction: \"forward\" }, requestOptions)).then(function (_a) {\n var featureService = _a.relatedItems[0];\n var model;\n if (featureService) {\n model = { item: featureService };\n }\n return model;\n });\n};\n//# sourceMappingURL=get-source-feature-service-model-from-fieldworker.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Fetches a Survey's Stakeholder View for a given\n * Form ID\n * @param {string} formId A Form ID\n * @param {IRequestOptions} requestOptions The request options\n * @returns {Promise<IModel>}\n */\nexport var getStakeholderModel = function (formId, requestOptions) {\n return getRelatedItems(__assign({ id: formId, relationshipType: \"Survey2Data\", direction: \"forward\" }, requestOptions)).then(function (_a) {\n var stakeholderView = _a.relatedItems[0];\n var model;\n if (stakeholderView) {\n model = { item: stakeholderView };\n }\n return model;\n });\n};\n//# sourceMappingURL=get-stakeholder-model.js.map","/**\n * Determines if the provided Feature Service item is a\n * Fieldworker View\n * @param {IItem} featureServiceItem\n * @returns {boolean}\n */\nexport function isFieldworkerView(featureServiceItem) {\n var hasTypekeyword = function (typeKeyword) {\n return featureServiceItem.typeKeywords.indexOf(typeKeyword) > -1;\n };\n // Survey123 only recently added the \"FieldworkerView\" typekeyword\n var isFieldworker = hasTypekeyword(\"FieldworkerView\");\n // we should support previously created fieldworkers too\n if (!isFieldworker) {\n var hasExpectedTypeKeywords = [\n \"Survey123\",\n \"Feature Service\",\n \"View Service\",\n ].every(hasTypekeyword);\n isFieldworker =\n hasExpectedTypeKeywords && !hasTypekeyword(\"StakeholderView\");\n }\n return isFieldworker;\n}\n//# sourceMappingURL=is-fieldworker-view.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { getItem } from \"@esri/arcgis-rest-portal\";\nimport { getInputFeatureServiceModel } from \"./get-input-feature-service-model\";\nimport { getSourceFeatureServiceModelFromFieldworker } from \"./get-source-feature-service-model-from-fieldworker\";\nimport { getStakeholderModel } from \"./get-stakeholder-model\";\nimport { isFieldworkerView } from \"./is-fieldworker-view\";\n/**\n * Builds a dictionary of Survey items for the given Form model\n * @param {string} formId The Form ID of the survey\n * @param {IRequestOptions} requestOptions The request options\n * @returns {Promise<IGetSurveyModelsResponse>}\n */\nexport var getSurveyModels = function (formItemOrId, requestOptions) {\n var fieldworker;\n var stakeholder;\n var getForm = function () {\n return typeof formItemOrId === \"string\"\n ? getItem(formItemOrId, requestOptions)\n : Promise.resolve(formItemOrId);\n };\n return getForm().then(function (form) {\n var promises = [\n // the primary input will be the fieldworker (if it exists), otherwise\n // the source feature service.\n getInputFeatureServiceModel(form.id, requestOptions),\n getStakeholderModel(form.id, requestOptions),\n ];\n return Promise.all(promises)\n .then(function (_a) {\n var featureServiceOrFieldworkerModelResult = _a[0], stakeholderResult = _a[1];\n stakeholder = stakeholderResult;\n if (featureServiceOrFieldworkerModelResult &&\n isFieldworkerView(featureServiceOrFieldworkerModelResult.item)) {\n fieldworker = featureServiceOrFieldworkerModelResult;\n // if the primary input is the fieldworker, fetch\n // the source feature service\n return getSourceFeatureServiceModelFromFieldworker(fieldworker.item.id, requestOptions);\n }\n else {\n return featureServiceOrFieldworkerModelResult;\n }\n })\n .then(function (featureService) {\n return {\n form: { item: form },\n featureService: featureService,\n fieldworker: fieldworker,\n stakeholder: stakeholder,\n };\n });\n });\n};\n//# sourceMappingURL=get-survey-models.js.map","/* Copyright (c) 2018-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __spreadArrays } from \"tslib\";\nimport { cloneObject, createId } from \"./util\";\nimport { getWithDefault } from \"./objects/get-with-default\";\n/**\n * Allows an application to track a series of operations, storing information\n * about the arguments passes in and the results returned\n *\n * ```js\n * import { OperationStack } from '@esri/solution-common';\n *\n * const stack = new OperationStack();\n *\n * // start an operation by type\n * const id = stack.start('getItem');\n * //.. work happens...\n * stack.finish(id);\n *\n * // start an operation with an Operation object\n * stack.start({\n * id: 'createItem_1',\n * type: 'createItem',\n * inputs: {\n * item: {...truncated...},\n * portal: 'https://www.arcgis.com',\n * username: 'jsmith'\n * },\n * });\n * // make the call\n * stack.finish('createItem_1', {newItemId: '00cf213'});\n *\n * // later you can get that information back out of the stack\n * const prevOp = stack.getOperation('createItem_1);\n *\n * // and if you need to roll back you can use the\n * // .cleanup and .output properties to help orchestrate\n *\n * ```\n *\n *\n * Can be used to implement \"atomic\" operations in an environment that does not\n * have this as a core feature\n */\nvar OperationStack = /** @class */ (function () {\n /**\n * Creates an instance of OperationStack.\n * @memberof OperationStack\n */\n function OperationStack() {\n this.operations = [];\n }\n /**\n * Start an Operation\n *\n * ```js\n * const stack = new OperationStack();\n * stack.startOperation({\n * id: 'get-bc3',\n * type: 'getItem',\n * cleanup: 'n/a',\n * inputs: {\n * id: 'bc3',\n * owner: 'vader'\n * }\n * });\n * // do work\n * stack.finish('get-bc3');\n * ```\n *\n *\n * @param {IOperation} operation\n * @memberof OperationStack\n */\n OperationStack.prototype.startOperation = function (operation) {\n var op = cloneObject(operation);\n op.startedAt = new Date().getTime();\n op.state = \"working\";\n this.operations.push(op);\n };\n /**\n * Start an operation without requiring a full operation\n *\n * ```js\n * const opId = stack.start('getItems');\n * //...work happens\n * stack.finish(opId);\n * ```\n *\n * @param {string} type Type of the operation. i.e. getItem\n * @param {Record<string, unknown>} [params] optionally pass in id, inputs, cleanup\n * @returns {string} Identifier of the new stack entry\n * @memberof OperationStack\n */\n OperationStack.prototype.start = function (type, params) {\n var op = {\n type: type,\n id: getWithDefault(params, \"id\", createId(type + \"_\")),\n inputs: getWithDefault(params, \"inputs\", {}),\n cleanup: getWithDefault(params, \"cleanup\", \"n/a\"),\n startedAt: new Date().getTime(),\n state: \"working\"\n };\n this.operations.push(op);\n return op.id;\n };\n /**\n * Returns a reference to an Operation\n *\n * @param {string} id Unique Identifier\n * @returns {Operation}\n * @memberof OperationStack\n */\n OperationStack.prototype.getOperation = function (id) {\n return this.operations.find(function (o) { return o.id === id; });\n };\n /**\n * Returns reference to the operations array\n *\n * @returns {Operation[]}\n * @memberof OperationStack\n */\n OperationStack.prototype.getOperations = function () {\n return this.operations;\n };\n /**\n * Inform the stack that an operation has finished.\n *\n * This will append in a duration property, and mark\n * the state as 'completed'.\n *\n * @param {string} id Unique identifier of the Operation\n * @param {Record<string, unknown>} [options] outputs\n * @memberof OperationStack\n */\n OperationStack.prototype.finish = function (id, options) {\n var op = this.getOperation(id);\n if (op) {\n op.duration = new Date().getTime() - op.startedAt;\n op.state = \"completed\";\n if (options) {\n op.output = cloneObject(options);\n }\n }\n else {\n throw new Error(\"No operation with id \" + id + \" present in stack\");\n }\n };\n /**\n * Merge a serialized operation stack into\n * a stack instance\n *\n * ```js\n * import { OperationStack } from '@esri/solution-common';\n * function someFunction() {\n * const stack = new OperationStack();\n * stack.start('getItem', {id: 'get-bc3'});\n * // do some work...\n * stack.finish('get-bc3');\n *\n * const itm = {title: 'Fake Item', type: 'Web Map'};\n * // create an entry for the function we are about to call...\n * stack.start('createItem', {id: 'createItem_01', inputs: {item: itm}});\n * // call a function that does work, and has it's own stack\n * // and returns a serialized version as part of it's results\n * return createItem(itm)\n * .then((result) => {\n * // tell the stack the last operation finished...\n * stack.finish('createItem_01');\n * // merge in the stack from the function we called\n * stack.merge(result.stack);\n * // > stack.getCompleted().length === 3\n * });\n * }\n *\n * function createItem (itm) {\n * const otherStack = new OperationStack();\n * const id = otherStack.start('createItem');\n * // make calls to create item etc\n * otherStack.finish(id, {itemId: newItem.id});\n * otherStack.start('protectItem', {id: 'protect-00c'});\n * // make call to protect item...\n * otherStack.finish('protect-00c');\n * // all done... return a result with a stack\n * return Promise.resolve({\n * success:true,\n * stack: otherStack.serialize()\n * });\n * }\n * ```\n *\n * Typically used to create a comprehensive list of operations\n * when a function returns a `SerializedOperationStack` as part of\n * it's response\n *\n *\n * @param {ISerializedOperationStack} stack\n * @memberof OperationStack\n */\n OperationStack.prototype.merge = function (stack) {\n this.operations = __spreadArrays(this.operations, stack.operations);\n };\n /**\n * Get a list of the completed operations\n *\n * @returns {IOperation[]}\n * @memberof OperationStack\n */\n OperationStack.prototype.getCompleted = function () {\n return cloneObject(this.operations.filter(function (e) { return e.state === \"completed\"; }));\n };\n /**\n * Return an array of working operations\n *\n * @returns {IOperation[]}\n * @memberof OperationStack\n */\n OperationStack.prototype.getWorking = function () {\n return cloneObject(this.operations.filter(function (e) { return e.state === \"working\"; }));\n };\n /**\n * Serialize the completed operations into a set of\n * human readable messages, sorted by the startedAt timestamp\n *\n *\n * @returns {string}\n * @memberof IOperationStack\n */\n OperationStack.prototype.toString = function () {\n // sort the operations by StartedAt\n var allOps = this.operations.sort(function (a, b) {\n if (a.startedAt < b.startedAt) {\n return -1;\n }\n if (b.startedAt < a.startedAt) {\n return 1;\n }\n return 0;\n });\n return allOps.map(getOperationMessage).join(\"\\n\");\n };\n /**\n * Serialize the stack into simple objects\n *\n * @returns {ISerializedOperationStack}\n * @memberof OperationStack\n */\n OperationStack.prototype.serialize = function () {\n return {\n operations: cloneObject(this.getOperations())\n };\n };\n return OperationStack;\n}());\nexport default OperationStack;\nfunction getOperationMessage(op) {\n var msg = op.startedAt + \" : Operation \" + op.id + \" started with inputs \" + JSON.stringify(op.inputs) + \" but was not completed\";\n if (op.state === \"completed\") {\n msg = op.startedAt + \" : Operation \" + op.id + \" took \" + op.duration + \" ms with inputs \" + JSON.stringify(op.inputs) + \" and output \" + (op.output ? JSON.stringify(op.output) : \"n/a\");\n }\n return msg;\n}\n//# sourceMappingURL=OperationStack.js.map"],"names":["cloneObject","getWithDefault","Level","getPortalUrl","_sendSafeRequest","_generateRequestOptions","_generateBatchRequests","_combineResults","getPortalApiUrl","app","dataset","document","event","feedback","initiative","map","other","site","allCategories","keystr","atob","btoa","portalGroupSearch","portalUserSearch"],"mappings":";;;;;;;;;;;;IAAA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,UAAU,CAAC,GAAG,EAAE,EAAE,EAAE;IACpC,IAAI,IAAI,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAChC,IAAI,IAAI,SAAS,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU,GAAG,EAAE,UAAU,EAAE;IAC3D,QAAQ,GAAG,CAAC,UAAU,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,UAAU,EAAE,GAAG,CAAC,CAAC;IAC/D,QAAQ,OAAO,GAAG,CAAC;IACnB,KAAK,EAAE,EAAE,CAAC,CAAC;IACX,IAAI,OAAO,SAAS,CAAC;IACrB;;ICZA;IACA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,cAAc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AAW,EAAE;IAClC,QAAQ,GAAG,GAAG,EAAE,CAAC,SAAS,GAAG,eAAe,GAAG,EAAE,CAAC,EAAE,GAAG,QAAQ,GAAG,EAAE,CAAC,QAAQ,GAAG,kBAAkB,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,MAAM,CAAC,GAAG,cAAc,IAAI,EAAE,CAAC,MAAM,GAAG,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,MAAM,CAAC,GAAG,KAAK,CAAC,CAAC;IAClM,KAAK;IACL,IAAI,OAAO,GAAG,CAAC;IACf;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"common.umd.js","sources":["../esm/objects/_map-values.js","../esm/objects/_deep-map-values.js","../esm/objects/get-prop.js","../esm/util.js","../esm/objects/deep-set.js","../esm/objects/ensure-prop.js","../esm/objects/get-props.js","../esm/objects/get-with-default.js","../esm/objects/remove-empty-props.js","../esm/objects/deep-string-replace.js","../esm/objects/merge-objects.js","../esm/objects/set-prop.js","../esm/objects/deepFind.js","../esm/utils/batch.js","../esm/utils/includes.js","../esm/utils/ensure-unique-string.js","../../../../node_modules/tslib/tslib.es6.js","../esm/OperationError.js","../esm/utils/create-operation-pipeline.js","../esm/utils/fail-safe.js","../esm/utils/generate-random-string.js","../esm/utils/get-hub-product.js","../esm/utils/get-subscription-type.js","../esm/utils/is-guid.js","../esm/utils/map-by.js","../esm/utils/slugify.js","../esm/utils/without-by-prop.js","../esm/utils/propify-string.js","../esm/utils/increment-string.js","../esm/utils/logger.js","../esm/utils/is-update-group.js","../esm/utils/revertable-tasks.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/process-params.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/encode-query-string.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/encode-form-data.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/ArcGISRequestError.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/warn.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/request.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/append-custom-params.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/clean-url.js","../../../../node_modules/@esri/arcgis-rest-request/dist/esm/utils/decode-query-string.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/fetch-token.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/generate-token.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/federation-utils.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/validate-app-access.js","../../../../node_modules/@esri/arcgis-rest-auth/dist/esm/UserSession.js","../esm/utils/sessionLocalStorage.js","../esm/access/has-base-priv.js","../esm/access/can-edit-event.js","../esm/access/can-edit-item.js","../esm/access/can-edit-site-content.js","../esm/access/can-edit-site.js","../esm/urls/build-url.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/get-portal-url.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/helpers.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/update.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/add.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/get.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/protect.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/get.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/helpers.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/remove.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/SearchQueryBuilder.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/generic-search.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/items/search.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/array.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/add-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/remove-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/invite-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/protect.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/remove.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/search.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/groups/update-user-membership.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/orgs/notification.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/users/get-user.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/users/search-users.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/is-item-shared-with-group.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/share-item-with-group.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/sharing/unshare-item-with-group.js","../../../../node_modules/@esri/arcgis-rest-portal/dist/esm/util/get-portal.js","../esm/urls/get-portal-url.js","../esm/urls/hub-cdn-urlmap.js","../esm/urls/get-hub-locale-asset-url.js","../esm/urls/get-portal-api-url.js","../esm/urls/upgrade-protocol.js","../esm/urls/strip-protocol.js","../esm/urls/_get-http-and-https-uris.js","../esm/urls/_get-location.js","../esm/urls/_get-hub-url-from-portal-hostname.js","../esm/urls/get-hub-url-from-portal.js","../esm/urls/get-hub-api-url-from-portal.js","../esm/urls/get-item-home-url.js","../esm/urls/get-item-api-url.js","../esm/urls/get-item-data-url.js","../esm/urls/convert-urls-to-anchor-tags.js","../esm/urls/index.js","../esm/api.js","../esm/auth.js","../esm/collections.js","../esm/categories.js","../esm/extent.js","../esm/items/get-structured-license.js","../esm/content/_internal.js","../esm/content/index.js","../../../../node_modules/abab/lib/atob.js","../../../../node_modules/abab/lib/btoa.js","../../../../node_modules/abab/index.js","../esm/downloads/build-existing-exports-portal-query.js","../esm/groups/_unprotect-and-remove-group.js","../esm/groups/add-users-workflow/output-processors/_consolidate-results.js","../esm/groups/add-users-workflow/output-processors/_format-auto-add-response.js","../esm/groups/add-users-workflow/utils/_can-email-user.js","../esm/groups/add-users-workflow/utils/_is-org-admin.js","../esm/groups/add-users-workflow/workflow-sections/email-org-users.js","../esm/groups/add-users-workflow/output-processors/_process-secondary-email.js","../esm/groups/add-users-workflow/workflow-sections/auto-add-users.js","../esm/groups/add-users-workflow/output-processors/_process-auto-add.js","../esm/groups/add-users-workflow/workflow-sections/invite-users.js","../esm/groups/add-users-workflow/output-processors/_process-invite.js","../esm/groups/add-users-workflow/output-processors/_process-primary-email.js","../esm/groups/add-users-workflow/utils/_get-auto-add-users.js","../esm/groups/add-users-workflow/utils/_get-invite-users.js","../esm/groups/add-users-workflow/utils/_get-email-users.js","../esm/groups/add-users-workflow/add-users-to-group.js","../esm/items/_unprotect-and-remove-item.js","../esm/items/apply-properties-to-items.js","../esm/items/delete-prop.js","../esm/items/serialize-model.js","../esm/items/fail-safe-update.js","../esm/items/get-model.js","../esm/items/get-model-from-options.js","../../../../node_modules/adlib/dist/adlib.esm.js","../esm/items/interpolate.js","../esm/items/interpolate-item-id.js","../esm/items/normalize-solution-template-item.js","../esm/items/replace-item-id.js","../esm/items/share-item-to-groups.js","../esm/items/unprotect-model.js","../esm/items/unshare-item-from-groups.js","../esm/items/does-item-exist-with-title.js","../esm/items/get-unique-item-title.js","../esm/items/fetch-all-pages.js","../esm/resources/_add-token-to-resource-url.js","../esm/resources/convert-solution-template-resources-to-assets.js","../esm/resources/fetch-image-as-blob.js","../esm/resources/fetch-and-upload-resource.js","../esm/resources/fetch-and-upload-thumbnail.js","../esm/resources/get-item-thumbnail-url.js","../esm/resources/get-item-assets.js","../esm/resources/string-to-blob.js","../esm/resources/upload-resources-from-url.js","../esm/resources/add-solution-resource-url-to-assets.js","../esm/resources/object-to-json-blob.js","../esm/search/hub-api-search.js","../esm/search/utils.js","../esm/search/content-utils.js","../esm/search/group-utils.js","../esm/search/user-utils.js","../esm/search/_searchContent.js","../esm/search/_searchGroups.js","../esm/search/_searchUsers.js","../esm/sites/domains/_check-status-and-parse-json.js","../esm/sites/domains/_get-auth-header.js","../esm/sites/domains/_get-domain-service-url.js","../esm/sites/domains/_lookup-portal.js","../esm/sites/domains/add-domain.js","../esm/sites/domains/domain-exists.js","../esm/sites/domains/domain-exists-portal.js","../esm/sites/domains/get-domains-for-site.js","../esm/sites/domains/get-unique-domain-name.js","../esm/sites/domains/get-unique-domain-name-portal.js","../esm/sites/domains/is-domain-for-legacy-site.js","../esm/sites/domains/lookup-domain.js","../esm/sites/domains/is-domain-used-elsewhere.js","../esm/sites/domains/is-valid-domain.js","../esm/sites/domains/remove-domain.js","../esm/sites/domains/update-domain.js","../esm/sites/domains/_ensure-safe-domain-length.js","../esm/sites/domains/ensure-unique-domain-name.js","../esm/sites/get-site-by-id.js","../esm/sites/drafts/build-draft.js","../esm/sites/_ensure-telemetry.js","../esm/sites/site-schema-version.js","../esm/sites/_apply-site-schema.js","../esm/sites/_enforce-lowercase-domains.js","../esm/sites/_ensure-catalog.js","../esm/sites/_purge-non-guids-from-catalog.js","../esm/sites/_migrate-feed-config.js","../esm/sites/upgrade-site-schema.js","../esm/sites/index.js","../esm/i18n/hub-locales.js","../esm/i18n/convert-to-well-known-locale.js","../esm/i18n/fetch-hub-translation.js","../esm/i18n/get-culture.js","../esm/request.js","../esm/surveys/get-input-feature-service-model.js","../esm/surveys/get-source-feature-service-model-from-fieldworker.js","../esm/surveys/get-stakeholder-model.js","../esm/surveys/is-fieldworker-view.js","../esm/surveys/get-survey-models.js","../esm/ArcGISContextState.js","../esm/ArcGISContext.js","../esm/OperationStack.js"],"sourcesContent":["/**\n * Maps over the values of an object (one level deep)\n * @param obj\n * @param fn\n * @private\n */\nexport function _mapValues(obj, fn) {\n var keys = Object.keys(obj);\n var newObject = keys.reduce(function (acc, currentKey) {\n acc[currentKey] = fn(obj[currentKey], currentKey, obj);\n return acc;\n }, {});\n return newObject;\n}\n//# sourceMappingURL=_map-values.js.map","import { _mapValues } from \"./_map-values\";\n/**\n * Maps over _all_ values of an object graph\n * @param object\n * @param callback function to be called on each value\n * @param propertyPath an initial path (optional, only changes what is passed to the callback as the \"path\" argument)\n * @private\n */\nexport function _deepMapValues(object, callback, propertyPath) {\n propertyPath = propertyPath || \"\";\n if (Array.isArray(object)) {\n return object.map(deepMapValuesIteratee);\n }\n else if (object &&\n _isObject(object) &&\n !_isDate(object) &&\n !_isRegExp(object) &&\n !_isFunction(object)) {\n return Object.assign({}, object, _mapValues(object, deepMapValuesIteratee));\n }\n else {\n return callback(object, propertyPath);\n }\n function deepMapValuesIteratee(value, key) {\n var valuePath = \"\" + (propertyPath ? propertyPath + \".\" + key : key);\n return _deepMapValues(value, callback, valuePath);\n }\n}\n// Simple \"good-enough\" type checks for the tree traversal functions\n// these are not bullet-proof and should not be public/docd\n/**\n * Is this a string?\n * @param v\n * @private\n */\nexport function _isString(v) {\n return typeof v === \"string\" || v instanceof String;\n}\n/**\n * Return if the passed entry is a Date\n * @param v\n * @private\n */\nexport function _isDate(v) {\n return v instanceof Date;\n}\n/**\n * Is this a function?\n * @param v\n * @private\n */\nexport function _isFunction(v) {\n return typeof v === \"function\";\n}\n/**\n * Is this an Object?\n * @param v\n * @private\n */\nexport function _isObject(v) {\n return typeof v === \"object\";\n}\n/**\n * Is this a regexp?\n * @param v\n * @private\n */\nexport function _isRegExp(v) {\n return v instanceof RegExp;\n}\n//# sourceMappingURL=_deep-map-values.js.map","/**\n * Get a property out of a deeply nested object\n * Does not handle anything but nested object graph\n */\nexport function getProp(obj, path) {\n return path.split(\".\").reduce(function (prev, curr) {\n /* istanbul ignore next no need to test undefined scenario */\n return prev ? prev[curr] : undefined;\n }, obj);\n}\n//# sourceMappingURL=get-prop.js.map","/* Copyright (c) 2018-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { getProp } from \"./objects/get-prop\";\n/**\n * ```js\n * import { cloneObject } from \"@esri/hub-common\";\n * const original = { foo: \"bar\" }\n * const copy = cloneObject(original)\n * copy.foo // \"bar\"\n * copy === original // false\n * ```\n * Make a deep clone, including arrays. Does not handle functions!\n */\nexport function cloneObject(obj) {\n var clone = {};\n // first check array\n if (Array.isArray(obj)) {\n clone = obj.map(cloneObject);\n }\n else if (typeof obj === \"object\") {\n for (var i in obj) {\n /* istanbul ignore next no need to deal w/ other side of hasOwnProperty() */\n if (obj.hasOwnProperty(i)) {\n var value = obj[i];\n if (value != null && typeof value === \"object\") {\n if (value instanceof Date) {\n clone[i] = new Date(value.getTime());\n }\n else {\n clone[i] = cloneObject(value);\n }\n }\n else {\n clone[i] = value;\n }\n }\n }\n }\n else {\n clone = obj;\n }\n return clone;\n}\n/**\n * Given an array of objects, convert into an object, with each\n * entry assigned the key via the keyprop\n */\nexport function arrayToObject(arr, key) {\n return arr.reduce(function (hash, entry) {\n hash[getProp(entry, key)] = entry;\n return hash;\n }, {});\n}\n/**\n * Given an object, convert into an array, with each\n * something or other\n */\nexport function objectToArray(obj, keyProp) {\n if (keyProp === void 0) { keyProp = \"id\"; }\n var arr = Object.keys(obj).reduce(function (acc, prop) {\n obj[prop][keyProp] = prop;\n acc.push(cloneObject(obj[prop]));\n return acc;\n }, []);\n return arr;\n}\n/**\n * Return an entry from an array by a property name\n */\nexport function findBy(arr, prop, value) {\n if (!arr) {\n return null;\n }\n var res = arr.reduce(function (acc, entry) {\n if (getProp(entry, prop) === value) {\n acc = entry;\n }\n return acc;\n }, null);\n return res;\n}\n/**\n * Return a new array without the specified value.\n *\n * @export\n * @param {any[]} arr\n * @param {*} val value or object to remove\n * @returns {any[]} Array without the value\n */\nexport function without(arr, value) {\n var res = arr.filter(function (entry) { return entry !== value; });\n return res;\n}\n/**\n * Compose\n * adapted from: https://github.com/stoeffel/compose-function/blob/master/module/index.js\n */\nexport function compose() {\n var fns = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n fns[_i] = arguments[_i];\n }\n return fns.reduce(function (f, g) {\n return function () {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n return f(g.apply(void 0, args));\n };\n });\n}\n/**\n * Return a random number, prefixed with a string. Used for unique identifiers that do not require\n * the rigor of a full UUID - i.e. node id's, process ids etc.\n * @param prefix String to prefix the random number with so the result is a valid javascript property\n */\nexport function createId(prefix) {\n if (prefix === void 0) { prefix = \"i\"; }\n // prepend some char so it's always a valid dotable property name\n // get a random number, convert to base 36 representation, then grab chars 2-8\n return \"\" + prefix + Math.random().toString(36).substr(2, 8);\n}\n/**\n * Append or replace a value on an object, using a specified key, if the value is not null.\n * This is a very useful companion to the [getProp()](../getProp/) utility.\n *\n * Note: object that is passed in is cloned before the property is appended.\n *\n * Allows for code like:\n *\n * ```js\n * let model = {\n * item: {\n * title: 'some example object',\n * description: 'this is some longer text',\n * type: 'Web Map',\n * properties: {\n * sourceId: '3ef'\n * }\n * },\n * data: {\n * theme: 'orange',\n * parcelLayer: {\n * primaryField: 'PIN'\n * }\n * }\n * };\n *\n * // Let's extract some details into an object.\n * const summary = [\n * 'item.title',\n * 'item.description',\n * 'item.missingProp',\n * 'data.parcelLayer.primaryField'].reduce((acc, prop) => {\n * // create the property name... you could do this however...\n * let propName = prop.split('.').reverse()[0];\n * return maybeAdd(propName, getProp(model, key), acc);\n * }, {});\n *\n * // summary =>\n * // {\n * // title: 'some example object',\n * // description: 'this is some longer text',\n * // primaryField: 'PIN'\n * // }\n * ```\n * @param key - key to use when appending to the object\n * @param val - the possibly null value\n * @param target - the object to update\n */\nexport function maybeAdd(key, val, target) {\n // see if we got something...\n if (val !== null && val !== undefined) {\n target = cloneObject(target);\n // attach using the key\n target[key] = val;\n }\n return target;\n}\n/**\n * Append a value to an array, if the value is not null.\n * This is a very useful companion to the [getProp()](../getProp/) utility.\n *\n * Note: the array that is passed in is cloned before being appended to.\n *\n * Allows for code like:\n * ```js\n * // example object\n * let model = {\n * item: {\n * id: 'c00',\n * title: 'some example object',\n * description: 'this is some longer text',\n * type: 'Web Map',\n * properties: {\n * sourceId: '3ef'\n * }\n * },\n * data: {\n * theme: 'orange',\n * parcelLayer: {\n * itemId: '7ca',\n * primaryField: 'PIN'\n * }\n * }\n * };\n * // lets pluck some id's into an array...\n * maybePush(getProp(model, 'item.properties.sourceId'), []);\n * // > ['3ef']\n *\n * // now try to get a value from a property that is missing...\n * maybePush(getProp(obj, 'item.properties.childId'), []);\n * // > []\n *\n * // easily pluck values via property paths\n * const summary = [\n * 'item.id',\n * 'item.properties.sourceId',\n * 'item.properties.childId',\n * 'data.parcelLayer.itemId'].reduce((acc, prop) => {\n * return maybePush(getProp(model, key), acc);\n * }, []);\n *\n * // summary => ['c00', '3ef', '7ca']\n *\n * ```\n *\n * @param val - the possibly null value\n * @param target - the array to add the value to\n */\nexport function maybePush(val, target) {\n if (val !== null && val !== undefined) {\n // create a clone because mutation makes us sad...\n target = cloneObject(target);\n target.push(val);\n }\n return target;\n}\n/**\n * Convert a string to camelCase\n *\n * @export\n * @param {string} value\n * @returns {string} camelCased string\n */\nexport function camelize(value) {\n // lower case the whole thing to start...\n value = value.toLowerCase();\n // strip out any/all special chars...\n value = value.replace(/[`~!@#$%^&*()_|+\\-=?;:'\",.<>\\{\\}\\[\\]\\\\\\/]/gi, \" \");\n // Hoisted from EmberJS (MIT License)\n // https://github.com/emberjs/ember.js/blob/v2.0.1/packages/ember-runtime/lib/system/string.js#L23-L27\n var STRING_CAMELIZE_REGEXP_1 = /(\\-|\\_|\\.|\\s)+(.)?/g;\n var STRING_CAMELIZE_REGEXP_2 = /(^|\\/)([A-Z])/g;\n return value\n .replace(STRING_CAMELIZE_REGEXP_1, function (match, separator, chr) {\n return chr ? chr.toUpperCase() : \"\";\n })\n .replace(STRING_CAMELIZE_REGEXP_2, function (match, separator, chr) {\n return match.toLowerCase();\n });\n}\n/**\n * Determines if a value is unique in an array\n * Allows for code like:\n *\n * ```js\n * const ary = [ 1, 2, 3, 3, 4, 5, 1 ];\n *\n * const result = ary.filter(unique);\n *\n * result => [ 1, 2, 3, 4, 5 ]\n * ```\n * @param value - the value to search for\n * @param index - the index of the searched value\n * @param ary - the array to search\n * @returns {boolean} - indicating if the value is unique in the array\n */\nexport function unique(value, index, ary) {\n return ary.indexOf(value) === index;\n}\n/**\n * Return array of unique objects, based on a deep property value\n * Note: Property you compare on should be a primative type\n * @export\n * @template T\n * @param {T[]} arr\n * @param {string} prop\n * @return {*} {T[]}\n */\nexport function uniqueBy(arr, prop) {\n return arr.reduce(function (acc, entry) {\n var nameMatches = function (e) {\n return getProp(e, prop) === getProp(entry, prop);\n };\n return maybePush(acc.find(nameMatches) ? null : entry, acc);\n }, []);\n}\n/**\n * Return last element of an array\n *\n * @export\n * @template T\n * @param {T[]} arr\n * @return {*} {T}\n */\nexport function last(arr) {\n return arr[arr.length - 1];\n}\n/**\n * Filter an array by a deep property value\n *\n * @export\n * @template T\n * @param {T[]} arr\n * @param {string} prop\n * @param {unknown} val\n * @return {*} {T[]}\n */\nexport function filterBy(arr, prop, val) {\n return arr.filter(function (entry) { return getProp(entry, prop) === val; });\n}\n/**\n * Extends the target object with props from the source object, overwriting identically named\n * props in target with those from source, ignoring null and undefined values; similar to $.extend.\n * Performs a deep extend by default, unless deep = false is passed as the third arg.\n *\n * @param target - the object that will take props from source\n * @param source - the object from which to take props\n * @param deep - whether or not to perform a deep (recursive) extend of source\n */\nexport function extend(target, source, deep) {\n if (deep === void 0) { deep = true; }\n var extended = cloneObject(target);\n return Object.keys(source).reduce(function (obj, prop) {\n if (source[prop] !== null && source[prop] !== undefined) {\n var value = cloneObject(source[prop]);\n if (Array.isArray(value)) {\n // check for arrays, since array is type object\n obj[prop] = value;\n }\n else if (deep && typeof value === \"object\") {\n obj[prop] = extend(obj[prop] || {}, value, deep);\n }\n else {\n obj[prop] = value;\n }\n }\n return obj;\n }, extended);\n}\n/**\n * Add number of days to a given date\n *\n * @export\n * @param {string} date\n * @param {number} numOfDays\n * @returns {string} date string with numOfDays added to the given date\n */\nexport function addDays(date, numOfDays) {\n try {\n var given = new Date(date);\n var dateString = new Date(given.setDate(given.getDate() + numOfDays)).toISOString();\n return dateString.split(\"T\")[0];\n }\n catch (e) {\n throw new Error(\"Invalid Date\");\n }\n}\n/**\n * Returns an array with arrays of the given size.\n *\n * @param arr Array to split\n * @param size Size of every group\n */\nexport function chunkArray(arr, size) {\n var results = [];\n var index = 0;\n while (index < arr.length) {\n results.push(arr.slice(index, index + size));\n index += size;\n }\n return results;\n}\n/**\n * Determine if a value is null or undefined\n * @param value anything\n * @returns\n */\nexport var isNil = function (value) { return value == null; };\n/**\n * Upper case first letter (only) of a string\n * @param word\n * @returns Word\n */\nexport var capitalize = function (word) {\n // upper case first letter and return as element in array for backwards compatibility\n var chars = Array.from(word);\n chars[0] = chars[0].toUpperCase();\n return chars.join(\"\");\n};\n/**\n * An IE-compatible stand-in for Javascript's [array.flat](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/flat)\n * @param arr the array\n * @returns an array\n */\nexport function flattenArray(arr) {\n return arr.reduce(function (acc, val) { return acc.concat(val); }, []);\n}\n//# sourceMappingURL=util.js.map","import { cloneObject } from \"../util\";\n/**\n * Deep set function. Like Ember.set, but smarter as it will create the path\n * @param {Object} target Object we want to set the property on\n * @param {String} path Dotted path to the property we want to set\n * @param {Any} value Value we want to assign to the property\n */\nexport function deepSet(target, path, value) {\n if (value === void 0) { value = {}; }\n var parts = path.split(\".\");\n var worker = target;\n var lastIdx = parts.length - 1;\n parts.forEach(function (p, idx) {\n if (!worker.hasOwnProperty(p) || worker[p] == null) {\n if (idx === lastIdx) {\n worker[p] = value;\n }\n else {\n // keep building the path\n worker[p] = {};\n }\n }\n else if (idx === lastIdx) {\n if (typeof worker[p] === \"object\" && !Array.isArray(worker[p])) {\n worker[p] = Object.assign(worker[p], cloneObject(value));\n }\n else {\n worker[p] = value;\n }\n }\n worker = worker[p];\n });\n}\n//# sourceMappingURL=deep-set.js.map","import { deepSet } from \"./deep-set\";\n/**\n * Ensure that an object has a deep property path.\n * This will replace any existing object at the end of the path\n * @param {Object} target Object we want to ensure has some deep property\n * @param {string} path Dotted path to the property we want to ensure exists\n */\nexport function ensureProp(target, path) {\n return deepSet(target, path);\n}\n//# sourceMappingURL=ensure-prop.js.map","import { getProp } from \"./get-prop\";\n/**\n * Given an array of prop paths, return all the values that exist, in an array\n */\nexport function getProps(obj, props) {\n return props.reduce(function (a, p) {\n var v = getProp(obj, p);\n if (v) {\n a.push(v);\n }\n return a;\n }, []);\n}\n//# sourceMappingURL=get-props.js.map","import { getProp } from \"./get-prop\";\n/**\n * Gets the value of a property from an object with a\n * default if that prop is undefined\n * @param obj\n * @param prop\n * @param def\n */\nexport function getWithDefault(obj, prop, def) {\n var res = getProp(obj, prop);\n return res !== undefined ? res : def;\n}\n//# sourceMappingURL=get-with-default.js.map","/**\n * Remove empty properties from an object graph\n * @param {Object} obj Object to remove empty/null properties from\n */\nexport function removeEmptyProps(obj) {\n // http://stackoverflow.com/questions/286141/remove-blank-attributes-from-an-object-in-javascript\n Object.keys(obj).forEach(function (key) {\n if (obj[key] && typeof obj[key] === \"object\") {\n removeEmptyProps(obj[key]);\n }\n else if (obj[key] == null) {\n delete obj[key];\n }\n });\n return obj;\n}\n//# sourceMappingURL=remove-empty-props.js.map","import { _deepMapValues, _isString, _isRegExp } from \"./_deep-map-values\";\n/**\n * Iterate over an object graph, and for all string properties, search for a string,\n * and replace it with another string\n */\nexport function deepStringReplace(obj, stringOrRegex, replacement) {\n var replacedObject = _deepMapValues(obj, function (value) {\n // Only string templates\n if (!_isString(value)) {\n return value;\n }\n var re;\n if (_isRegExp(stringOrRegex)) {\n re = stringOrRegex;\n }\n else {\n re = new RegExp(stringOrRegex, \"g\");\n }\n return value.replace(re, replacement);\n });\n return replacedObject;\n}\n//# sourceMappingURL=deep-string-replace.js.map","import { getProp } from \"./get-prop\";\nimport { deepSet } from \"./deep-set\";\n/**\n * Apply a specified set properties from a source object to a target object\n *\n * @param {Object} source The source object\n * @param {Object} target The target object\n * @param {Array} allowList Array of property paths (if not provided, source returned)\n */\nexport function mergeObjects(source, target, allowList) {\n if (Array.isArray(allowList) && allowList.length) {\n // we iterate the allowList, applying changes to the target from source\n allowList.forEach(function (prop) {\n if (getProp(source, prop) !== undefined) {\n deepSet(target, prop, getProp(source, prop));\n }\n });\n // return the modified target object\n return target;\n }\n else {\n // if no property paths were passed in, return the source\n return source;\n }\n}\n//# sourceMappingURL=merge-objects.js.map","import { deepSet } from \"./deep-set\";\n/**\n * Sets a deep object property, constructing the property path as necessary\n *\n * @param path - the path to the property we want to set\n * @param val - the value we want to set it to\n * @param obj - the target object\n */\nexport function setProp(path, val, obj) {\n if (Array.isArray(path)) {\n path = path.join(\".\");\n }\n deepSet(obj, path, val);\n}\n//# sourceMappingURL=set-prop.js.map","import { _isDate, _isFunction, _isObject, _isRegExp, } from \"./_deep-map-values\";\n/**\n * Traverse a graph, locating the first entry with an `id` property that\n * has a specific string or number value\n *\n * ```js\n * const l = {\n * one: {\n * two: [\n * {\n * id: \"n001\",\n * color: \"red\"\n * },\n * {\n * id: \"n002\",\n * color: \"yellow\"\n * }\n * ]\n * }\n * };\n *\n * const config = deepFindById(l, \"n002\")\n * //> {id: \"n002\", color:\"yellow\"}\n * ```\n *\n * This was designed to search a Site/Page/Project layout, and return\n * the config for a card. There was some concern about the performance\n * and using a real layout object, in the test, it takes ~1.5ms to\n * do the search.\n *\n * @param object\n * @param key\n * @param value\n * @returns\n */\nexport function deepFindById(object, value) {\n var p = function (obj) { return obj.id === value; };\n return deepFind(object, p);\n}\n/**\n * Traverse a graph locating an entry that passes the predicate\n *\n * @param object\n * @param predicate\n * @returns\n */\nexport function deepFind(object, predicate) {\n if (Array.isArray(object)) {\n return object.reduce(function (acc, entry) {\n if (predicate(entry)) {\n acc = entry;\n }\n else {\n if (isFindable(entry)) {\n var maybe = deepFind(entry, predicate);\n if (maybe) {\n acc = maybe;\n }\n }\n }\n return acc;\n }, undefined);\n }\n else if (isFindable(object)) {\n if (predicate(object)) {\n return object;\n }\n else {\n return Object.keys(object).reduce(function (acc, entry) {\n if (isFindable(object[entry])) {\n var maybe = deepFind(object[entry], predicate);\n if (maybe) {\n acc = maybe;\n }\n }\n return acc;\n }, undefined);\n }\n }\n else {\n return undefined;\n }\n}\nfunction isFindable(object) {\n var result = false;\n if (object &&\n _isObject(object) &&\n !_isDate(object) &&\n !_isRegExp(object) &&\n !_isFunction(object)) {\n result = true;\n }\n return result;\n}\n//# sourceMappingURL=deepFind.js.map","/**\n * Helper to split a large number of calls into\n * smaller batches of concurrent calls.\n * @param {Array} values Any array of values with which to invoke fn\n * @param {Function} fn The function that will be invoked with each value\n * @param {number} [batchSize=5] The number of concurrent calls to fn, defaults to 5\n * @returns {Promise<IBatch[]>}\n */\nexport function batch(values, fn, batchSize) {\n if (batchSize === void 0) { batchSize = 5; }\n var toBatches = function (_batches, value) {\n var _batch = _batches[_batches.length - 1];\n if (!_batch || _batch.length === batchSize) {\n _batch = [];\n _batches.push(_batch);\n }\n _batch.push(value);\n return _batches;\n };\n var toSerialBatchChain = function (promise, batchOfValues) {\n var executeBatch = function (prevResults) {\n var batchResults = batchOfValues.map(function (id) { return fn(id); });\n return Promise.all(batchResults).then(function (results) {\n return prevResults.concat(results);\n });\n };\n return promise.then(executeBatch);\n };\n // split values into batches of values\n var batches = values.reduce(toBatches, []);\n // batches are processed serially, however\n // all calls within a batch are concurrent\n return batches.reduce(toSerialBatchChain, Promise.resolve([]));\n}\n//# sourceMappingURL=batch.js.map","/**\n * Checks whether a value exists in the given array\n * @param array The array\n * @param val The value\n */\nexport function includes(array, val) {\n return array.indexOf(val) !== -1;\n}\n//# sourceMappingURL=includes.js.map","import { includes } from \"./includes\";\n/**\n * Given an array of strings, add a value and ensure it is unique by incrementing a suffix number\n * @param {Array} entries array of strings\n * @param {string} value string to uniqueify and add\n */\nexport function ensureUniqueString(entries, value) {\n var foundUnique = false;\n var num = 0;\n var chk = value;\n while (!foundUnique) {\n if (includes(entries, chk)) {\n num++;\n chk = value + \"-\" + num;\n }\n else {\n foundUnique = true;\n }\n }\n return chk;\n}\n//# sourceMappingURL=ensure-unique-string.js.map","/*! *****************************************************************************\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***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n 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 extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(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\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n 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;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\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;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport function __createBinding(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}\r\n\r\nexport function __exportStar(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !exports.hasOwnProperty(p)) exports[p] = m[p];\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\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 () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\r\n result.default = mod;\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","/* Copyright (c) 2018-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __extends } from \"tslib\";\nimport { getWithDefault } from \"./objects/get-with-default\";\n/**\n * Generic Solution Error with an Error stack as well\n * as an optional serialized OperationStack.\n *\n * Also accepts a `rootCause` Error object\n */\nvar OperationError = /** @class */ (function (_super) {\n __extends(OperationError, _super);\n /**\n * Creates an instance of OperationError.\n * @param {string} operation\n * @param {string} [message]\n * @param {Error} [rootCause]\n * @memberof OperationError\n */\n function OperationError(operation, message, rootCause) {\n var _this = this;\n message = message || \"UNKNOWN_ERROR\";\n // if the rootCause has a .rootCause, use that so we don't deeply nest\n rootCause = getWithDefault(rootCause, \"rootCause\", rootCause);\n _this = _super.call(this, message) || this;\n _this.operation = operation;\n _this.name = \"OperationError\";\n _this.rootCause = rootCause;\n Object.setPrototypeOf(_this, OperationError.prototype);\n // using rootCause.stack ensures that the resulting error will have the original\n // message + call stack. If that's not an option, we create a new\n // stack... which is better than nothing, but it will look like\n // OperationError is the source of the error\n _this.stack = getWithDefault(rootCause, \"stack\", new Error().stack);\n return _this;\n }\n return OperationError;\n}(Error));\nexport default OperationError;\n//# sourceMappingURL=OperationError.js.map","import OperationError from \"../OperationError\";\n/**\n * Returns a function that orchestrates a pipeline of smaller functions.\n * See [Composing Workflows](../../../guides/composing-workflows) for more information.\n *\n * All the functions must adhere to the `PipelineFn<T>` signature:\n *\n * `(value: IPipeable<T>) => Promise<IPipeable<T>>`\n *\n * Given an array of OperationPipeFns, run them in sequence and return the resultant promise\n *\n * i.e. `createOperationPipeline([fn1, fn2, f3])` will return in a function that chains\n * the functions like this: `fn1(input).then(fn2).then(fn3).then(result)`\n *\n * @param fns functions to be run in sequence\n * @returns Promise<Pipable<T>>\n */\nexport var createOperationPipeline = function (fns) {\n return function (input) {\n return fns.reduce(function (chain, func) {\n return chain.then(func).catch(function (err) {\n // if it's an OperationError we can just reject with it...\n if (err.name === \"OperationError\") {\n return Promise.reject(err);\n }\n else {\n // otherwise, create an OperationError and reject with that\n var msg = \"IPipeableFn did not reject with an OperationError \\n Operation Stack: \\n \" + input.stack.toString();\n var opErr = new OperationError(\"pipeline execution error\", msg);\n opErr.operationStack = input.stack.serialize();\n return Promise.reject(opErr);\n }\n });\n }, Promise.resolve(input));\n };\n};\n//# sourceMappingURL=create-operation-pipeline.js.map","/**\n * Wrap an async function such that it will never reject\n * @param {Function} fn Async Function that we want to never fail\n * @param {Object} resolveWith Object to resolve with in the event of a failure\n */\nexport function failSafe(fn, resolveWith) {\n if (resolveWith === void 0) { resolveWith = {}; }\n return function () {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n return fn.apply(void 0, args).catch(function (_) {\n return resolveWith;\n });\n };\n}\n//# sourceMappingURL=fail-safe.js.map","/**\n * Generate a random string of a specified length\n * User when we need to ensure a unique domain with a fixed length\n * @param {Number} chars Length of random string\n */\nexport function generateRandomString(chars) {\n var d = new Date().getTime();\n var result = Array(chars)\n .fill(0)\n .reduce(function (acc) {\n /* tslint:disable-next-line */\n var r = (d + Math.random() * 16) % 16 | 0;\n d = Math.floor(d / 16);\n acc = \"\" + acc + r.toString(16);\n return acc;\n }, \"\");\n return result;\n}\n//# sourceMappingURL=generate-random-string.js.map","import { getProp } from \"../objects/get-prop\";\n/**\n * Gien a portal settings object, determine the hub product name\n * @param {Object} portal Portal settings object\n */\nexport function getHubProduct(portal) {\n var isPremium = getProp(portal, \"portalProperties.hub.enabled\") || false;\n var product = isPremium ? \"premium\" : \"basic\";\n // TODO confirm w/ AGO that this is 100% bomber logic\n if (portal.isPortal && portal.portalMode === \"singletenant\") {\n product = \"portal\";\n }\n return product;\n}\n//# sourceMappingURL=get-hub-product.js.map","import { getWithDefault } from \"../objects/get-with-default\";\nexport var getSubscriptionType = function (portalSelf) {\n return getWithDefault(portalSelf, \"subscriptionInfo.type\", \"Enterprise\");\n};\n//# sourceMappingURL=get-subscription-type.js.map","/**\n * Is a String a GUID?\n * @param {string} stringToTest string to check if it's a GUID\n */\nexport function isGuid(stringToTest) {\n // strip curlies if sent...\n if (stringToTest[0] === \"{\") {\n stringToTest = stringToTest.substring(1, stringToTest.length - 1);\n }\n // ughh... seems legit\n var regexGuid = /^(\\{){0,1}[0-9a-fA-F]{8}[-]?[0-9a-fA-F]{4}[-]?[0-9a-fA-F]{4}[-]?[0-9a-fA-F]{4}[-]?[0-9a-fA-F]{12}(\\}){0,1}$/gi;\n // test\n return regexGuid.test(stringToTest);\n}\n//# sourceMappingURL=is-guid.js.map","/**\n * Map over an array returning the specified property for each entry\n * @param {String} prop Property to extracct\n * @param {Array} arr array of objects\n */\nexport function mapBy(prop, arr) {\n if (arr === void 0) { arr = []; }\n return arr.map(function (e) { return e[prop]; });\n}\n//# sourceMappingURL=map-by.js.map","/**\n * Perform the following operations on a string to make it slug-friendly:\n * 1. trim it\n * 2. convert to lowercase\n * 3. remove any character not a-z, 0-9, or _\n * 4. dasherize it\n * @param {String} value String to slugify\n */\nexport function slugify(value) {\n if (typeof value === \"string\") {\n // @ts-ignore\n return value\n .trim()\n .toLowerCase()\n .replace(/ +/g, \"-\")\n .replace(/[^\\w-]/g, \"\")\n .replace(/-+/g, \"-\");\n }\n else {\n return value;\n }\n}\n//# sourceMappingURL=slugify.js.map","/**\n * Returns a new array with all the entries have the given value\n * at the given prop location removed.\n *\n * @param prop the property\n * @param val the value\n * @param arr the array\n */\nexport function withoutByProp(prop, val, arr) {\n return arr.filter(function (e) {\n return e[prop] !== val;\n });\n}\n//# sourceMappingURL=without-by-prop.js.map","import { camelize } from \"../util\";\n/**\n * Given a string, strip out chars etc that would make it\n * and invalid javascript property name, then camelize it.\n * @param {string} value String to convert into a property\n */\nexport function propifyString(value) {\n var result = value;\n // strip off any leading numbers...\n result = result.replace(/^[0-9]*/g, \"\");\n // remove any rando chars...\n result = result.replace(/[^\\w\\s]/g, \"\");\n // camelize the rest...\n result = camelize(result);\n return result;\n}\n//# sourceMappingURL=propify-string.js.map","/**\n * Given a string, append a `- 1` on the end if no number is present\n * otherwise, increment the number\n * @param {string} str String to increment\n */\nexport function incrementString(str) {\n var matches = str.match(/-\\s(\\d+$)/);\n if (matches) {\n // get the number\n var current = parseInt(matches[1], 10);\n // replace `- current` with `- current + 1`\n var next = current + 1;\n str = str.replace(\"- \" + current, \"- \" + next);\n }\n else {\n str = str + \" - 1\";\n }\n return str;\n}\n//# sourceMappingURL=increment-string.js.map","/* tslint:disable no-console */\nimport { __spreadArrays } from \"tslib\";\n/**\n * Enum for Logger Levels\n */\nexport var Level;\n(function (Level) {\n Level[Level[\"all\"] = 0] = \"all\";\n Level[Level[\"debug\"] = 1] = \"debug\";\n Level[Level[\"info\"] = 2] = \"info\";\n Level[Level[\"warn\"] = 3] = \"warn\";\n Level[Level[\"error\"] = 4] = \"error\";\n Level[Level[\"off\"] = 5] = \"off\";\n})(Level || (Level = {}));\n/**\n * ```js\n * import { Logger, Level } from '@esri/hub-common'\n * ```\n * Functions share the console interface\n * ```js\n * Logger.log('My Message');\n * Logger.warn('Watch out!', { threat: 'Charizard' });\n * // etc, etc\n * ```\n * Available logging levels are specified in the Level enum. The hierarchy is as follows:\n * ```\n * off > error > warn > info > debug > all\n * ```\n * Logger only sends messages whose level is greater than or equal to the global log level\n * ```js\n * // Global level is 'warn'\n * Logger.info('This message won't log');\n * Logger.error('But this one will!');\n * ```\n * Logger's default level is 'off', so set desired level before use\n * ```js\n * Logger.setLogLevel(Level.all);\n * ```\n */\nvar Logger = /** @class */ (function () {\n function Logger() {\n }\n /**\n * Sets the global log level\n * @param {Level} level\n */\n Logger.setLogLevel = function (level) {\n this.logLevel = level;\n };\n /**\n * Logs to debug if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.log = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.debug)) {\n console.log.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to debug if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.debug = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.debug)) {\n console.debug.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to info if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.info = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.info)) {\n console.info.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to warn if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.warn = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.warn)) {\n console.warn.apply(console, __spreadArrays([message], objects));\n }\n };\n /**\n * Logs to error if level is enabled\n * @param {string} message\n * @param {...*} objects additional objects to log (optional rest parameter)\n */\n Logger.error = function (message) {\n var objects = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n objects[_i - 1] = arguments[_i];\n }\n if (this.isLevelPermitted(Level.error)) {\n console.error.apply(console, __spreadArrays([message], objects));\n }\n };\n Logger.isLevelPermitted = function (level) {\n return this.logLevel <= level;\n };\n Logger.logLevel = Level.off;\n return Logger;\n}());\nexport { Logger };\n//# sourceMappingURL=logger.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Determines if a given IGroup is an update group\n * @param {IGroup} group The group to evaluate\n */\nexport function isUpdateGroup(group) {\n return group.capabilities.includes(\"updateitemcontrol\");\n}\n//# sourceMappingURL=is-update-group.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Runs the given task and returns a IRevertableTaskResult\n * @param {Function} task A task method to run\n * @param {Function} revert A method to revert the task\n * @returns {Promise<IRevertableTaskResult>}\n */\nexport var runRevertableTask = function (task, revert) {\n return task()\n .then(function (results) {\n return {\n status: \"fullfilled\",\n results: results,\n revert: revert\n };\n })\n .catch(function (error) {\n return { status: \"rejected\", error: error };\n });\n};\n/**\n * Processes an Array of Promise<IRevertableTaskResult>. When all IRevertableTaskResult\n * are IRevertableTaskSuccess, it resolves an Array of all result values. If any\n * IRevertableTaskResult are IRevertableTaskFailed, it reverts all IRevertableTaskSuccess\n * and rejects with the first IRevertableTaskFailed error\n * @param revertableTasks\n * @returns {Promise<any[]>}\n */\nexport var processRevertableTasks = function (revertableTasks) {\n return Promise.all(revertableTasks).then(function (results) {\n var isFullfilled = function (result) {\n return result.status === \"fullfilled\";\n };\n var successfulTasks = results.filter(isFullfilled);\n var failedTasks = results.filter(function (result) { return !isFullfilled(result); });\n if (failedTasks.length) {\n var reverts = successfulTasks.map(function (task) { return task.revert(); });\n // fire & forget\n /* tslint:disable no-empty */\n Promise.all(reverts).catch(function () { });\n /* tslint:enable no-empty */\n throw failedTasks[0].error;\n }\n var returnResults = successfulTasks.map(function (result) { return result.results; });\n return returnResults;\n });\n};\n//# sourceMappingURL=revertable-tasks.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Checks parameters to see if we should use FormData to send the request\n * @param params The object whose keys will be encoded.\n * @return A boolean indicating if FormData will be required.\n */\nexport function requiresFormData(params) {\n return Object.keys(params).some(function (key) {\n var value = params[key];\n if (!value) {\n return false;\n }\n if (value && value.toParam) {\n value = value.toParam();\n }\n var type = value.constructor.name;\n switch (type) {\n case \"Array\":\n return false;\n case \"Object\":\n return false;\n case \"Date\":\n return false;\n case \"Function\":\n return false;\n case \"Boolean\":\n return false;\n case \"String\":\n return false;\n case \"Number\":\n return false;\n default:\n return true;\n }\n });\n}\n/**\n * Converts parameters to the proper representation to send to the ArcGIS REST API.\n * @param params The object whose keys will be encoded.\n * @return A new object with properly encoded values.\n */\nexport function processParams(params) {\n var newParams = {};\n Object.keys(params).forEach(function (key) {\n var _a, _b;\n var param = params[key];\n if (param && param.toParam) {\n param = param.toParam();\n }\n if (!param &&\n param !== 0 &&\n typeof param !== \"boolean\" &&\n typeof param !== \"string\") {\n return;\n }\n var type = param.constructor.name;\n var value;\n // properly encodes objects, arrays and dates for arcgis.com and other services.\n // ported from https://github.com/Esri/esri-leaflet/blob/master/src/Request.js#L22-L30\n // also see https://github.com/Esri/arcgis-rest-js/issues/18:\n // null, undefined, function are excluded. If you want to send an empty key you need to send an empty string \"\".\n switch (type) {\n case \"Array\":\n // Based on the first element of the array, classify array as an array of arrays, an array of objects\n // to be stringified, or an array of non-objects to be comma-separated\n // eslint-disable-next-line no-case-declarations\n var firstElementType = (_b = (_a = param[0]) === null || _a === void 0 ? void 0 : _a.constructor) === null || _b === void 0 ? void 0 : _b.name;\n value =\n firstElementType === \"Array\" ? param : // pass thru array of arrays\n firstElementType === \"Object\" ? JSON.stringify(param) : // stringify array of objects\n param.join(\",\"); // join other types of array elements\n break;\n case \"Object\":\n value = JSON.stringify(param);\n break;\n case \"Date\":\n value = param.valueOf();\n break;\n case \"Function\":\n value = null;\n break;\n case \"Boolean\":\n value = param + \"\";\n break;\n default:\n value = param;\n break;\n }\n if (value || value === 0 || typeof value === \"string\" || Array.isArray(value)) {\n newParams[key] = value;\n }\n });\n return newParams;\n}\n//# sourceMappingURL=process-params.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { processParams } from \"./process-params\";\n/**\n * Encodes keys and parameters for use in a URL's query string.\n *\n * @param key Parameter's key\n * @param value Parameter's value\n * @returns Query string with key and value pairs separated by \"&\"\n */\nexport function encodeParam(key, value) {\n // For array of arrays, repeat key=value for each element of containing array\n if (Array.isArray(value) && value[0] && Array.isArray(value[0])) {\n return value.map(function (arrayElem) { return encodeParam(key, arrayElem); }).join(\"&\");\n }\n return encodeURIComponent(key) + \"=\" + encodeURIComponent(value);\n}\n/**\n * Encodes the passed object as a query string.\n *\n * @param params An object to be encoded.\n * @returns An encoded query string.\n */\nexport function encodeQueryString(params) {\n var newParams = processParams(params);\n return Object.keys(newParams)\n .map(function (key) {\n return encodeParam(key, newParams[key]);\n })\n .join(\"&\");\n}\n//# sourceMappingURL=encode-query-string.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { processParams, requiresFormData } from \"./process-params\";\nimport { encodeQueryString } from \"./encode-query-string\";\n/**\n * Encodes parameters in a [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData) object in browsers or in a [FormData](https://github.com/form-data/form-data) in Node.js\n *\n * @param params An object to be encoded.\n * @returns The complete [FormData](https://developer.mozilla.org/en-US/docs/Web/API/FormData) object.\n */\nexport function encodeFormData(params, forceFormData) {\n // see https://github.com/Esri/arcgis-rest-js/issues/499 for more info.\n var useFormData = requiresFormData(params) || forceFormData;\n var newParams = processParams(params);\n if (useFormData) {\n var formData_1 = new FormData();\n Object.keys(newParams).forEach(function (key) {\n if (typeof Blob !== \"undefined\" && newParams[key] instanceof Blob) {\n /* To name the Blob:\n 1. look to an alternate request parameter called 'fileName'\n 2. see if 'name' has been tacked onto the Blob manually\n 3. if all else fails, use the request parameter\n */\n var filename = newParams[\"fileName\"] || newParams[key].name || key;\n formData_1.append(key, newParams[key], filename);\n }\n else {\n formData_1.append(key, newParams[key]);\n }\n });\n return formData_1;\n }\n else {\n return encodeQueryString(params);\n }\n}\n//# sourceMappingURL=encode-form-data.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n// TypeScript 2.1 no longer allows you to extend built in types. See https://github.com/Microsoft/TypeScript/issues/12790#issuecomment-265981442\n// and https://github.com/Microsoft/TypeScript-wiki/blob/master/Breaking-Changes.md#extending-built-ins-like-error-array-and-map-may-no-longer-work\n//\n// This code is from MDN https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error#Custom_Error_Types.\nvar ArcGISRequestError = /** @class */ (function () {\n /**\n * Create a new `ArcGISRequestError` object.\n *\n * @param message - The error message from the API\n * @param code - The error code from the API\n * @param response - The original response from the API that caused the error\n * @param url - The original url of the request\n * @param options - The original options and parameters of the request\n */\n function ArcGISRequestError(message, code, response, url, options) {\n message = message || \"UNKNOWN_ERROR\";\n code = code || \"UNKNOWN_ERROR_CODE\";\n this.name = \"ArcGISRequestError\";\n this.message =\n code === \"UNKNOWN_ERROR_CODE\" ? message : code + \": \" + message;\n this.originalMessage = message;\n this.code = code;\n this.response = response;\n this.url = url;\n this.options = options;\n }\n return ArcGISRequestError;\n}());\nexport { ArcGISRequestError };\nArcGISRequestError.prototype = Object.create(Error.prototype);\nArcGISRequestError.prototype.constructor = ArcGISRequestError;\n//# sourceMappingURL=ArcGISRequestError.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Method used internally to surface messages to developers.\n */\nexport function warn(message) {\n if (console && console.warn) {\n console.warn.apply(console, [message]);\n }\n}\n//# sourceMappingURL=warn.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign, __extends } from \"tslib\";\nimport { encodeFormData } from \"./utils/encode-form-data\";\nimport { encodeQueryString } from \"./utils/encode-query-string\";\nimport { requiresFormData } from \"./utils/process-params\";\nimport { ArcGISRequestError } from \"./utils/ArcGISRequestError\";\nimport { warn } from \"./utils/warn\";\nexport var NODEJS_DEFAULT_REFERER_HEADER = \"@esri/arcgis-rest-js\";\nvar DEFAULT_ARCGIS_REQUEST_OPTIONS = {\n httpMethod: \"POST\",\n params: {\n f: \"json\",\n },\n};\n/**\n * Sets the default options that will be passed in **all requests across all `@esri/arcgis-rest-js` modules**.\n *\n *\n * ```js\n * import { setDefaultRequestOptions } from \"@esri/arcgis-rest-request\";\n * setDefaultRequestOptions({\n * authentication: userSession // all requests will use this session by default\n * })\n * ```\n * You should **never** set a default `authentication` when you are in a server side environment where you may be handling requests for many different authenticated users.\n *\n * @param options The default options to pass with every request. Existing default will be overwritten.\n * @param hideWarnings Silence warnings about setting default `authentication` in shared environments.\n */\nexport function setDefaultRequestOptions(options, hideWarnings) {\n if (options.authentication && !hideWarnings) {\n warn(\"You should not set `authentication` as a default in a shared environment such as a web server which will process multiple users requests. You can call `setDefaultRequestOptions` with `true` as a second argument to disable this warning.\");\n }\n DEFAULT_ARCGIS_REQUEST_OPTIONS = options;\n}\nvar ArcGISAuthError = /** @class */ (function (_super) {\n __extends(ArcGISAuthError, _super);\n /**\n * Create a new `ArcGISAuthError` object.\n *\n * @param message - The error message from the API\n * @param code - The error code from the API\n * @param response - The original response from the API that caused the error\n * @param url - The original url of the request\n * @param options - The original options of the request\n */\n function ArcGISAuthError(message, code, response, url, options) {\n if (message === void 0) { message = \"AUTHENTICATION_ERROR\"; }\n if (code === void 0) { code = \"AUTHENTICATION_ERROR_CODE\"; }\n var _this = _super.call(this, message, code, response, url, options) || this;\n _this.name = \"ArcGISAuthError\";\n _this.message =\n code === \"AUTHENTICATION_ERROR_CODE\" ? message : code + \": \" + message;\n return _this;\n }\n ArcGISAuthError.prototype.retry = function (getSession, retryLimit) {\n var _this = this;\n if (retryLimit === void 0) { retryLimit = 3; }\n var tries = 0;\n var retryRequest = function (resolve, reject) {\n getSession(_this.url, _this.options)\n .then(function (session) {\n var newOptions = __assign(__assign({}, _this.options), { authentication: session });\n tries = tries + 1;\n return request(_this.url, newOptions);\n })\n .then(function (response) {\n resolve(response);\n })\n .catch(function (e) {\n if (e.name === \"ArcGISAuthError\" && tries < retryLimit) {\n retryRequest(resolve, reject);\n }\n else if (e.name === \"ArcGISAuthError\" && tries >= retryLimit) {\n reject(_this);\n }\n else {\n reject(e);\n }\n });\n };\n return new Promise(function (resolve, reject) {\n retryRequest(resolve, reject);\n });\n };\n return ArcGISAuthError;\n}(ArcGISRequestError));\nexport { ArcGISAuthError };\n/**\n * Checks for errors in a JSON response from the ArcGIS REST API. If there are no errors, it will return the `data` passed in. If there is an error, it will throw an `ArcGISRequestError` or `ArcGISAuthError`.\n *\n * @param data The response JSON to check for errors.\n * @param url The url of the original request\n * @param params The parameters of the original request\n * @param options The options of the original request\n * @returns The data that was passed in the `data` parameter\n */\nexport function checkForErrors(response, url, params, options, originalAuthError) {\n // this is an error message from billing.arcgis.com backend\n if (response.code >= 400) {\n var message = response.message, code = response.code;\n throw new ArcGISRequestError(message, code, response, url, options);\n }\n // error from ArcGIS Online or an ArcGIS Portal or server instance.\n if (response.error) {\n var _a = response.error, message = _a.message, code = _a.code, messageCode = _a.messageCode;\n var errorCode = messageCode || code || \"UNKNOWN_ERROR_CODE\";\n if (code === 498 ||\n code === 499 ||\n messageCode === \"GWM_0003\" ||\n (code === 400 && message === \"Unable to generate token.\")) {\n if (originalAuthError) {\n throw originalAuthError;\n }\n else {\n throw new ArcGISAuthError(message, errorCode, response, url, options);\n }\n }\n throw new ArcGISRequestError(message, errorCode, response, url, options);\n }\n // error from a status check\n if (response.status === \"failed\" || response.status === \"failure\") {\n var message = void 0;\n var code = \"UNKNOWN_ERROR_CODE\";\n try {\n message = JSON.parse(response.statusMessage).message;\n code = JSON.parse(response.statusMessage).code;\n }\n catch (e) {\n message = response.statusMessage || response.message;\n }\n throw new ArcGISRequestError(message, code, response, url, options);\n }\n return response;\n}\n/**\n * ```js\n * import { request } from '@esri/arcgis-rest-request';\n * //\n * request('https://www.arcgis.com/sharing/rest')\n * .then(response) // response.currentVersion === 5.2\n * //\n * request('https://www.arcgis.com/sharing/rest', {\n * httpMethod: \"GET\"\n * })\n * //\n * request('https://www.arcgis.com/sharing/rest/search', {\n * params: { q: 'parks' }\n * })\n * .then(response) // response.total => 78379\n * ```\n * Generic method for making HTTP requests to ArcGIS REST API endpoints.\n *\n * @param url - The URL of the ArcGIS REST API endpoint.\n * @param requestOptions - Options for the request, including parameters relevant to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function request(url, requestOptions) {\n if (requestOptions === void 0) { requestOptions = { params: { f: \"json\" } }; }\n var options = __assign(__assign(__assign({ httpMethod: \"POST\" }, DEFAULT_ARCGIS_REQUEST_OPTIONS), requestOptions), {\n params: __assign(__assign({}, DEFAULT_ARCGIS_REQUEST_OPTIONS.params), requestOptions.params),\n headers: __assign(__assign({}, DEFAULT_ARCGIS_REQUEST_OPTIONS.headers), requestOptions.headers),\n });\n var missingGlobals = [];\n var recommendedPackages = [];\n // don't check for a global fetch if a custom implementation was passed through\n if (!options.fetch && typeof fetch !== \"undefined\") {\n options.fetch = fetch.bind(Function(\"return this\")());\n }\n else {\n missingGlobals.push(\"`fetch`\");\n recommendedPackages.push(\"`node-fetch`\");\n }\n if (typeof Promise === \"undefined\") {\n missingGlobals.push(\"`Promise`\");\n recommendedPackages.push(\"`es6-promise`\");\n }\n if (typeof FormData === \"undefined\") {\n missingGlobals.push(\"`FormData`\");\n recommendedPackages.push(\"`isomorphic-form-data`\");\n }\n if (!options.fetch ||\n typeof Promise === \"undefined\" ||\n typeof FormData === \"undefined\") {\n throw new Error(\"`arcgis-rest-request` requires a `fetch` implementation and global variables for `Promise` and `FormData` to be present in the global scope. You are missing \" + missingGlobals.join(\", \") + \". We recommend installing the \" + recommendedPackages.join(\", \") + \" modules at the root of your application to add these to the global scope. See https://bit.ly/2KNwWaJ for more info.\");\n }\n var httpMethod = options.httpMethod, authentication = options.authentication, rawResponse = options.rawResponse;\n var params = __assign({ f: \"json\" }, options.params);\n var originalAuthError = null;\n var fetchOptions = {\n method: httpMethod,\n /* ensures behavior mimics XMLHttpRequest.\n needed to support sending IWA cookies */\n credentials: options.credentials || \"same-origin\",\n };\n // the /oauth2/platformSelf route will add X-Esri-Auth-Client-Id header\n // and that request needs to send cookies cross domain\n // so we need to set the credentials to \"include\"\n if (options.headers &&\n options.headers[\"X-Esri-Auth-Client-Id\"] &&\n url.indexOf(\"/oauth2/platformSelf\") > -1) {\n fetchOptions.credentials = \"include\";\n }\n return (authentication\n ? authentication.getToken(url, { fetch: options.fetch }).catch(function (err) {\n /**\n * append original request url and requestOptions\n * to the error thrown by getToken()\n * to assist with retrying\n */\n err.url = url;\n err.options = options;\n /**\n * if an attempt is made to talk to an unfederated server\n * first try the request anonymously. if a 'token required'\n * error is thrown, throw the UNFEDERATED error then.\n */\n originalAuthError = err;\n return Promise.resolve(\"\");\n })\n : Promise.resolve(\"\"))\n .then(function (token) {\n if (token.length) {\n params.token = token;\n }\n if (authentication && authentication.getDomainCredentials) {\n fetchOptions.credentials = authentication.getDomainCredentials(url);\n }\n // Custom headers to add to request. IRequestOptions.headers with merge over requestHeaders.\n var requestHeaders = {};\n if (fetchOptions.method === \"GET\") {\n // Prevents token from being passed in query params when hideToken option is used.\n /* istanbul ignore if - window is always defined in a browser. Test case is covered by Jasmine in node test */\n if (params.token &&\n options.hideToken &&\n // Sharing API does not support preflight check required by modern browsers https://developer.mozilla.org/en-US/docs/Glossary/Preflight_request\n typeof window === \"undefined\") {\n requestHeaders[\"X-Esri-Authorization\"] = \"Bearer \" + params.token;\n delete params.token;\n }\n // encode the parameters into the query string\n var queryParams = encodeQueryString(params);\n // dont append a '?' unless parameters are actually present\n var urlWithQueryString = queryParams === \"\" ? url : url + \"?\" + encodeQueryString(params);\n if (\n // This would exceed the maximum length for URLs specified by the consumer and requires POST\n (options.maxUrlLength &&\n urlWithQueryString.length > options.maxUrlLength) ||\n // Or if the customer requires the token to be hidden and it has not already been hidden in the header (for browsers)\n (params.token && options.hideToken)) {\n // the consumer specified a maximum length for URLs\n // and this would exceed it, so use post instead\n fetchOptions.method = \"POST\";\n // If the token was already added as a Auth header, add the token back to body with other params instead of header\n if (token.length && options.hideToken) {\n params.token = token;\n // Remove existing header that was added before url query length was checked\n delete requestHeaders[\"X-Esri-Authorization\"];\n }\n }\n else {\n // just use GET\n url = urlWithQueryString;\n }\n }\n /* updateResources currently requires FormData even when the input parameters dont warrant it.\n https://developers.arcgis.com/rest/users-groups-and-items/update-resources.htm\n see https://github.com/Esri/arcgis-rest-js/pull/500 for more info. */\n var forceFormData = new RegExp(\"/items/.+/updateResources\").test(url);\n if (fetchOptions.method === \"POST\") {\n fetchOptions.body = encodeFormData(params, forceFormData);\n }\n // Mixin headers from request options\n fetchOptions.headers = __assign(__assign({}, requestHeaders), options.headers);\n /* istanbul ignore next - karma reports coverage on browser tests only */\n if (typeof window === \"undefined\" && !fetchOptions.headers.referer) {\n fetchOptions.headers.referer = NODEJS_DEFAULT_REFERER_HEADER;\n }\n /* istanbul ignore else blob responses are difficult to make cross platform we will just have to trust the isomorphic fetch will do its job */\n if (!requiresFormData(params) && !forceFormData) {\n fetchOptions.headers[\"Content-Type\"] =\n \"application/x-www-form-urlencoded\";\n }\n return options.fetch(url, fetchOptions);\n })\n .then(function (response) {\n if (!response.ok) {\n // server responded w/ an actual error (404, 500, etc)\n var status_1 = response.status, statusText = response.statusText;\n throw new ArcGISRequestError(statusText, \"HTTP \" + status_1, response, url, options);\n }\n if (rawResponse) {\n return response;\n }\n switch (params.f) {\n case \"json\":\n return response.json();\n case \"geojson\":\n return response.json();\n case \"html\":\n return response.text();\n case \"text\":\n return response.text();\n /* istanbul ignore next blob responses are difficult to make cross platform we will just have to trust that isomorphic fetch will do its job */\n default:\n return response.blob();\n }\n })\n .then(function (data) {\n if ((params.f === \"json\" || params.f === \"geojson\") && !rawResponse) {\n var response = checkForErrors(data, url, params, options, originalAuthError);\n if (originalAuthError) {\n /* If the request was made to an unfederated service that\n didn't require authentication, add the base url and a dummy token\n to the list of trusted servers to avoid another federation check\n in the event of a repeat request */\n var truncatedUrl = url\n .toLowerCase()\n .split(/\\/rest(\\/admin)?\\/services\\//)[0];\n options.authentication.federatedServers[truncatedUrl] = {\n token: [],\n // default to 24 hours\n expires: new Date(Date.now() + 86400 * 1000),\n };\n originalAuthError = null;\n }\n return response;\n }\n else {\n return data;\n }\n });\n}\n//# sourceMappingURL=request.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\n/**\n * Helper for methods with lots of first order request options to pass through as request parameters.\n */\nexport function appendCustomParams(customOptions, keys, baseOptions) {\n var requestOptionsKeys = [\n \"params\",\n \"httpMethod\",\n \"rawResponse\",\n \"authentication\",\n \"portal\",\n \"fetch\",\n \"maxUrlLength\",\n \"headers\"\n ];\n var options = __assign(__assign({ params: {} }, baseOptions), customOptions);\n // merge all keys in customOptions into options.params\n options.params = keys.reduce(function (value, key) {\n if (customOptions[key] || typeof customOptions[key] === \"boolean\") {\n value[key] = customOptions[key];\n }\n return value;\n }, options.params);\n // now remove all properties in options that don't exist in IRequestOptions\n return requestOptionsKeys.reduce(function (value, key) {\n if (options[key]) {\n value[key] = options[key];\n }\n return value;\n }, {});\n}\n//# sourceMappingURL=append-custom-params.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Helper method to ensure that user supplied urls don't include whitespace or a trailing slash.\n */\nexport function cleanUrl(url) {\n // Guard so we don't try to trim something that's not a string\n if (typeof url !== \"string\") {\n return url;\n }\n // trim leading and trailing spaces, but not spaces inside the url\n url = url.trim();\n // remove the trailing slash to the url if one was included\n if (url[url.length - 1] === \"/\") {\n url = url.slice(0, -1);\n }\n return url;\n}\n//# sourceMappingURL=clean-url.js.map","/* Copyright (c) 2017-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nexport function decodeParam(param) {\n var _a = param.split(\"=\"), key = _a[0], value = _a[1];\n return { key: decodeURIComponent(key), value: decodeURIComponent(value) };\n}\n/**\n * Decodes the passed query string as an object.\n *\n * @param query A string to be decoded.\n * @returns A decoded query param object.\n */\nexport function decodeQueryString(query) {\n return query\n .replace(/^#/, \"\")\n .split(\"&\")\n .reduce(function (acc, entry) {\n var _a = decodeParam(entry), key = _a.key, value = _a.value;\n acc[key] = value;\n return acc;\n }, {});\n}\n//# sourceMappingURL=decode-query-string.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nexport function fetchToken(url, requestOptions) {\n var options = requestOptions;\n // we generate a response, so we can't return the raw response\n options.rawResponse = false;\n return request(url, options).then(function (response) {\n var r = {\n token: response.access_token,\n username: response.username,\n expires: new Date(\n // convert seconds in response to milliseconds and add the value to the current time to calculate a static expiration timestamp\n Date.now() + (response.expires_in * 1000 - 1000)),\n ssl: response.ssl === true\n };\n if (response.refresh_token) {\n r.refreshToken = response.refresh_token;\n }\n return r;\n });\n}\n//# sourceMappingURL=fetch-token.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request, NODEJS_DEFAULT_REFERER_HEADER, } from \"@esri/arcgis-rest-request\";\nexport function generateToken(url, requestOptions) {\n var options = requestOptions;\n /* istanbul ignore else */\n if (typeof window !== \"undefined\" &&\n window.location &&\n window.location.host) {\n options.params.referer = window.location.host;\n }\n else {\n options.params.referer = NODEJS_DEFAULT_REFERER_HEADER;\n }\n return request(url, options);\n}\n//# sourceMappingURL=generate-token.js.map","import { cleanUrl } from \"@esri/arcgis-rest-request\";\n/**\n * Used to test if a URL is an ArcGIS Online URL\n */\nvar arcgisOnlineUrlRegex = /^https?:\\/\\/(\\S+)\\.arcgis\\.com.+/;\n/**\n * Used to test if a URL is production ArcGIS Online Portal\n */\nvar arcgisOnlinePortalRegex = /^https?:\\/\\/(dev|devext|qa|qaext|www)\\.arcgis\\.com\\/sharing\\/rest+/;\n/**\n * Used to test if a URL is an ArcGIS Online Organization Portal\n */\nvar arcgisOnlineOrgPortalRegex = /^https?:\\/\\/(?:[a-z0-9-]+\\.maps(dev|devext|qa|qaext)?)?.arcgis\\.com\\/sharing\\/rest/;\nexport function isOnline(url) {\n return arcgisOnlineUrlRegex.test(url);\n}\nexport function normalizeOnlinePortalUrl(portalUrl) {\n if (!arcgisOnlineUrlRegex.test(portalUrl)) {\n return portalUrl;\n }\n switch (getOnlineEnvironment(portalUrl)) {\n case \"dev\":\n return \"https://devext.arcgis.com/sharing/rest\";\n case \"qa\":\n return \"https://qaext.arcgis.com/sharing/rest\";\n default:\n return \"https://www.arcgis.com/sharing/rest\";\n }\n}\nexport function getOnlineEnvironment(url) {\n if (!arcgisOnlineUrlRegex.test(url)) {\n return null;\n }\n var match = url.match(arcgisOnlineUrlRegex);\n var subdomain = match[1].split(\".\").pop();\n if (subdomain.includes(\"dev\")) {\n return \"dev\";\n }\n if (subdomain.includes(\"qa\")) {\n return \"qa\";\n }\n return \"production\";\n}\nexport function isFederated(owningSystemUrl, portalUrl) {\n var normalizedPortalUrl = cleanUrl(normalizeOnlinePortalUrl(portalUrl)).replace(/https?:\\/\\//, \"\");\n var normalizedOwningSystemUrl = cleanUrl(owningSystemUrl).replace(/https?:\\/\\//, \"\");\n return new RegExp(normalizedOwningSystemUrl, \"i\").test(normalizedPortalUrl);\n}\nexport function canUseOnlineToken(portalUrl, requestUrl) {\n var portalIsOnline = isOnline(portalUrl);\n var requestIsOnline = isOnline(requestUrl);\n var portalEnv = getOnlineEnvironment(portalUrl);\n var requestEnv = getOnlineEnvironment(requestUrl);\n if (portalIsOnline && requestIsOnline && portalEnv === requestEnv) {\n return true;\n }\n return false;\n}\n//# sourceMappingURL=federation-utils.js.map","/* Copyright (c) 2018-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\n/**\n * Validates that the user has access to the application\n * and if they user should be presented a \"View Only\" mode\n *\n * This is only needed/valid for Esri applications that are \"licensed\"\n * and shipped in ArcGIS Online or ArcGIS Enterprise. Most custom applications\n * should not need or use this.\n *\n * ```js\n * import { validateAppAccess } from '@esri/arcgis-rest-auth';\n *\n * return validateAppAccess('your-token', 'theClientId')\n * .then((result) => {\n * if (!result.value) {\n * // redirect or show some other ui\n * } else {\n * if (result.viewOnlyUserTypeApp) {\n * // use this to inform your app to show a \"View Only\" mode\n * }\n * }\n * })\n * .catch((err) => {\n * // two possible errors\n * // invalid clientId: {\"error\":{\"code\":400,\"messageCode\":\"GWM_0007\",\"message\":\"Invalid request\",\"details\":[]}}\n * // invalid token: {\"error\":{\"code\":498,\"message\":\"Invalid token.\",\"details\":[]}}\n * })\n * ```\n *\n * Note: This is only usable by Esri applications hosted on *arcgis.com, *esri.com or within\n * an ArcGIS Enterprise installation. Custom applications can not use this.\n *\n * @param token platform token\n * @param clientId application client id\n * @param portal Optional\n */\nexport function validateAppAccess(token, clientId, portal) {\n if (portal === void 0) { portal = \"https://www.arcgis.com/sharing/rest\"; }\n var url = portal + \"/oauth2/validateAppAccess\";\n var ro = {\n method: \"POST\",\n params: {\n f: \"json\",\n client_id: clientId,\n token: token,\n },\n };\n return request(url, ro);\n}\n//# sourceMappingURL=validate-app-access.js.map","/* Copyright (c) 2017-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, ArcGISAuthError, cleanUrl, encodeQueryString, decodeQueryString, } from \"@esri/arcgis-rest-request\";\nimport { generateToken } from \"./generate-token\";\nimport { fetchToken } from \"./fetch-token\";\nimport { canUseOnlineToken, isFederated } from \"./federation-utils\";\nimport { validateAppAccess } from \"./validate-app-access\";\nfunction defer() {\n var deferred = {\n promise: null,\n resolve: null,\n reject: null,\n };\n deferred.promise = new Promise(function (resolve, reject) {\n deferred.resolve = resolve;\n deferred.reject = reject;\n });\n return deferred;\n}\n/**\n * ```js\n * import { UserSession } from '@esri/arcgis-rest-auth';\n * UserSession.beginOAuth2({\n * // register an app of your own to create a unique clientId\n * clientId: \"abc123\",\n * redirectUri: 'https://yourapp.com/authenticate.html'\n * })\n * .then(session)\n * // or\n * new UserSession({\n * username: \"jsmith\",\n * password: \"123456\"\n * })\n * // or\n * UserSession.deserialize(cache)\n * ```\n * Used to authenticate both ArcGIS Online and ArcGIS Enterprise users. `UserSession` includes helper methods for [OAuth 2.0](/arcgis-rest-js/guides/browser-authentication/) in both browser and server applications.\n */\nvar UserSession = /** @class */ (function () {\n function UserSession(options) {\n this.clientId = options.clientId;\n this._refreshToken = options.refreshToken;\n this._refreshTokenExpires = options.refreshTokenExpires;\n this.username = options.username;\n this.password = options.password;\n this._token = options.token;\n this._tokenExpires = options.tokenExpires;\n this.portal = options.portal\n ? cleanUrl(options.portal)\n : \"https://www.arcgis.com/sharing/rest\";\n this.ssl = options.ssl;\n this.provider = options.provider || \"arcgis\";\n this.tokenDuration = options.tokenDuration || 20160;\n this.redirectUri = options.redirectUri;\n this.refreshTokenTTL = options.refreshTokenTTL || 20160;\n this.server = options.server;\n this.federatedServers = {};\n this.trustedDomains = [];\n // if a non-federated server was passed explicitly, it should be trusted.\n if (options.server) {\n // if the url includes more than '/arcgis/', trim the rest\n var root = this.getServerRootUrl(options.server);\n this.federatedServers[root] = {\n token: options.token,\n expires: options.tokenExpires,\n };\n }\n this._pendingTokenRequests = {};\n }\n Object.defineProperty(UserSession.prototype, \"token\", {\n /**\n * The current ArcGIS Online or ArcGIS Enterprise `token`.\n */\n get: function () {\n return this._token;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"tokenExpires\", {\n /**\n * The expiration time of the current `token`.\n */\n get: function () {\n return this._tokenExpires;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"refreshToken\", {\n /**\n * The current token to ArcGIS Online or ArcGIS Enterprise.\n */\n get: function () {\n return this._refreshToken;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"refreshTokenExpires\", {\n /**\n * The expiration time of the current `refreshToken`.\n */\n get: function () {\n return this._refreshTokenExpires;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(UserSession.prototype, \"trustedServers\", {\n /**\n * Deprecated, use `federatedServers` instead.\n *\n * @deprecated\n */\n get: function () {\n console.log(\"DEPRECATED: use federatedServers instead\");\n return this.federatedServers;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * Begins a new browser-based OAuth 2.0 sign in. If `options.popup` is `true` the\n * authentication window will open in a new tab/window and the function will return\n * Promise&lt;UserSession&gt;. Otherwise, the user will be redirected to the\n * authorization page in their current tab/window and the function will return `undefined`.\n *\n * @browserOnly\n */\n /* istanbul ignore next */\n UserSession.beginOAuth2 = function (options, win) {\n if (win === void 0) { win = window; }\n if (options.duration) {\n console.log(\"DEPRECATED: 'duration' is deprecated - use 'expiration' instead\");\n }\n var _a = __assign({\n portal: \"https://www.arcgis.com/sharing/rest\",\n provider: \"arcgis\",\n expiration: 20160,\n popup: true,\n popupWindowFeatures: \"height=400,width=600,menubar=no,location=yes,resizable=yes,scrollbars=yes,status=yes\",\n state: options.clientId,\n locale: \"\",\n }, options), portal = _a.portal, provider = _a.provider, clientId = _a.clientId, expiration = _a.expiration, redirectUri = _a.redirectUri, popup = _a.popup, popupWindowFeatures = _a.popupWindowFeatures, state = _a.state, locale = _a.locale, params = _a.params;\n var url;\n if (provider === \"arcgis\") {\n url = portal + \"/oauth2/authorize?client_id=\" + clientId + \"&response_type=token&expiration=\" + (options.duration || expiration) + \"&redirect_uri=\" + encodeURIComponent(redirectUri) + \"&state=\" + state + \"&locale=\" + locale;\n }\n else {\n url = portal + \"/oauth2/social/authorize?client_id=\" + clientId + \"&socialLoginProviderName=\" + provider + \"&autoAccountCreateForSocial=true&response_type=token&expiration=\" + (options.duration || expiration) + \"&redirect_uri=\" + encodeURIComponent(redirectUri) + \"&state=\" + state + \"&locale=\" + locale;\n }\n // append additional params\n if (params) {\n url = url + \"&\" + encodeQueryString(params);\n }\n if (!popup) {\n win.location.href = url;\n return undefined;\n }\n var session = defer();\n win[\"__ESRI_REST_AUTH_HANDLER_\" + clientId] = function (errorString, oauthInfoString) {\n if (errorString) {\n var error = JSON.parse(errorString);\n session.reject(new ArcGISAuthError(error.errorMessage, error.error));\n return;\n }\n if (oauthInfoString) {\n var oauthInfo = JSON.parse(oauthInfoString);\n session.resolve(new UserSession({\n clientId: clientId,\n portal: portal,\n ssl: oauthInfo.ssl,\n token: oauthInfo.token,\n tokenExpires: new Date(oauthInfo.expires),\n username: oauthInfo.username,\n }));\n }\n };\n win.open(url, \"oauth-window\", popupWindowFeatures);\n return session.promise;\n };\n /**\n * Completes a browser-based OAuth 2.0 sign in. If `options.popup` is `true` the user\n * will be returned to the previous window. Otherwise a new `UserSession`\n * will be returned. You must pass the same values for `options.popup` and\n * `options.portal` as you used in `beginOAuth2()`.\n *\n * @browserOnly\n */\n /* istanbul ignore next */\n UserSession.completeOAuth2 = function (options, win) {\n if (win === void 0) { win = window; }\n var _a = __assign({ portal: \"https://www.arcgis.com/sharing/rest\", popup: true }, options), portal = _a.portal, clientId = _a.clientId, popup = _a.popup;\n function completeSignIn(error, oauthInfo) {\n try {\n var handlerFn = void 0;\n var handlerFnName = \"__ESRI_REST_AUTH_HANDLER_\" + clientId;\n if (popup) {\n // Guard b/c IE does not support window.opener\n if (win.opener) {\n if (win.opener.parent && win.opener.parent[handlerFnName]) {\n handlerFn = win.opener.parent[handlerFnName];\n }\n else if (win.opener && win.opener[handlerFnName]) {\n // support pop-out oauth from within an iframe\n handlerFn = win.opener[handlerFnName];\n }\n }\n else {\n // IE\n if (win !== win.parent && win.parent && win.parent[handlerFnName]) {\n handlerFn = win.parent[handlerFnName];\n }\n }\n // if we have a handler fn, call it and close the window\n if (handlerFn) {\n handlerFn(error ? JSON.stringify(error) : undefined, JSON.stringify(oauthInfo));\n win.close();\n return undefined;\n }\n }\n }\n catch (e) {\n throw new ArcGISAuthError(\"Unable to complete authentication. It's possible you specified popup based oAuth2 but no handler from \\\"beginOAuth2()\\\" present. This generally happens because the \\\"popup\\\" option differs between \\\"beginOAuth2()\\\" and \\\"completeOAuth2()\\\".\");\n }\n if (error) {\n throw new ArcGISAuthError(error.errorMessage, error.error);\n }\n return new UserSession({\n clientId: clientId,\n portal: portal,\n ssl: oauthInfo.ssl,\n token: oauthInfo.token,\n tokenExpires: oauthInfo.expires,\n username: oauthInfo.username,\n });\n }\n var params = decodeQueryString(win.location.hash);\n if (!params.access_token) {\n var error = void 0;\n var errorMessage = \"Unknown error\";\n if (params.error) {\n error = params.error;\n errorMessage = params.error_description;\n }\n return completeSignIn({ error: error, errorMessage: errorMessage });\n }\n var token = params.access_token;\n var expires = new Date(Date.now() + parseInt(params.expires_in, 10) * 1000 - 60 * 1000);\n var username = params.username;\n var ssl = params.ssl === \"true\";\n return completeSignIn(undefined, {\n token: token,\n expires: expires,\n ssl: ssl,\n username: username,\n });\n };\n /**\n * Request session information from the parent application\n *\n * When an application is embedded into another application via an IFrame, the embedded app can\n * use `window.postMessage` to request credentials from the host application. This function wraps\n * that behavior.\n *\n * The ArcGIS API for Javascript has this built into the Identity Manager as of the 4.19 release.\n *\n * Note: The parent application will not respond if the embedded app's origin is not:\n * - the same origin as the parent or *.arcgis.com (JSAPI)\n * - in the list of valid child origins (REST-JS)\n *\n *\n * @param parentOrigin origin of the parent frame. Passed into the embedded application as `parentOrigin` query param\n * @browserOnly\n */\n UserSession.fromParent = function (parentOrigin, win) {\n /* istanbul ignore next: must pass in a mockwindow for tests so we can't cover the other branch */\n if (!win && window) {\n win = window;\n }\n // Declare handler outside of promise scope so we can detach it\n var handler;\n // return a promise that will resolve when the handler receives\n // session information from the correct origin\n return new Promise(function (resolve, reject) {\n // create an event handler that just wraps the parentMessageHandler\n handler = function (event) {\n // ensure we only listen to events from the parent\n if (event.source === win.parent && event.data) {\n try {\n return resolve(UserSession.parentMessageHandler(event));\n }\n catch (err) {\n return reject(err);\n }\n }\n };\n // add listener\n win.addEventListener(\"message\", handler, false);\n win.parent.postMessage({ type: \"arcgis:auth:requestCredential\" }, parentOrigin);\n }).then(function (session) {\n win.removeEventListener(\"message\", handler, false);\n return session;\n });\n };\n /**\n * Begins a new server-based OAuth 2.0 sign in. This will redirect the user to\n * the ArcGIS Online or ArcGIS Enterprise authorization page.\n *\n * @nodeOnly\n */\n UserSession.authorize = function (options, response) {\n if (options.duration) {\n console.log(\"DEPRECATED: 'duration' is deprecated - use 'expiration' instead\");\n }\n var _a = __assign({ portal: \"https://arcgis.com/sharing/rest\", expiration: 20160 }, options), portal = _a.portal, clientId = _a.clientId, expiration = _a.expiration, redirectUri = _a.redirectUri;\n response.writeHead(301, {\n Location: portal + \"/oauth2/authorize?client_id=\" + clientId + \"&expiration=\" + (options.duration || expiration) + \"&response_type=code&redirect_uri=\" + encodeURIComponent(redirectUri),\n });\n response.end();\n };\n /**\n * Completes the server-based OAuth 2.0 sign in process by exchanging the `authorizationCode`\n * for a `access_token`.\n *\n * @nodeOnly\n */\n UserSession.exchangeAuthorizationCode = function (options, authorizationCode) {\n var _a = __assign({\n portal: \"https://www.arcgis.com/sharing/rest\",\n refreshTokenTTL: 20160,\n }, options), portal = _a.portal, clientId = _a.clientId, redirectUri = _a.redirectUri, refreshTokenTTL = _a.refreshTokenTTL;\n return fetchToken(portal + \"/oauth2/token\", {\n params: {\n grant_type: \"authorization_code\",\n client_id: clientId,\n redirect_uri: redirectUri,\n code: authorizationCode,\n },\n }).then(function (response) {\n return new UserSession({\n clientId: clientId,\n portal: portal,\n ssl: response.ssl,\n redirectUri: redirectUri,\n refreshToken: response.refreshToken,\n refreshTokenTTL: refreshTokenTTL,\n refreshTokenExpires: new Date(Date.now() + (refreshTokenTTL - 1) * 60 * 1000),\n token: response.token,\n tokenExpires: response.expires,\n username: response.username,\n });\n });\n };\n UserSession.deserialize = function (str) {\n var options = JSON.parse(str);\n return new UserSession({\n clientId: options.clientId,\n refreshToken: options.refreshToken,\n refreshTokenExpires: new Date(options.refreshTokenExpires),\n username: options.username,\n password: options.password,\n token: options.token,\n tokenExpires: new Date(options.tokenExpires),\n portal: options.portal,\n ssl: options.ssl,\n tokenDuration: options.tokenDuration,\n redirectUri: options.redirectUri,\n refreshTokenTTL: options.refreshTokenTTL,\n });\n };\n /**\n * Translates authentication from the format used in the [ArcGIS API for JavaScript](https://developers.arcgis.com/javascript/).\n *\n * ```js\n * UserSession.fromCredential({\n * userId: \"jsmith\",\n * token: \"secret\"\n * });\n * ```\n *\n * @returns UserSession\n */\n UserSession.fromCredential = function (credential) {\n // At ArcGIS Online 9.1, credentials no longer include the ssl and expires properties\n // Here, we provide default values for them to cover this condition\n var ssl = typeof credential.ssl !== \"undefined\" ? credential.ssl : true;\n var expires = credential.expires || Date.now() + 7200000; /* 2 hours */\n return new UserSession({\n portal: credential.server.includes(\"sharing/rest\")\n ? credential.server\n : credential.server + \"/sharing/rest\",\n ssl: ssl,\n token: credential.token,\n username: credential.userId,\n tokenExpires: new Date(expires),\n });\n };\n /**\n * Handle the response from the parent\n * @param event DOM Event\n */\n UserSession.parentMessageHandler = function (event) {\n if (event.data.type === \"arcgis:auth:credential\") {\n return UserSession.fromCredential(event.data.credential);\n }\n if (event.data.type === \"arcgis:auth:error\") {\n var err = new Error(event.data.error.message);\n err.name = event.data.error.name;\n throw err;\n }\n else {\n throw new Error(\"Unknown message type.\");\n }\n };\n /**\n * Returns authentication in a format useable in the [ArcGIS API for JavaScript](https://developers.arcgis.com/javascript/).\n *\n * ```js\n * esriId.registerToken(session.toCredential());\n * ```\n *\n * @returns ICredential\n */\n UserSession.prototype.toCredential = function () {\n return {\n expires: this.tokenExpires.getTime(),\n server: this.portal,\n ssl: this.ssl,\n token: this.token,\n userId: this.username,\n };\n };\n /**\n * Returns information about the currently logged in [user](https://developers.arcgis.com/rest/users-groups-and-items/user.htm). Subsequent calls will *not* result in additional web traffic.\n *\n * ```js\n * session.getUser()\n * .then(response => {\n * console.log(response.role); // \"org_admin\"\n * })\n * ```\n *\n * @param requestOptions - Options for the request. NOTE: `rawResponse` is not supported by this operation.\n * @returns A Promise that will resolve with the data from the response.\n */\n UserSession.prototype.getUser = function (requestOptions) {\n var _this = this;\n if (this._pendingUserRequest) {\n return this._pendingUserRequest;\n }\n else if (this._user) {\n return Promise.resolve(this._user);\n }\n else {\n var url = this.portal + \"/community/self\";\n var options = __assign(__assign({ httpMethod: \"GET\", authentication: this }, requestOptions), { rawResponse: false });\n this._pendingUserRequest = request(url, options).then(function (response) {\n _this._user = response;\n _this._pendingUserRequest = null;\n return response;\n });\n return this._pendingUserRequest;\n }\n };\n /**\n * Returns information about the currently logged in user's [portal](https://developers.arcgis.com/rest/users-groups-and-items/portal-self.htm). Subsequent calls will *not* result in additional web traffic.\n *\n * ```js\n * session.getPortal()\n * .then(response => {\n * console.log(portal.name); // \"City of ...\"\n * })\n * ```\n *\n * @param requestOptions - Options for the request. NOTE: `rawResponse` is not supported by this operation.\n * @returns A Promise that will resolve with the data from the response.\n */\n UserSession.prototype.getPortal = function (requestOptions) {\n var _this = this;\n if (this._pendingPortalRequest) {\n return this._pendingPortalRequest;\n }\n else if (this._portalInfo) {\n return Promise.resolve(this._portalInfo);\n }\n else {\n var url = this.portal + \"/portals/self\";\n var options = __assign(__assign({ httpMethod: \"GET\", authentication: this }, requestOptions), { rawResponse: false });\n this._pendingPortalRequest = request(url, options).then(function (response) {\n _this._portalInfo = response;\n _this._pendingPortalRequest = null;\n return response;\n });\n return this._pendingPortalRequest;\n }\n };\n /**\n * Returns the username for the currently logged in [user](https://developers.arcgis.com/rest/users-groups-and-items/user.htm). Subsequent calls will *not* result in additional web traffic. This is also used internally when a username is required for some requests but is not present in the options.\n *\n * * ```js\n * session.getUsername()\n * .then(response => {\n * console.log(response); // \"casey_jones\"\n * })\n * ```\n */\n UserSession.prototype.getUsername = function () {\n if (this.username) {\n return Promise.resolve(this.username);\n }\n else if (this._user) {\n return Promise.resolve(this._user.username);\n }\n else {\n return this.getUser().then(function (user) {\n return user.username;\n });\n }\n };\n /**\n * Gets an appropriate token for the given URL. If `portal` is ArcGIS Online and\n * the request is to an ArcGIS Online domain `token` will be used. If the request\n * is to the current `portal` the current `token` will also be used. However if\n * the request is to an unknown server we will validate the server with a request\n * to our current `portal`.\n */\n UserSession.prototype.getToken = function (url, requestOptions) {\n if (canUseOnlineToken(this.portal, url)) {\n return this.getFreshToken(requestOptions);\n }\n else if (new RegExp(this.portal, \"i\").test(url)) {\n return this.getFreshToken(requestOptions);\n }\n else {\n return this.getTokenForServer(url, requestOptions);\n }\n };\n /**\n * Get application access information for the current user\n * see `validateAppAccess` function for details\n *\n * @param clientId application client id\n */\n UserSession.prototype.validateAppAccess = function (clientId) {\n return this.getToken(this.portal).then(function (token) {\n return validateAppAccess(token, clientId);\n });\n };\n UserSession.prototype.toJSON = function () {\n return {\n clientId: this.clientId,\n refreshToken: this.refreshToken,\n refreshTokenExpires: this.refreshTokenExpires,\n username: this.username,\n password: this.password,\n token: this.token,\n tokenExpires: this.tokenExpires,\n portal: this.portal,\n ssl: this.ssl,\n tokenDuration: this.tokenDuration,\n redirectUri: this.redirectUri,\n refreshTokenTTL: this.refreshTokenTTL,\n };\n };\n UserSession.prototype.serialize = function () {\n return JSON.stringify(this);\n };\n /**\n * For a \"Host\" app that embeds other platform apps via iframes, after authenticating the user\n * and creating a UserSession, the app can then enable \"post message\" style authentication by calling\n * this method.\n *\n * Internally this adds an event listener on window for the `message` event\n *\n * @param validChildOrigins Array of origins that are allowed to request authentication from the host app\n */\n UserSession.prototype.enablePostMessageAuth = function (validChildOrigins, win) {\n /* istanbul ignore next: must pass in a mockwindow for tests so we can't cover the other branch */\n if (!win && window) {\n win = window;\n }\n this._hostHandler = this.createPostMessageHandler(validChildOrigins);\n win.addEventListener(\"message\", this._hostHandler, false);\n };\n /**\n * For a \"Host\" app that has embedded other platform apps via iframes, when the host needs\n * to transition routes, it should call `UserSession.disablePostMessageAuth()` to remove\n * the event listener and prevent memory leaks\n */\n UserSession.prototype.disablePostMessageAuth = function (win) {\n /* istanbul ignore next: must pass in a mockwindow for tests so we can't cover the other branch */\n if (!win && window) {\n win = window;\n }\n win.removeEventListener(\"message\", this._hostHandler, false);\n };\n /**\n * Manually refreshes the current `token` and `tokenExpires`.\n */\n UserSession.prototype.refreshSession = function (requestOptions) {\n // make sure subsequent calls to getUser() don't returned cached metadata\n this._user = null;\n if (this.username && this.password) {\n return this.refreshWithUsernameAndPassword(requestOptions);\n }\n if (this.clientId && this.refreshToken) {\n return this.refreshWithRefreshToken();\n }\n return Promise.reject(new ArcGISAuthError(\"Unable to refresh token.\"));\n };\n /**\n * Determines the root of the ArcGIS Server or Portal for a given URL.\n *\n * @param url the URl to determine the root url for.\n */\n UserSession.prototype.getServerRootUrl = function (url) {\n var root = cleanUrl(url).split(/\\/rest(\\/admin)?\\/services(?:\\/|#|\\?|$)/)[0];\n var _a = root.match(/(https?:\\/\\/)(.+)/), match = _a[0], protocol = _a[1], domainAndPath = _a[2];\n var _b = domainAndPath.split(\"/\"), domain = _b[0], path = _b.slice(1);\n // only the domain is lowercased because in some cases an org id might be\n // in the path which cannot be lowercased.\n return \"\" + protocol + domain.toLowerCase() + \"/\" + path.join(\"/\");\n };\n /**\n * Returns the proper [`credentials`] option for `fetch` for a given domain.\n * See [trusted server](https://enterprise.arcgis.com/en/portal/latest/administer/windows/configure-security.htm#ESRI_SECTION1_70CC159B3540440AB325BE5D89DBE94A).\n * Used internally by underlying request methods to add support for specific security considerations.\n *\n * @param url The url of the request\n * @returns \"include\" or \"same-origin\"\n */\n UserSession.prototype.getDomainCredentials = function (url) {\n if (!this.trustedDomains || !this.trustedDomains.length) {\n return \"same-origin\";\n }\n return this.trustedDomains.some(function (domainWithProtocol) {\n return url.startsWith(domainWithProtocol);\n })\n ? \"include\"\n : \"same-origin\";\n };\n /**\n * Return a function that closes over the validOrigins array and\n * can be used as an event handler for the `message` event\n *\n * @param validOrigins Array of valid origins\n */\n UserSession.prototype.createPostMessageHandler = function (validOrigins) {\n var _this = this;\n // return a function that closes over the validOrigins and\n // has access to the credential\n return function (event) {\n // Verify that the origin is valid\n // Note: do not use regex's here. validOrigins is an array so we're checking that the event's origin\n // is in the array via exact match. More info about avoiding postMessage xss issues here\n // https://jlajara.gitlab.io/web/2020/07/17/Dom_XSS_PostMessage_2.html#tipsbypasses-in-postmessage-vulnerabilities\n var isValidOrigin = validOrigins.indexOf(event.origin) > -1;\n // JSAPI handles this slightly differently - instead of checking a list, it will respond if\n // event.origin === window.location.origin || event.origin.endsWith('.arcgis.com')\n // For Hub, and to enable cross domain debugging with port's in urls, we are opting to\n // use a list of valid origins\n // Ensure the message type is something we want to handle\n var isValidType = event.data.type === \"arcgis:auth:requestCredential\";\n var isTokenValid = _this.tokenExpires.getTime() > Date.now();\n if (isValidOrigin && isValidType) {\n var msg = {};\n if (isTokenValid) {\n var credential = _this.toCredential();\n // arcgis:auth:error with {name: \"\", message: \"\"}\n // the following line allows us to conform to our spec without changing other depended-on functionality\n // https://github.com/Esri/arcgis-rest-js/blob/master/packages/arcgis-rest-auth/post-message-auth-spec.md#arcgisauthcredential\n credential.server = credential.server.replace(\"/sharing/rest\", \"\");\n msg = { type: \"arcgis:auth:credential\", credential: credential };\n }\n else {\n // Return an error\n msg = {\n type: \"arcgis:auth:error\",\n error: {\n name: \"tokenExpiredError\",\n message: \"Session token was expired, and not returned to the child application\",\n },\n };\n }\n event.source.postMessage(msg, event.origin);\n }\n };\n };\n /**\n * Validates that a given URL is properly federated with our current `portal`.\n * Attempts to use the internal `federatedServers` cache first.\n */\n UserSession.prototype.getTokenForServer = function (url, requestOptions) {\n var _this = this;\n // requests to /rest/services/ and /rest/admin/services/ are both valid\n // Federated servers may have inconsistent casing, so lowerCase it\n var root = this.getServerRootUrl(url);\n var existingToken = this.federatedServers[root];\n if (existingToken &&\n existingToken.expires &&\n existingToken.expires.getTime() > Date.now()) {\n return Promise.resolve(existingToken.token);\n }\n if (this._pendingTokenRequests[root]) {\n return this._pendingTokenRequests[root];\n }\n this._pendingTokenRequests[root] = this.fetchAuthorizedDomains().then(function () {\n return request(root + \"/rest/info\", {\n credentials: _this.getDomainCredentials(url),\n })\n .then(function (response) {\n if (response.owningSystemUrl) {\n /**\n * if this server is not owned by this portal\n * bail out with an error since we know we wont\n * be able to generate a token\n */\n if (!isFederated(response.owningSystemUrl, _this.portal)) {\n throw new ArcGISAuthError(url + \" is not federated with \" + _this.portal + \".\", \"NOT_FEDERATED\");\n }\n else {\n /**\n * if the server is federated, use the relevant token endpoint.\n */\n return request(response.owningSystemUrl + \"/sharing/rest/info\", requestOptions);\n }\n }\n else if (response.authInfo &&\n _this.federatedServers[root] !== undefined) {\n /**\n * if its a stand-alone instance of ArcGIS Server that doesn't advertise\n * federation, but the root server url is recognized, use its built in token endpoint.\n */\n return Promise.resolve({\n authInfo: response.authInfo,\n });\n }\n else {\n throw new ArcGISAuthError(url + \" is not federated with any portal and is not explicitly trusted.\", \"NOT_FEDERATED\");\n }\n })\n .then(function (response) {\n return response.authInfo.tokenServicesUrl;\n })\n .then(function (tokenServicesUrl) {\n // an expired token cant be used to generate a new token\n if (_this.token && _this.tokenExpires.getTime() > Date.now()) {\n return generateToken(tokenServicesUrl, {\n params: {\n token: _this.token,\n serverUrl: url,\n expiration: _this.tokenDuration,\n client: \"referer\",\n },\n });\n // generate an entirely fresh token if necessary\n }\n else {\n return generateToken(tokenServicesUrl, {\n params: {\n username: _this.username,\n password: _this.password,\n expiration: _this.tokenDuration,\n client: \"referer\",\n },\n }).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = new Date(response.expires);\n return response;\n });\n }\n })\n .then(function (response) {\n _this.federatedServers[root] = {\n expires: new Date(response.expires),\n token: response.token,\n };\n delete _this._pendingTokenRequests[root];\n return response.token;\n });\n });\n return this._pendingTokenRequests[root];\n };\n /**\n * Returns an unexpired token for the current `portal`.\n */\n UserSession.prototype.getFreshToken = function (requestOptions) {\n var _this = this;\n if (this.token && !this.tokenExpires) {\n return Promise.resolve(this.token);\n }\n if (this.token &&\n this.tokenExpires &&\n this.tokenExpires.getTime() > Date.now()) {\n return Promise.resolve(this.token);\n }\n if (!this._pendingTokenRequests[this.portal]) {\n this._pendingTokenRequests[this.portal] = this.refreshSession(requestOptions).then(function (session) {\n _this._pendingTokenRequests[_this.portal] = null;\n return session.token;\n });\n }\n return this._pendingTokenRequests[this.portal];\n };\n /**\n * Refreshes the current `token` and `tokenExpires` with `username` and\n * `password`.\n */\n UserSession.prototype.refreshWithUsernameAndPassword = function (requestOptions) {\n var _this = this;\n var options = __assign({ params: {\n username: this.username,\n password: this.password,\n expiration: this.tokenDuration,\n } }, requestOptions);\n return generateToken(this.portal + \"/generateToken\", options).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = new Date(response.expires);\n return _this;\n });\n };\n /**\n * Refreshes the current `token` and `tokenExpires` with `refreshToken`.\n */\n UserSession.prototype.refreshWithRefreshToken = function (requestOptions) {\n var _this = this;\n if (this.refreshToken &&\n this.refreshTokenExpires &&\n this.refreshTokenExpires.getTime() < Date.now()) {\n return this.refreshRefreshToken(requestOptions);\n }\n var options = __assign({ params: {\n client_id: this.clientId,\n refresh_token: this.refreshToken,\n grant_type: \"refresh_token\",\n } }, requestOptions);\n return fetchToken(this.portal + \"/oauth2/token\", options).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = response.expires;\n return _this;\n });\n };\n /**\n * Exchanges an unexpired `refreshToken` for a new one, also updates `token` and\n * `tokenExpires`.\n */\n UserSession.prototype.refreshRefreshToken = function (requestOptions) {\n var _this = this;\n var options = __assign({ params: {\n client_id: this.clientId,\n refresh_token: this.refreshToken,\n redirect_uri: this.redirectUri,\n grant_type: \"exchange_refresh_token\",\n } }, requestOptions);\n return fetchToken(this.portal + \"/oauth2/token\", options).then(function (response) {\n _this._token = response.token;\n _this._tokenExpires = response.expires;\n _this._refreshToken = response.refreshToken;\n _this._refreshTokenExpires = new Date(Date.now() + (_this.refreshTokenTTL - 1) * 60 * 1000);\n return _this;\n });\n };\n /**\n * ensures that the authorizedCrossOriginDomains are obtained from the portal and cached\n * so we can check them later.\n *\n * @returns this\n */\n UserSession.prototype.fetchAuthorizedDomains = function () {\n var _this = this;\n // if this token is for a specific server or we don't have a portal\n // don't get the portal info because we cant get the authorizedCrossOriginDomains\n if (this.server || !this.portal) {\n return Promise.resolve(this);\n }\n return this.getPortal().then(function (portalInfo) {\n /**\n * Specific domains can be configured as secure.esri.com or https://secure.esri.com this\n * normalizes to https://secure.esri.com so we can use startsWith later.\n */\n if (portalInfo.authorizedCrossOriginDomains &&\n portalInfo.authorizedCrossOriginDomains.length) {\n _this.trustedDomains = portalInfo.authorizedCrossOriginDomains\n .filter(function (d) { return !d.startsWith(\"http://\"); })\n .map(function (d) {\n if (d.startsWith(\"https://\")) {\n return d;\n }\n else {\n return \"https://\" + d;\n }\n });\n }\n return _this;\n });\n };\n return UserSession;\n}());\nexport { UserSession };\n//# sourceMappingURL=UserSession.js.map","import { UserSession } from \"@esri/arcgis-rest-auth\";\n/**\n * Remove any serialized sessions associated with the passed clientId\n * from a browser's local storage\n * @param clientId oAuth Client Id\n * @param win optional window (used for testing)\n */\nexport function clearSession(clientId, \n/* istanbul ignore next */\nwin) {\n if (win === void 0) { win = window; }\n if (win.localStorage) {\n win.localStorage.removeItem(\"__CONTEXT_\" + clientId);\n }\n}\n/**\n * Re-hydrate a UserSession from a browser's local storage.\n * If not found,\n * @param clientId oAuth Client Id\n * @param win optional window (used for testing)\n * @returns\n */\nexport function getSession(clientId, \n/* istanbul ignore next */\nwin) {\n if (win === void 0) { win = window; }\n var result = null;\n if (win.localStorage) {\n var serializedSession = win.localStorage.getItem(\"__CONTEXT_\" + clientId);\n if (serializedSession) {\n result = UserSession.deserialize(serializedSession);\n }\n }\n return result;\n}\n/**\n * Serialize a UserSession into a browser's local storage\n * @param clientId oAuth Client Id\n * @param session UserSession\n * @param win optional window (used for testing)\n */\nexport function saveSession(clientId, session, \n/* istanbul ignore next */\nwin) {\n if (win === void 0) { win = window; }\n if (win.localStorage) {\n win.localStorage.setItem(\"__CONTEXT_\" + clientId, session.serialize());\n }\n}\n//# sourceMappingURL=sessionLocalStorage.js.map","import { includes } from \"../utils\";\n/**\n * Checks for fundamental privilege required by all access checks\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function hasBasePriv(user) {\n var _a = user.privileges, privileges = _a === void 0 ? [] : _a;\n return includes(privileges, \"portal:user:createItem\");\n}\n//# sourceMappingURL=has-base-priv.js.map","import { getProp } from \"../objects\";\nimport { findBy } from \"../util\";\nimport { hasBasePriv } from \"./has-base-priv\";\n/**\n * Checks if user has access to edit an event in Hub\n * @param {IEventModel} model consolidated event model as consumed by Hub, contains the event feature, related initiative model, and attendees group\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditEvent(model, user) {\n var res = false;\n if (hasBasePriv(user)) {\n var coreTeamId = getProp(model, \"initiative.item.properties.collaborationGroupId\");\n var _a = user.groups, groups = _a === void 0 ? [] : _a;\n res = !!coreTeamId && !!findBy(groups, \"id\", coreTeamId);\n }\n return res;\n}\n//# sourceMappingURL=can-edit-event.js.map","import { __spreadArrays } from \"tslib\";\nimport { isUpdateGroup, includes } from \"../utils\";\nimport { getProp } from \"../objects\";\nimport { hasBasePriv } from \"./has-base-priv\";\n/**\n * Checks if user has access to edit an item in Hub\n * @param {IItem} item\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditItem(item, user) {\n var res = false;\n var itemControls = [\"admin\", \"update\"];\n var itemControl = item.itemControl, owner = item.owner, itemOrgId = item.orgId;\n var roleId = user.roleId, role = user.role, username = user.username, userGroups = user.groups, userOrgId = user.orgId;\n var hasItemControl = includes(itemControls, itemControl);\n var isOwner = !!owner && owner === username;\n var isOrgItem = !!itemOrgId && itemOrgId === userOrgId;\n var isItemOrgAdmin = !!isOrgItem && !roleId && role === \"org_admin\";\n var hasPlatformControl = hasItemControl || isOwner || isItemOrgAdmin;\n var hasPriv = hasBasePriv(user);\n if (hasPriv && hasPlatformControl) {\n res = true;\n }\n else if (hasPriv) {\n var itemGroups_1 = __spreadArrays((getProp(item, \"groupIds\") || []), [\n getProp(item, \"properties.collaborationGroupId\")\n ]);\n var isGroupEditable = function (group) {\n return isUpdateGroup(group) && includes(itemGroups_1, group.id);\n };\n res = userGroups.some(isGroupEditable);\n }\n return res;\n}\n//# sourceMappingURL=can-edit-item.js.map","import { includes } from \"../utils\";\nimport { getProp } from \"../objects\";\nimport { hasBasePriv } from \"./has-base-priv\";\nimport { canEditItem } from \"./can-edit-item\";\nexport var REQUIRED_PRIVS = [\n \"portal:user:createGroup\",\n \"portal:user:createItem\",\n \"portal:user:shareToGroup\",\n \"portal:user:viewOrgGroups\",\n \"portal:user:viewOrgItems\"\n];\n/**\n * Checks if user has access to content library in Hub\n * In Hub Home context, user access requires additional privileges\n * In initiative context, check is delegated to canEditItem for the initiative site item\n * @param {IItem} item\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditSiteContent(item, user) {\n var res = false;\n var isDefaultHubHome = getProp(item, \"properties.isDefaultHubHome\");\n var hasPriv = hasBasePriv(user);\n if (!isDefaultHubHome && hasPriv) {\n res = canEditItem(item, user);\n }\n else if (hasPriv) {\n var userOrgId = user.orgId;\n var itemOrgId = item.orgId;\n var sameOrg = !!userOrgId && userOrgId === itemOrgId;\n if (sameOrg) {\n var privileges_1 = user.privileges || [];\n res = REQUIRED_PRIVS.every(function (privilege) { return includes(privileges_1, privilege); });\n }\n }\n return res;\n}\n//# sourceMappingURL=can-edit-site-content.js.map","import { getProp } from \"../objects\";\nimport { hasBasePriv } from \"./has-base-priv\";\nimport { canEditItem } from \"./can-edit-item\";\n/**\n * Checks if user has access to edit site in Hub\n * Currently, Hub Home sites are not editable\n * In initiative context, check is delegated to canEditItem for the initiative site item\n * @param {IItem} model\n * @param {IUser} user\n * @returns {boolean}\n */\nexport function canEditSite(model, user) {\n var res = false;\n var isDefaultHubHome = getProp(model, \"properties.isDefaultHubHome\");\n if (!isDefaultHubHome && hasBasePriv(user)) {\n res = canEditItem(model, user);\n }\n return res;\n}\n//# sourceMappingURL=can-edit-site.js.map","/**\n * @private\n */\nexport function buildUrl(params) {\n var host = params.host, path = params.path, query = params.query;\n var baseUrl = host.endsWith(\"/\") ? host : host + \"/\";\n var url = new URL(path, baseUrl);\n url.search = buildQueryString(query);\n return url.toString();\n}\nfunction buildQueryString(params) {\n if (params === void 0) { params = {}; }\n var queryParams = Object.keys(params)\n .filter(function (key) {\n return params[key] !== undefined;\n })\n .reduce(function (acc, key) {\n acc[key] = params[key];\n return acc;\n }, {});\n return new URLSearchParams(queryParams).toString();\n}\n//# sourceMappingURL=build-url.js.map","/* Copyright (c) 2017 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { cleanUrl } from \"@esri/arcgis-rest-request\";\n/**\n * Helper that returns the appropriate portal url for a given request. `requestOptions.portal` is given\n * precedence over `authentication.portal`. If neither `portal` nor `authentication` is present,\n * `www.arcgis.com/sharing/rest` is returned.\n *\n * @param requestOptions - Request options that may have authentication manager\n * @returns Portal url to be used in API requests\n */\nexport function getPortalUrl(requestOptions) {\n if (requestOptions === void 0) { requestOptions = {}; }\n // use portal in options if specified\n if (requestOptions.portal) {\n return cleanUrl(requestOptions.portal);\n }\n // if auth was passed, use that portal\n if (requestOptions.authentication) {\n // the portal url is already scrubbed in the auth package\n return requestOptions.authentication.portal;\n }\n // default to arcgis.com\n return \"https://www.arcgis.com/sharing/rest\";\n}\n//# sourceMappingURL=get-portal-url.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\n/**\n * Serialize an item and its data into a json format accepted by the Portal API for create and update operations\n *\n * @param item Item to be serialized\n * @returns a formatted json object to be sent to Portal\n */\nexport function serializeItem(item) {\n // create a clone so we're not messing with the original\n var clone = JSON.parse(JSON.stringify(item));\n // binary data needs POSTed as a `file`\n // JSON object literals should be passed as `text`.\n if (clone.data) {\n (typeof Blob !== \"undefined\" && item.data instanceof Blob) ||\n // Node.js doesn't implement Blob\n item.data.constructor.name === \"ReadStream\"\n ? (clone.file = item.data)\n : (clone.text = item.data);\n delete clone.data;\n }\n return clone;\n}\n/**\n * `requestOptions.owner` is given priority, `requestOptions.item.owner` will be checked next. If neither are present, `authentication.getUserName()` will be used instead.\n */\nexport function determineOwner(requestOptions) {\n if (requestOptions.owner) {\n return Promise.resolve(requestOptions.owner);\n }\n else if (requestOptions.item && requestOptions.item.owner) {\n return Promise.resolve(requestOptions.item.owner);\n }\n else if (requestOptions.authentication &&\n requestOptions.authentication.getUsername) {\n return requestOptions.authentication.getUsername();\n }\n else {\n return Promise.reject(new Error(\"Could not determine the owner of this item. Pass the `owner`, `item.owner`, or `authentication` option.\"));\n }\n}\n//# sourceMappingURL=helpers.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { serializeItem, determineOwner } from \"./helpers\";\n/**\n * ```js\n * import { updateItem } from \"@esri/arcgis-rest-portal\";\n * //\n * updateItem({\n * item: {\n * id: \"3ef\",\n * description: \"A three hour tour\"\n * },\n * authentication\n * })\n * .then(response)\n * ```\n * Update an Item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-item.htm) for more information.\n *\n * @param requestOptions - Options for the request.\n * @returns A Promise that updates an item.\n */\nexport function updateItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = requestOptions.folderId\n ? getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/\" + requestOptions.folderId + \"/items/\" + requestOptions.item.id + \"/update\"\n : getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.item.id + \"/update\";\n // serialize the item into something Portal will accept\n requestOptions.params = __assign(__assign({}, requestOptions.params), serializeItem(requestOptions.item));\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { updateItemInfo } from \"@esri/arcgis-rest-portal\";\n * //\n * updateItemInfo({\n * id: '3ef',\n * file: file,\n * authentication\n * })\n * .then(response)\n * ```\n * Update an info file associated with an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-info.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that updates an item info file.\n */\nexport function updateItemInfo(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/updateinfo\";\n // mix in user supplied params\n requestOptions.params = __assign({ folderName: requestOptions.folderName, file: requestOptions.file }, requestOptions.params);\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { updateItemResource } from \"@esri/arcgis-rest-portal\";\n * //\n * updateItemResource({\n * id: '3ef',\n * resource: file,\n * name: 'bigkahuna.jpg',\n * authentication\n * })\n * .then(response)\n * ```\n * Update a resource associated with an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-resources.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that updates an item resource.\n */\nexport function updateItemResource(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/updateResources\";\n // mix in user supplied params\n requestOptions.params = __assign({ file: requestOptions.resource, fileName: requestOptions.name, resourcesPrefix: requestOptions.prefix, text: requestOptions.content }, requestOptions.params);\n // only override the access specified previously if 'private' is passed explicitly\n if (typeof requestOptions.private !== \"undefined\") {\n requestOptions.params.access = requestOptions.private\n ? \"private\"\n : \"inherit\";\n }\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { moveItem } from \"@esri/arcgis-rest-portal\";\n * //\n * moveItem({\n * itemId: \"3ef\",\n * folderId: \"7c5\",\n * authentication: userSession\n * })\n * ```\n * Move an item to a folder. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/move-item.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that resolves with owner and folder details once the move has been completed\n */\nexport function moveItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.itemId + \"/move\";\n var folderId = requestOptions.folderId;\n if (!folderId) {\n folderId = \"/\";\n }\n requestOptions.params = __assign({ folder: folderId }, requestOptions.params);\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=update.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { determineOwner } from \"./helpers\";\nimport { updateItem } from \"./update\";\n/**\n * ```js\n * import { addItemData } from \"@esri/arcgis-rest-portal\";\n * //\n * addItemData({\n * id: '3ef',\n * data: file,\n * authentication\n * })\n * .then(response)\n * ```\n * Send a file or blob to an item to be stored as the `/data` resource. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/update-item.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with an object reporting\n * success/failure and echoing the item id.\n */\nexport function addItemData(requestOptions) {\n var options = __assign({ item: {\n id: requestOptions.id,\n data: requestOptions.data\n } }, requestOptions);\n delete options.id;\n delete options.data;\n return updateItem(options);\n}\n/**\n * ```js\n * import { addItemRelationship } from \"@esri/arcgis-rest-portal\";\n * //\n * addItemRelationship({\n * originItemId: '3ef',\n * destinationItemId: 'ae7',\n * relationshipType: 'Service2Layer',\n * authentication\n * })\n * .then(response)\n * ```\n * Add a relationship between two items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/add-relationship.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to add item resources.\n */\nexport function addItemRelationship(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/addRelationship\";\n var options = appendCustomParams(requestOptions, [\"originItemId\", \"destinationItemId\", \"relationshipType\"], { params: __assign({}, requestOptions.params) });\n return request(url, options);\n });\n}\n/**\n * ```js\n * import { addItemResource } from \"@esri/arcgis-rest-portal\";\n * //\n * // Add a file resource\n * addItemResource({\n * id: '3ef',\n * resource: file,\n * name: 'bigkahuna.jpg',\n * authentication\n * })\n * .then(response)\n * //\n * // Add a text resource\n * addItemResource({\n * id: '4fg',\n * content: \"Text content\",\n * name: 'bigkahuna.txt',\n * authentication\n * })\n * .then(response)\n * ```\n * Add a resource associated with an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/add-resources.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to add item resources.\n */\nexport function addItemResource(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/addResources\";\n requestOptions.params = __assign({ file: requestOptions.resource, fileName: requestOptions.name, resourcesPrefix: requestOptions.prefix, text: requestOptions.content, access: requestOptions.private ? \"private\" : \"inherit\" }, requestOptions.params);\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=add.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { scrubControlChars } from '../util/scrub-control-chars';\nimport { determineOwner } from \"./helpers\";\n/**\n * ```\n * import { getItem } from \"@esri/arcgis-rest-portal\";\n * //\n * getItem(\"ae7\")\n * .then(response);\n * // or\n * getItem(\"ae7\", { authentication })\n * .then(response)\n * ```\n * Get an item by id. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/item.htm) for more information.\n *\n * @param id - Item Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function getItem(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions);\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * Get the fully qualified base URL to the REST end point for an item.\n * @param id Item Id\n * @param portalUrlOrRequestOptions a portal URL or request options\n * @returns URL to the item's REST end point, defaults to `https://www.arcgis.com/sharing/rest/content/items/{id}`\n */\nexport var getItemBaseUrl = function (id, portalUrlOrRequestOptions) {\n var portalUrl = typeof portalUrlOrRequestOptions === \"string\"\n ? portalUrlOrRequestOptions\n : getPortalUrl(portalUrlOrRequestOptions);\n return portalUrl + \"/content/items/\" + id;\n};\n/**\n * ```\n * import { getItemData } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemData(\"ae7\")\n * .then(response)\n * // or\n * getItemData(\"ae7\", { authentication })\n * .then(response)\n * ```\n * Get the /data for an item. If no data exists, returns `undefined`. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/item-data.htm) for more information.\n * @param id - Item Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the json data for the item.\n */\nexport function getItemData(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions) + \"/data\";\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\", params: {} }, requestOptions);\n if (options.file) {\n options.params.f = null;\n }\n return request(url, options).catch(function (err) {\n /* if the item doesn't include data, the response will be empty\n and the internal call to response.json() will fail */\n var emptyResponseErr = RegExp(/The string did not match the expected pattern|(Unexpected end of (JSON input|data at line 1 column 1))/i);\n /* istanbul ignore else */\n if (emptyResponseErr.test(err.message)) {\n return;\n }\n else\n throw err;\n });\n}\n/**\n * ```\n * import { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n * //\n * getRelatedItems({\n * id: \"ae7\",\n * relationshipType: \"Service2Layer\" // or several [\"Service2Layer\", \"Map2Area\"]\n * })\n * .then(response)\n * ```\n * Get the related items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/related-items.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to get some item resources.\n */\nexport function getRelatedItems(requestOptions) {\n var url = getItemBaseUrl(requestOptions.id, requestOptions) + \"/relatedItems\";\n var options = __assign({ httpMethod: \"GET\", params: {\n direction: requestOptions.direction\n } }, requestOptions);\n if (typeof requestOptions.relationshipType === \"string\") {\n options.params.relationshipType = requestOptions.relationshipType;\n }\n else {\n options.params.relationshipTypes = requestOptions.relationshipType;\n }\n delete options.direction;\n delete options.relationshipType;\n return request(url, options);\n}\n/**\n * Get the resources associated with an item\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to get some item resources.\n */\nexport function getItemResources(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions) + \"/resources\";\n // Mix in num:1000 with any user supplied params\n // Key thing - we don't want to mutate the passed in requestOptions\n // as that may be used in other (subsequent) calls in the course\n // of a long promise chains\n var options = __assign({}, requestOptions);\n options.params = __assign({ num: 1000 }, options.params);\n return request(url, options);\n}\n/**\n * ```js\n * import { getItemResource } from \"@esri/arcgis-rest-portal\";\n *\n * // Parses contents as blob by default\n * getItemResource(\"3ef\", { fileName: \"resource.jpg\", ...})\n * .then(resourceContents => {});\n *\n * // Can override parse method\n * getItemResource(\"3ef\", { fileName: \"resource.json\", readAs: 'json', ...})\n * .then(resourceContents => {});\n *\n * // Get the response object instead\n * getItemResource(\"3ef\",{ rawResponse: true, fileName: \"resource.json\" })\n * .then(response => {})\n * ```\n * Fetches an item resource and optionally parses it to the correct format.\n *\n * Note: provides JSON parse error protection by sanitizing out any unescaped control\n * characters before parsing that would otherwise cause an error to be thrown\n *\n * @param {string} itemId\n * @param {IGetItemResourceOptions} requestOptions\n */\nexport function getItemResource(itemId, requestOptions) {\n var readAs = requestOptions.readAs || 'blob';\n return getItemFile(itemId, \"/resources/\" + requestOptions.fileName, readAs, requestOptions);\n}\n/**\n * ```js\n * import { getItemGroups } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemGroups(\"30e5fe3149c34df1ba922e6f5bbf808f\")\n * .then(response)\n * ```\n * Lists the groups of which the item is a part, only showing the groups that the calling user can access. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/groups.htm) for more information.\n *\n * @param id - The Id of the item to query group association for.\n * @param requestOptions - Options for the request\n * @returns A Promise to get some item groups.\n */\nexport function getItemGroups(id, requestOptions) {\n var url = getItemBaseUrl(id, requestOptions) + \"/groups\";\n return request(url, requestOptions);\n}\n/**\n * ```js\n * import { getItemStatus } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemStatus({\n * id: \"30e5fe3149c34df1ba922e6f5bbf808f\",\n * authentication\n * })\n * .then(response)\n * ```\n * Inquire about status when publishing an item, adding an item in async mode, or adding with a multipart upload. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/status.htm) for more information.\n *\n * @param id - The Id of the item to get status for.\n * @param requestOptions - Options for the request\n * @returns A Promise to get the item status.\n */\nexport function getItemStatus(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/status\";\n var options = appendCustomParams(requestOptions, [\"jobId\", \"jobType\"], { params: __assign({}, requestOptions.params) });\n return request(url, options);\n });\n}\n/**\n * ```js\n * import { getItemParts } from \"@esri/arcgis-rest-portal\";\n * //\n * getItemParts({\n * id: \"30e5fe3149c34df1ba922e6f5bbf808f\",\n * authentication\n * })\n * .then(response)\n * ```\n * Lists the part numbers of the file parts that have already been uploaded in a multipart file upload. This method can be used to verify the parts that have been received as well as those parts that were not received by the server. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/parts.htm) for more information.\n *\n * @param id - The Id of the item to get part list.\n * @param requestOptions - Options for the request\n * @returns A Promise to get the item part list.\n */\nexport function getItemParts(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/parts\";\n return request(url, requestOptions);\n });\n}\n/**\n * ```\n * import { getItemInfo } from \"@esri/arcgis-rest-portal\";\n * // get the \"Info Card\" for the item\n * getItemInfo(\"ae7\")\n * .then(itemInfoXml) // XML document as a string\n * // or get the contents of a specific file\n * getItemInfo(\"ae7\", { fileName: \"form.json\", readAs: \"json\", authentication })\n * .then(formJson) // JSON document as JSON\n * ```\n * Get an info file for an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/item-info-file.htm) for more information.\n * @param id - Item Id\n * @param requestOptions - Options for the request, including the file name which defaults to `iteminfo.xml`.\n * If the file is not a text file (XML, HTML, etc) you will need to specify the `readAs` parameter\n * @returns A Promise that will resolve with the contents of the info file for the item.\n */\nexport function getItemInfo(id, requestOptions) {\n var _a = requestOptions || {}, _b = _a.fileName, fileName = _b === void 0 ? \"iteminfo.xml\" : _b, _c = _a.readAs, readAs = _c === void 0 ? \"text\" : _c;\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return getItemFile(id, \"/info/\" + fileName, readAs, options);\n}\n/**\n * ```\n * import { getItemMetadata } from \"@esri/arcgis-rest-portal\";\n * // get the metadata for the item\n * getItemMetadata(\"ae7\")\n * .then(itemMetadataXml) // XML document as a string\n * // or with additional request options\n * getItemMetadata(\"ae7\", { authentication })\n * .then(itemMetadataXml) // XML document as a string\n * ```\n * Get the standard formal metadata XML file for an item (`/info/metadata/metadata.xml`)\n * @param id - Item Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the contents of the metadata file for the item as a string.\n */\nexport function getItemMetadata(id, requestOptions) {\n var options = __assign(__assign({}, requestOptions), { fileName: \"metadata/metadata.xml\" });\n return getItemInfo(id, options);\n}\n// overrides request()'s default behavior for reading the response\n// which is based on `params.f` and defaults to JSON\n// Also adds JSON parse error protection by sanitizing out any unescaped control characters before parsing\nfunction getItemFile(id, \n// NOTE: fileName should include any folder/subfolders\nfileName, readMethod, requestOptions) {\n var url = \"\" + getItemBaseUrl(id, requestOptions) + fileName;\n // preserve escape hatch to let the consumer read the response\n // and ensure the f param is not appended to the query string\n var options = __assign({ params: {} }, requestOptions);\n var justReturnResponse = options.rawResponse;\n options.rawResponse = true;\n options.params.f = null;\n return request(url, options).then(function (response) {\n if (justReturnResponse) {\n return response;\n }\n return readMethod !== 'json'\n ? response[readMethod]()\n : response.text().then(function (text) { return JSON.parse(scrubControlChars(text)); });\n });\n}\n//# sourceMappingURL=get.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { determineOwner } from \"./helpers\";\n/**\n * Protect an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/protect.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to protect an item.\n */\nexport function protectItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/protect\";\n return request(url, requestOptions);\n });\n}\n/**\n * Unprotect an item. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/unprotect.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to unprotect an item.\n */\nexport function unprotectItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/unprotect\";\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=protect.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { getGroup } from \"@esri/arcgis-rest-portal\";\n * //\n * getGroup(\"fxb988\") // id\n * .then(response)\n * ```\n * Fetch a group using its id. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group.htm) for more information.\n *\n * @param id - Group Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function getGroup(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id;\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * Gets the category schema set on a group\n *\n * @param id - Group Id\n * @param requestOptions - Options for the request\n * @returns A promise that will resolve with JSON of group's category schema\n * @see https://developers.arcgis.com/rest/users-groups-and-items/group-category-schema.htm\n */\nexport function getGroupCategorySchema(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/categorySchema\";\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * Returns the content of a Group. Since the group may contain 1000s of items\n * the requestParams allow for paging.\n * @param id - Group Id\n * @param requestOptions - Options for the request, including paging parameters.\n * @returns A Promise that will resolve with the content of the group.\n */\nexport function getGroupContent(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/content/groups/\" + id;\n // default to a GET request\n var options = __assign(__assign({ httpMethod: \"GET\" }, { params: { start: 1, num: 100 } }), requestOptions);\n // is this the most concise way to mixin with the defaults above?\n if (requestOptions && requestOptions.paging) {\n options.params = __assign({}, requestOptions.paging);\n }\n return request(url, options);\n}\n/**\n * Get the usernames of the admins and members. Does not return actual 'User' objects. Those must be\n * retrieved via separate calls to the User's API.\n * @param id - Group Id\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with arrays of the group admin usernames and the member usernames\n */\nexport function getGroupUsers(id, requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/users\";\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n return request(url, options);\n}\n/**\n * ```js\n * import { searchGroupUsers } from \"@esri/arcgis-rest-portal\";\n * //\n * searchGroupUsers('abc123')\n * .then(response)\n * ```\n * Search the users in a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group-users-list.htm) for more information.\n *\n * @param id - The group id\n * @param searchOptions - Options for the request, including paging parameters.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchGroupUsers(id, searchOptions) {\n var url = getPortalUrl(searchOptions) + \"/community/groups/\" + id + \"/userlist\";\n var options = appendCustomParams(searchOptions || {}, [\"name\", \"num\", \"start\", \"sortField\", \"sortOrder\", \"joined\", \"memberType\"], {\n httpMethod: \"GET\"\n });\n return request(url, options);\n}\n//# sourceMappingURL=get.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { getGroup } from \"../groups/get\";\nexport function getSharingUrl(requestOptions) {\n var username = requestOptions.authentication.username;\n var owner = requestOptions.owner || username;\n return getPortalUrl(requestOptions) + \"/content/users/\" + encodeURIComponent(owner) + \"/items/\" + requestOptions.id + \"/share\";\n}\nexport function isItemOwner(requestOptions) {\n var username = requestOptions.authentication.username;\n var owner = requestOptions.owner || username;\n return owner === username;\n}\n/**\n * Check it the user is a full org_admin\n * @param requestOptions\n * @returns Promise resolving in a boolean indicating if the user is an ArcGIS Organization administrator\n */\nexport function isOrgAdmin(requestOptions) {\n var session = requestOptions.authentication;\n return session.getUser(requestOptions).then(function (user) {\n return user && user.role === \"org_admin\" && !user.roleId;\n });\n}\n/**\n * Get the User Membership for a particular group. Use this if all you have is the groupId.\n * If you have the group object, check the `userMembership.memberType` property instead of calling this method.\n *\n * @param requestOptions\n * @returns A Promise that resolves with \"owner\" | \"admin\" | \"member\" | \"nonmember\"\n */\nexport function getUserMembership(requestOptions) {\n // fetch the group...\n return getGroup(requestOptions.groupId, requestOptions)\n .then(function (group) {\n return group.userMembership.memberType;\n })\n .catch(function () {\n return \"none\";\n });\n}\n//# sourceMappingURL=helpers.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request, appendCustomParams } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { determineOwner } from \"./helpers\";\n/**\n * ```js\n * import { removeItem } from \"@esri/arcgis-rest-portal\";\n * //\n * removeItem({\n * id: \"3ef\",\n * authentication\n * })\n * ```\n * Delete an item from the portal. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-item.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that deletes an item.\n */\nexport function removeItem(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/delete\";\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { removeItemRelationship } from \"@esri/arcgis-rest-portal\";\n * //\n * removeItemRelationship({\n * originItemId: '3ef',\n * destinationItemId: 'ae7',\n * relationshipType: 'Service2Layer',\n * authentication\n * })\n * .then(response)\n * ```\n * Remove a relationship between two items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-relationship.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise to add item resources.\n */\nexport function removeItemRelationship(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/deleteRelationship\";\n var options = appendCustomParams(requestOptions, [\"originItemId\", \"destinationItemId\", \"relationshipType\"], { params: __assign({}, requestOptions.params) });\n return request(url, options);\n });\n}\n/**\n * Remove a resource associated with an item\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that deletes an item resource.\n */\nexport function removeItemResource(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + owner + \"/items/\" + requestOptions.id + \"/removeResources\";\n // mix in user supplied params\n requestOptions.params = __assign(__assign({}, requestOptions.params), { resource: requestOptions.resource });\n // only override the deleteAll param specified previously if it is passed explicitly\n if (typeof requestOptions.deleteAll !== \"undefined\") {\n requestOptions.params.deleteAll = requestOptions.deleteAll;\n }\n return request(url, requestOptions);\n });\n}\n/**\n * ```js\n * import { removeFolder } from \"@esri/arcgis-rest-portal\";\n * //\n * removeFolder({\n * folderId: \"fe4\",\n * owner: \"c@sey\",\n * authentication\n * })\n * .then(response)\n *\n * ```\n * Delete a non-root folder and all the items it contains. See the [REST\n * Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-folder.htm) for\n * more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that deletes a folder\n */\nexport function removeFolder(requestOptions) {\n return determineOwner(requestOptions).then(function (owner) {\n var url = getPortalUrl(requestOptions) + \"/content/users/\" + encodeURIComponent(owner) + \"/\" + requestOptions.folderId + \"/delete\";\n return request(url, requestOptions);\n });\n}\n//# sourceMappingURL=remove.js.map","/* Copyright (c) 2018-2021 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { warn } from \"@esri/arcgis-rest-request\";\n/**\n * `SearchQueryBuilder` can be used to construct the `q` param for\n * [`searchItems`](/arcgis-rest-js/api/portal/searchItems#searchItems-search) or\n * [`searchGroups`](/arcgis-rest-js/api/portal/searchGroups#searchGroups-search).\n * By chaining methods, it helps build complex search queries.\n *\n * ```js\n * const startDate = new Date(\"2020-01-01\");\n * const endDate = new Date(\"2020-09-01\");\n * const query = new SearchQueryBuilder()\n * .match(\"Patrick\")\n * .in(\"owner\")\n * .and()\n * .from(startDate)\n * .to(endDate)\n * .in(\"created\")\n * .and()\n * .startGroup()\n * .match(\"Web Mapping Application\")\n * .in(\"type\")\n * .or()\n * .match(\"Mobile Application\")\n * .in(\"type\")\n * .or()\n * .match(\"Application\")\n * .in(\"type\")\n * .endGroup()\n * .and()\n * .match(\"Demo App\");\n *\n * searchItems(query).then((res) => {\n * console.log(res.results);\n * });\n * ```\n *\n * Will search for items matching\n * ```\n * \"owner: Patrick AND created:[1577836800000 TO 1598918400000] AND (type:\"Web Mapping Application\" OR type:\"Mobile Application\" OR type:Application) AND Demo App\"\n * ```\n */\nvar SearchQueryBuilder = /** @class */ (function () {\n /**\n * @param q An existing query string to start building from.\n */\n function SearchQueryBuilder(q) {\n if (q === void 0) { q = \"\"; }\n this.termStack = [];\n this.rangeStack = [];\n this.openGroups = 0;\n this.q = q;\n }\n /**\n * Defines strings to search for.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"My Layer\")\n * ```\n *\n * @param terms strings to search for.\n */\n SearchQueryBuilder.prototype.match = function () {\n var terms = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n terms[_i] = arguments[_i];\n }\n this.termStack = this.termStack.concat(terms);\n return this;\n };\n /**\n * Defines fields to search in. You can pass `\"*\"` or call this method without arguments to search a default set of fields\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"My Layer\")\n * .in(\"title\")\n * ```\n *\n * @param field The field to search for the previous match in.\n */\n SearchQueryBuilder.prototype.in = function (field) {\n var fn = \"`in(\" + (field ? \"\\\"\" + field + \"\\\"\" : \"\") + \")`\";\n if (!this.hasRange && !this.hasTerms) {\n warn(\n // apparently-p-rettier-ignore causes some\n fn + \" was called with no call to `match(...)` or `from(...)`/`to(...)`. Your query was not modified.\");\n return this;\n }\n if (field && field !== \"*\") {\n this.q += field + \":\";\n }\n return this.commit();\n };\n /**\n * Starts a new search group.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .startGroup()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .endGroup()\n * .or()\n * .startGroup()\n * .match(\"Rivers\")\n * .in(\"title\")\n * .endGroup()\n * ```\n */\n SearchQueryBuilder.prototype.startGroup = function () {\n this.commit();\n if (this.openGroups > 0) {\n this.q += \" \";\n }\n this.openGroups++;\n this.q += \"(\";\n return this;\n };\n /**\n * Ends a search group.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .startGroup()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .endGroup()\n * .or()\n * .startGroup()\n * .match(\"Rivers\")\n * .in(\"title\")\n * .endGroup()\n * ```\n */\n SearchQueryBuilder.prototype.endGroup = function () {\n if (this.openGroups <= 0) {\n warn(\"`endGroup(...)` was called without calling `startGroup(...)` first. Your query was not modified.\");\n return this;\n }\n this.commit();\n this.openGroups--;\n this.q += \")\";\n return this;\n };\n /**\n * Joins two sets of queries with an `AND` clause.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .and()\n * .match(\"Rivers\")\n * .in(\"title\")\n * ```\n */\n SearchQueryBuilder.prototype.and = function () {\n return this.addModifier(\"and\");\n };\n /**\n * Joins two sets of queries with an `OR` clause.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .or()\n * .match(\"Rivers\")\n * .in(\"title\")\n * ```\n */\n SearchQueryBuilder.prototype.or = function () {\n return this.addModifier(\"or\");\n };\n /**\n * Joins two sets of queries with a `NOT` clause. Another option for filtering results is the [prohibit operator '-'](https://developers.arcgis.com/rest/users-groups-and-items/search-reference.htm#ESRI_SECTION1_5C6C35DB9E4A4F4492C5B937BDA2BF67).\n *\n * ```js\n * // omit results with \"Rivers\" in their title\n * const query = new SearchQueryBuilder()\n * .not()\n * .match(\"Rivers\")\n * .in(\"title\")\n *\n * // equivalent\n * const query = new SearchQueryBuilder()\n * .match(\"Rivers\")\n * .in(\"-title\")\n * ```\n */\n SearchQueryBuilder.prototype.not = function () {\n return this.addModifier(\"not\");\n };\n /**\n * Begins a new range query.\n *\n * ```js\n *\n * const NEWYEARS = new Date(\"2020-01-01\")\n * const TODAY = new Date()\n *\n * const query = new SearchQueryBuilder()\n * .from(NEWYEARS)\n * .to(TODAY)\n * .in(\"created\")\n * ```\n */\n SearchQueryBuilder.prototype.from = function (term) {\n if (this.hasTerms) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"`from(...)` is not allowed after `match(...)` try using `.from(...).to(...).in(...)`. Optionally, you may see this because dates are incorrectly formatted. Dates should be a primative Date value, aka a number in milliseconds or Date object, ie new Date(\\\"2020-01-01\\\"). Your query was not modified.\");\n return this;\n }\n this.rangeStack[0] = term;\n return this;\n };\n /**\n * Ends a range query.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .from(yesterdaysDate)\n * .to(todaysDate)\n * .in(\"created\")\n * ```\n */\n SearchQueryBuilder.prototype.to = function (term) {\n if (this.hasTerms) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"`to(...)` is not allowed after `match(...)` try using `.from(...).to(...).in(...)`. Optionally, you may see this because dates are incorrectly formatted. Dates should be a primative Date value, aka a number in milliseconds or Date object, ie new Date(\\\"2020-01-01\\\"). Your query was not modified.\");\n return this;\n }\n this.rangeStack[1] = term;\n return this;\n };\n /**\n * Boosts the previous term to increase its rank in the results.\n *\n * ```js\n * const query = new SearchQueryBuilder()\n * .match(\"Lakes\")\n * .in(\"title\")\n * .or()\n * .match(\"Rivers\")\n * .in(\"title\")\n * .boost(3)\n * ```\n */\n SearchQueryBuilder.prototype.boost = function (num) {\n this.commit();\n this.q += \"^\" + num;\n return this;\n };\n /**\n * Returns the current query string. Called internally when the request is made.\n */\n SearchQueryBuilder.prototype.toParam = function () {\n this.commit();\n this.cleanup();\n return this.q;\n };\n /**\n * Returns a new instance of `SearchQueryBuilder` based on the current instance.\n */\n SearchQueryBuilder.prototype.clone = function () {\n this.commit();\n this.cleanup();\n return new SearchQueryBuilder(this.q + \"\");\n };\n SearchQueryBuilder.prototype.addModifier = function (modifier) {\n if (this.currentModifer) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"You have called `\" + this.currentModifer + \"()` after `\" + modifier + \"()`. Your current query was not modified.\");\n return this;\n }\n this.commit();\n if (this.q === \"\" && modifier !== \"not\") {\n warn(\"You have called `\" + modifier + \"()` without calling another method to modify your query first. Try calling `match()` first.\");\n return this;\n }\n this.currentModifer = modifier;\n this.q += this.q === \"\" ? \"\" : \" \";\n this.q += modifier.toUpperCase() + \" \";\n return this;\n };\n SearchQueryBuilder.prototype.needsQuotes = function (s) {\n return /\\s|:/g.test(s);\n };\n SearchQueryBuilder.prototype.formatTerm = function (term) {\n if (term instanceof Date) {\n return term.getTime();\n }\n if (typeof term === \"string\" && this.needsQuotes(term)) {\n return \"\\\"\" + term + \"\\\"\";\n }\n return term;\n };\n SearchQueryBuilder.prototype.commit = function () {\n var _this = this;\n this.currentModifer = undefined;\n if (this.hasRange) {\n this.q += \"[\" + this.formatTerm(this.rangeStack[0]) + \" TO \" + this.formatTerm(this.rangeStack[1]) + \"]\";\n this.rangeStack = [undefined, undefined];\n }\n if (this.hasTerms) {\n this.q += this.termStack\n .map(function (term) {\n return _this.formatTerm(term);\n })\n .join(\" \");\n this.termStack = [];\n }\n return this;\n };\n Object.defineProperty(SearchQueryBuilder.prototype, \"hasTerms\", {\n get: function () {\n return this.termStack.length > 0;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(SearchQueryBuilder.prototype, \"hasRange\", {\n get: function () {\n return this.rangeStack.length && this.rangeStack[0] && this.rangeStack[1];\n },\n enumerable: false,\n configurable: true\n });\n SearchQueryBuilder.prototype.cleanup = function () {\n // end a group if we have started one\n if (this.openGroups > 0) {\n warn(\n // apparently-p*rettier-ignore causes prettier to strip *all* comments O_o\n \"Automatically closing \" + this.openGroups + \" group(s). You can use `endGroup(...)` to remove this warning.\");\n while (this.openGroups > 0) {\n this.q += \")\";\n this.openGroups--;\n }\n }\n var oldQ = this.q;\n this.q = oldQ.replace(/( AND ?| NOT ?| OR ?)*$/, \"\");\n if (oldQ !== this.q) {\n warn(\"`startGroup(...)` was called without calling `endGroup(...)` first. Your query was not modified.\");\n }\n // clear empty groups\n this.q = this.q.replace(/(\\(\\))*/, \"\");\n };\n return SearchQueryBuilder;\n}());\nexport { SearchQueryBuilder };\n//# sourceMappingURL=SearchQueryBuilder.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request, appendCustomParams, } from \"@esri/arcgis-rest-request\";\nimport { SearchQueryBuilder } from \"./SearchQueryBuilder\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nexport function genericSearch(search, searchType) {\n var options;\n if (typeof search === \"string\" || search instanceof SearchQueryBuilder) {\n options = {\n httpMethod: \"GET\",\n params: {\n q: search,\n },\n };\n }\n else {\n // searchUserAccess has one (knonw) valid value: \"groupMember\"\n options = appendCustomParams(search, [\n \"q\",\n \"num\",\n \"start\",\n \"sortField\",\n \"sortOrder\",\n \"searchUserAccess\",\n \"searchUserName\",\n \"filter\",\n \"countFields\",\n \"countSize\",\n \"categories\",\n \"categoryFilters\",\n ], {\n httpMethod: \"GET\",\n });\n }\n var path;\n switch (searchType) {\n case \"item\":\n path = \"/search\";\n break;\n case \"group\":\n path = \"/community/groups\";\n break;\n case \"groupContent\":\n // Need to have groupId property to do group contents search,\n // cso filter out all but ISearchGroupContentOptions\n if (typeof search !== \"string\" &&\n !(search instanceof SearchQueryBuilder) &&\n search.groupId) {\n path = \"/content/groups/\" + search.groupId + \"/search\";\n }\n else {\n return Promise.reject(new Error(\"you must pass a `groupId` option to `searchGroupContent`\"));\n }\n break;\n default:\n // \"users\"\n path = \"/portals/self/users/search\";\n break;\n }\n var url = getPortalUrl(options) + path;\n // send the request\n return request(url, options).then(function (r) {\n if (r.nextStart && r.nextStart !== -1) {\n r.nextPage = function () {\n var newOptions;\n if (typeof search === \"string\" ||\n search instanceof SearchQueryBuilder) {\n newOptions = {\n q: search,\n start: r.nextStart,\n };\n }\n else {\n newOptions = search;\n newOptions.start = r.nextStart;\n }\n return genericSearch(newOptions, searchType);\n };\n }\n return r;\n });\n}\n//# sourceMappingURL=generic-search.js.map","/* Copyright (c) 2018-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { genericSearch } from \"../util/generic-search\";\n/**\n * ```js\n * import { searchItems } from \"@esri/arcgis-rest-portal\";\n * //\n * searchItems('water')\n * .then(response) // response.total => 355\n * ```\n * Search a portal for items. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/search.htm) for more information.\n *\n * @param search - A string or RequestOptions object to pass through to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchItems(search) {\n return genericSearch(search, \"item\");\n}\n//# sourceMappingURL=search.js.map","/* Copyright (c) 2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nexport function chunk(array, size) {\n if (array.length === 0) {\n return [];\n }\n var chunks = [];\n for (var i = 0; i < array.length; i += size) {\n chunks.push(array.slice(i, i + size));\n }\n return chunks;\n}\n//# sourceMappingURL=array.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign, __spreadArrays } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * ```js\n * import { addGroupUsers } from \"@esri/arcgis-rest-portal\";\n * //\n * addGroupUsers({\n * id: groupId,\n * users: [\"username1\", \"username2\"],\n * admins: [\"username3\"],\n * authentication\n * })\n * .then(response);\n * ```\n * Add users to a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/add-users-to-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise\n */\nexport function addGroupUsers(requestOptions) {\n var id = requestOptions.id;\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/addUsers\";\n var baseOptions = Object.assign({}, requestOptions, {\n admins: undefined,\n users: undefined\n });\n var batchRequestOptions = __spreadArrays(_prepareRequests(\"users\", requestOptions.users, baseOptions), _prepareRequests(\"admins\", requestOptions.admins, baseOptions));\n var promises = batchRequestOptions.map(function (options) {\n return _sendSafeRequest(url, options);\n });\n return Promise.all(promises).then(_consolidateRequestResults);\n}\nfunction _prepareRequests(type, usernames, baseOptions) {\n if (!usernames || usernames.length < 1) {\n return [];\n }\n // the ArcGIS REST API only allows to add no more than 25 users per request,\n // see https://developers.arcgis.com/rest/users-groups-and-items/add-users-to-group.htm\n var userChunks = chunk(usernames, 25);\n return userChunks.map(function (users) {\n return _generateRequestOptions(type, users, baseOptions);\n });\n}\nfunction _generateRequestOptions(type, usernames, baseOptions) {\n var _a, _b;\n return Object.assign({}, baseOptions, (_a = {},\n _a[type] = usernames,\n _a.params = __assign(__assign({}, baseOptions.params), (_b = {}, _b[type] = usernames, _b)),\n _a));\n}\n// this request is safe since the request error will be handled\nfunction _sendSafeRequest(url, requestOptions) {\n return request(url, requestOptions).catch(function (error) {\n return {\n errors: [error]\n };\n });\n}\nfunction _consolidateRequestResults(results) {\n var notAdded = results\n .filter(function (result) { return result.notAdded; })\n .reduce(function (collection, result) { return collection.concat(result.notAdded); }, []);\n var errors = results\n .filter(function (result) { return result.errors; })\n .reduce(function (collection, result) { return collection.concat(result.errors); }, []);\n var consolidated = { notAdded: notAdded };\n if (errors.length > 0) {\n consolidated.errors = errors;\n }\n return consolidated;\n}\n//# sourceMappingURL=add-users.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * ```js\n * import { removeGroupUsers } from \"@esri/arcgis-rest-portal\";\n * //\n * removeGroupUsers({\n * id: groupId,\n * users: [\"username1\", \"username2\"],\n * authentication\n * })\n * .then(response);\n * ```\n * Add users to a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/remove-users-from-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise\n */\nexport function removeGroupUsers(requestOptions) {\n var id = requestOptions.id, usersToRemove = requestOptions.users;\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + id + \"/removeUsers\";\n var safeSend = function (users) {\n var options = __assign(__assign({}, requestOptions), { users: users, params: { users: users } });\n return request(url, options)\n .catch(function (error) { return ({ errors: [error] }); });\n };\n // the ArcGIS REST API only allows to add no more than 25 users per request,\n // see https://developers.arcgis.com/rest/users-groups-and-items/remove-users-from-group.htm\n var promises = chunk(usersToRemove, 25).map(function (usersChunk) { return safeSend(usersChunk); });\n return Promise.all(promises)\n .then(function (results) {\n var filtered = function (propName) { return results\n .filter(function (result) { return result[propName]; })\n .reduce(function (collection, result) { return collection.concat(result[propName]); }, []); };\n var errors = filtered('errors');\n var consolidated = { notRemoved: filtered('notRemoved') };\n return errors.length ? __assign(__assign({}, consolidated), { errors: errors }) : consolidated;\n });\n}\n//# sourceMappingURL=remove-users.js.map","import { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * Invites users to join a group. Operation success\n * will be indicated by a flag on the return\n * object. If there are any errors, they will be\n * placed in an errors array on the return object\n *\n * ```js\n * const authentication: IAuthenticationManager; // Typically passed into to the function\n * //\n * const options: IInviteGroupUsersOptions = {\n * id: 'group_id',\n * users: ['ed', 'edd', 'eddy'],\n * role: 'group-member',\n * expiration: 20160,\n * authentication\n * }\n * //\n * const result = await inviteGroupUsers(options);\n * //\n * const if_success_result_looks_like = {\n * success: true\n * }\n * //\n * const if_failure_result_looks_like = {\n * success: false,\n * errors: [ArcGISRequestError]\n * }\n * ```\n * @param {IInviteGroupUsersOptions} options\n *\n * @returns {Promise<IAddGroupUsersResult>}\n */\nexport function inviteGroupUsers(options) {\n var id = options.id;\n var url = getPortalUrl(options) + \"/community/groups/\" + id + \"/invite\";\n var batches = _generateBatchRequests(options);\n var promises = batches.map(function (batch) { return _sendSafeRequest(url, batch); });\n return Promise.all(promises).then(_combineResults);\n}\n/**\n * @private\n */\nfunction _generateBatchRequests(options) {\n var userBatches = chunk(options.users, 25);\n return userBatches.map(function (users) { return _generateRequestOptions(users, options); });\n}\n/**\n * @private\n */\nfunction _generateRequestOptions(users, baseOptions) {\n var requestOptions = Object.assign({}, baseOptions);\n requestOptions.params = __assign(__assign({}, requestOptions.params), { users: users, role: requestOptions.role, expiration: requestOptions.expiration });\n return requestOptions;\n}\n/**\n * @private\n */\nfunction _sendSafeRequest(url, requestOptions) {\n return request(url, requestOptions)\n .catch(function (error) { return ({ errors: [error] }); });\n}\n/**\n * @private\n */\nfunction _combineResults(responses) {\n var success = responses.every(function (res) { return res.success; });\n var errors = responses.reduce(function (collection, res) { return collection.concat(res.errors || []); }, []);\n var combined = { success: success };\n if (errors.length > 0) {\n combined.errors = errors;\n }\n return combined;\n}\n//# sourceMappingURL=invite-users.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { protectGroup } from '@esri/arcgis-rest-portal';\n * //\n * protectGroup({\n * id: groupId,\n * authentication\n * })\n * .then(response)\n * ```\n * Protect a group to avoid accidental deletion. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/protect-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the success/failure status of the request\n */\nexport function protectGroup(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/protect\";\n return request(url, requestOptions);\n}\n/**\n * ```js\n * import { unprotectGroup } from '@esri/arcgis-rest-portal';\n * //\n * unprotectGroup({\n * id: groupId,\n * authentication\n * })\n * .then(response)\n * ```\n * Unprotect a Group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/unprotect-group.htm) for more information.\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the success/failure status of the request\n */\nexport function unprotectGroup(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/unprotect\";\n return request(url, requestOptions);\n}\n//# sourceMappingURL=protect.js.map","/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { removeGroup } from '@esri/arcgis-rest-portal';\n * //\n * removeGroup({\n * id: groupId,\n * authentication\n * })\n * .then(response)\n * ```\n * Delete a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/delete-group.htm) for more information.\n *\n * @param requestOptions - Options for the request\n * @returns A Promise that will resolve with the success/failure status of the request\n */\nexport function removeGroup(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/delete\";\n var options = __assign({}, requestOptions);\n return request(url, options);\n}\n//# sourceMappingURL=remove.js.map","/* Copyright (c) 2018-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { genericSearch } from \"../util/generic-search\";\n/**\n * ```js\n * import { searchGroups } from \"@esri/arcgis-rest-portal\";\n * //\n * searchGroups('water')\n * .then(response) // response.total => 355\n * ```\n * Search a portal for groups. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group-search.htm) for more information.\n *\n * @param search - A string or RequestOptions object to pass through to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchGroups(search) {\n return genericSearch(search, \"group\");\n}\n/**\n * ```js\n * import { searchGroupContent } from \"@esri/arcgis-rest-portal\";\n * //\n * searchGroupContent('water')\n * .then(response) // response.total => 355\n * ```\n * Search a portal for items in a group. See the [REST Documentation](https://developers.arcgis.com/rest/users-groups-and-items/group-content-search.htm) for more information.\n *\n * @param options - RequestOptions object amended with search parameters.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchGroupContent(options) {\n return genericSearch(options, \"groupContent\");\n}\n//# sourceMappingURL=search.js.map","import { getPortalUrl } from \"../util/get-portal-url\";\nimport { request } from \"@esri/arcgis-rest-request\";\n/**\n * ```js\n * import { updateUserMemberships } from \"@esri/arcgis-rest-portal\";\n * //\n * updateUserMemberships({\n * id: groupId,\n * admins: [\"username3\"],\n * authentication\n * })\n * .then(response);\n * ```\n * Change the user membership levels of existing users in a group\n *\n * @param requestOptions - Options for the request\n * @returns A Promise\n */\nexport function updateUserMemberships(requestOptions) {\n var url = getPortalUrl(requestOptions) + \"/community/groups/\" + requestOptions.id + \"/updateUsers\";\n var opts = {\n authentication: requestOptions.authentication,\n params: {}\n };\n // add the correct params depending on the type of membership we are changing to\n if (requestOptions.newMemberType === \"admin\") {\n opts.params.admins = requestOptions.users;\n }\n else {\n opts.params.users = requestOptions.users;\n }\n // make the request\n return request(url, opts);\n}\n//# sourceMappingURL=update-user-membership.js.map","import { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { chunk } from \"../util/array\";\n/**\n * Send a notification to members of the requesting user's org.\n * Operation success will be indicated by a flag on the return\n * object. If there are any errors, they will be placed in an\n * errors array on the return object\n *\n * ```js\n * const authentication: IAuthenticationManager; // Typically passed into to the function\n * //\n * const options: IInviteGroupUsersOptions = {\n * id: 'group_id',\n * users: ['larry', 'curly', 'moe'],\n * notificationChannelType: 'email',\n * expiration: 20160,\n * authentication\n * }\n * //\n * const result = await createOrgNotification(options);\n * //\n * const if_success_result_looks_like = {\n * success: true\n * }\n * //\n * const if_failure_result_looks_like = {\n * success: false,\n * errors: [ArcGISRequestError]\n * }\n * ```\n * @param {ICreateOrgNotificationOptions} options\n *\n * @returns {ICreateOrgNotificationResult}\n */\nexport function createOrgNotification(options) {\n var url = getPortalUrl(options) + \"/portals/self/createNotification\";\n var batches = _generateBatchRequests(options);\n var promises = batches.map(function (batch) { return _sendSafeRequest(url, batch); });\n return Promise.all(promises).then(_combineResults);\n}\n/**\n * @private\n */\nfunction _generateBatchRequests(options) {\n var userBatches = chunk(options.users, options.batchSize || 25);\n return userBatches.map(function (users) { return _generateRequestOptions(users, options); });\n}\n/**\n * @private\n */\nfunction _generateRequestOptions(users, baseOptions) {\n var requestOptions = Object.assign({}, baseOptions);\n requestOptions.params = __assign(__assign({}, requestOptions.params), { users: users, subject: baseOptions.subject, message: baseOptions.message, notificationChannelType: requestOptions.notificationChannelType });\n return requestOptions;\n}\n/**\n * @private\n */\nfunction _sendSafeRequest(url, requestOptions) {\n return request(url, requestOptions)\n .catch(function (error) { return ({ errors: [error] }); });\n}\n/**\n * @private\n */\nfunction _combineResults(responses) {\n var success = responses.every(function (res) { return res.success; });\n var errors = responses.reduce(function (collection, res) { return collection.concat(res.errors || []); }, []);\n var combined = { success: success };\n if (errors.length > 0) {\n combined.errors = errors;\n }\n return combined;\n}\n//# sourceMappingURL=notification.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\n/**\n * ```js\n * import { getUser } from '@esri/arcgis-rest-portal';\n * //\n * getUser(\"jsmith\")\n * .then(response)\n * // => { firstName: \"John\", lastName: \"Smith\",tags: [\"GIS Analyst\", \"City of Redlands\"] }\n * ```\n * Get information about a user. This method has proven so generically useful that you can also call [`UserSession.getUser()`](/arcgis-rest-js/api/auth/UserSession#getUser-summary).\n *\n * @param requestOptions - options to pass through in the request\n * @returns A Promise that will resolve with metadata about the user\n */\nexport function getUser(requestOptions) {\n var url;\n var options = { httpMethod: \"GET\" };\n // if a username is passed, assume ArcGIS Online\n if (typeof requestOptions === \"string\") {\n url = \"https://www.arcgis.com/sharing/rest/community/users/\" + requestOptions;\n }\n else {\n // if an authenticated session is passed, default to that user/portal unless another username is provided manually\n var username = requestOptions.username || requestOptions.authentication.username;\n url = getPortalUrl(requestOptions) + \"/community/users/\" + encodeURIComponent(username);\n options = __assign(__assign({}, requestOptions), options);\n }\n // send the request\n return request(url, options);\n}\n//# sourceMappingURL=get-user.js.map","import { genericSearch } from \"../util/generic-search\";\n/**\n * ```js\n * import { searchItems } from \"@esri/arcgis-rest-portal\";\n * //\n * searchUsers({ q: 'tommy', authentication })\n * .then(response) // response.total => 355\n * ```\n * Search a portal for users.\n *\n * @param search - A RequestOptions object to pass through to the endpoint.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function searchUsers(search) {\n return genericSearch(search, \"user\");\n}\n//# sourceMappingURL=search-users.js.map","import { searchItems } from \"../items/search\";\n/**\n * ```js\n * import { isItemSharedWithGroup } from \"@esri/arcgis-rest-portal\";\n * //\n * isItemSharedWithGroup({\n * groupId: 'bc3,\n * itemId: 'f56,\n * authentication\n * })\n * .then(isShared => {})\n * ```\n * Find out whether or not an item is already shared with a group.\n *\n * @param requestOptions - Options for the request. NOTE: `rawResponse` is not supported by this operation.\n * @returns Promise that will resolve with true/false\n */\nexport function isItemSharedWithGroup(requestOptions) {\n var searchOpts = {\n q: \"id: \" + requestOptions.id + \" AND group: \" + requestOptions.groupId,\n start: 1,\n num: 10,\n sortField: \"title\",\n authentication: requestOptions.authentication,\n httpMethod: \"POST\"\n };\n return searchItems(searchOpts).then(function (searchResponse) {\n var result = false;\n if (searchResponse.total > 0) {\n result = searchResponse.results.some(function (itm) {\n return itm.id === requestOptions.id;\n });\n return result;\n }\n });\n}\n//# sourceMappingURL=is-item-shared-with-group.js.map","import { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { getUserMembership, } from \"./helpers\";\nimport { getUser } from \"../users/get-user\";\nimport { addGroupUsers } from \"../groups/add-users\";\nimport { removeGroupUsers } from \"../groups/remove-users\";\nimport { updateUserMemberships, } from \"../groups/update-user-membership\";\nimport { isItemSharedWithGroup } from \"../sharing/is-item-shared-with-group\";\n/**\n * ```js\n * import { shareItemWithGroup } from '@esri/arcgis-rest-portal';\n * //\n * shareItemWithGroup({\n * id: \"abc123\",\n * groupId: \"xyz987\",\n * owner: \"some-owner\",\n * authentication\n * })\n * ```\n * Share an item with a group, either as an\n * [item owner](https://developers.arcgis.com/rest/users-groups-and-items/share-item-as-item-owner-.htm),\n * [group admin](https://developers.arcgis.com/rest/users-groups-and-items/share-item-as-group-admin-.htm) or\n * organization admin.\n *\n * Note: Sharing the item as an Admin will use the `/content/users/:ownername/items/:itemid/share` end-point\n *\n * @param requestOptions - Options for the request.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function shareItemWithGroup(requestOptions) {\n return isItemSharedWithGroup(requestOptions)\n .then(function (isShared) {\n if (isShared) {\n // already shared, exit early with success response\n return {\n itemId: requestOptions.id,\n shortcut: true,\n notSharedWith: [],\n };\n }\n var username = requestOptions.authentication.username, owner = requestOptions.owner, confirmItemControl = requestOptions.confirmItemControl;\n var itemOwner = owner || username;\n // non-item owner\n if (itemOwner !== username) {\n // need to track if the user is an admin\n var isAdmin_1 = false;\n // track if the admin & owner are in the same org\n var isCrossOrgSharing_1 = false;\n // next perform any necessary membership adjustments for\n // current user and/or item owner\n return Promise.all([\n getUser({\n username: username,\n authentication: requestOptions.authentication,\n }),\n getUser({\n username: itemOwner,\n authentication: requestOptions.authentication,\n }),\n getUserMembership(requestOptions),\n ])\n .then(function (_a) {\n var currentUser = _a[0], ownerUser = _a[1], membership = _a[2];\n var isSharedEditingGroup = !!confirmItemControl;\n isAdmin_1 = currentUser.role === \"org_admin\" && !currentUser.roleId;\n isCrossOrgSharing_1 = currentUser.orgId !== ownerUser.orgId;\n return getMembershipAdjustments(currentUser, isSharedEditingGroup, membership, isAdmin_1, ownerUser, requestOptions);\n })\n .then(function (membershipAdjustments) {\n var _a = membershipAdjustments[0], revert = (_a === void 0 ? {\n promise: Promise.resolve({ notAdded: [] }),\n revert: function (sharingResults) {\n return Promise.resolve(sharingResults);\n },\n } : _a).revert;\n // perform all membership adjustments\n return Promise.all(membershipAdjustments.map(function (_a) {\n var promise = _a.promise;\n return promise;\n }))\n .then(function () {\n // then attempt the share\n return shareToGroup(requestOptions, isAdmin_1, isCrossOrgSharing_1);\n })\n .then(function (sharingResults) {\n // lastly, if the admin user was added to the group,\n // remove them from the group. this is a no-op that\n // immediately resolves the sharingResults when no\n // membership adjustment was needed\n return revert(sharingResults);\n });\n });\n }\n // item owner, let it call through\n return shareToGroup(requestOptions);\n })\n .then(function (sharingResponse) {\n if (sharingResponse.notSharedWith.length) {\n throw Error(\"Item \" + requestOptions.id + \" could not be shared to group \" + requestOptions.groupId + \".\");\n }\n else {\n // all is well\n return sharingResponse;\n }\n });\n}\nfunction getMembershipAdjustments(currentUser, isSharedEditingGroup, membership, isAdmin, ownerUser, requestOptions) {\n var membershipGuarantees = [];\n if (requestOptions.groupId !== currentUser.favGroupId) {\n if (isSharedEditingGroup) {\n if (!isAdmin) {\n // abort and reject promise\n throw Error(\"This item can not be shared to shared editing group \" + requestOptions.groupId + \" by \" + currentUser.username + \" as they not the item owner or org admin.\");\n }\n membershipGuarantees.push(\n // admin user must be a group member to share, should be reverted afterwards\n ensureMembership(currentUser, currentUser, false, \"Error adding \" + currentUser.username + \" as member to edit group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\", requestOptions), \n // item owner must be a group admin\n ensureMembership(currentUser, ownerUser, true, membership === \"none\"\n ? \"Error adding user \" + ownerUser.username + \" to edit group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\"\n : \"Error promoting user \" + ownerUser.username + \" to admin in edit group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\", requestOptions));\n }\n else if (isAdmin) {\n // admin user must be a group member to share, should be reverted afterwards\n membershipGuarantees.push(ensureMembership(currentUser, currentUser, false, \"Error adding \" + currentUser.username + \" as member to view group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" was not shared to the group.\", requestOptions));\n }\n else if (membership === \"none\") {\n // all other non-item owners must be a group member\n throw new Error(\"This item can not be shared by \" + currentUser.username + \" as they are not a member of the specified group \" + requestOptions.groupId + \".\");\n }\n }\n return membershipGuarantees;\n}\nfunction shareToGroup(requestOptions, isAdmin, isCrossOrgSharing) {\n if (isAdmin === void 0) { isAdmin = false; }\n if (isCrossOrgSharing === void 0) { isCrossOrgSharing = false; }\n var username = requestOptions.authentication.username;\n var itemOwner = requestOptions.owner || username;\n // decide what url to use\n // default to the non-owner url...\n var url = getPortalUrl(requestOptions) + \"/content/items/\" + requestOptions.id + \"/share\";\n // but if they are the owner, or org_admin, use this route\n // Note: When using this end-point as an admin, apparently the admin does not need to be a member of the group (the itemOwner does)\n // Note: Admin's can only use this route when the item is in the same org they are admin for\n if (itemOwner === username || (isAdmin && !isCrossOrgSharing)) {\n url = getPortalUrl(requestOptions) + \"/content/users/\" + itemOwner + \"/items/\" + requestOptions.id + \"/share\";\n }\n // now its finally time to do the sharing\n requestOptions.params = {\n groups: requestOptions.groupId,\n confirmItemControl: requestOptions.confirmItemControl,\n };\n return request(url, requestOptions);\n}\nexport function ensureMembership(currentUser, ownerUser, shouldPromote, errorMessage, requestOptions) {\n var _a;\n var ownerGroups = ownerUser.groups || [];\n var group = ownerGroups.find(function (g) {\n return g.id === requestOptions.groupId;\n });\n // if they are in different orgs, eject\n if (currentUser.orgId !== ownerUser.orgId) {\n throw Error(\"User \" + ownerUser.username + \" is not a member of the same org as \" + currentUser.username + \". Consequently they can not be added added to group \" + requestOptions.groupId + \" nor can item \" + requestOptions.id + \" be shared to the group.\");\n }\n // if owner is not a member, and has 512 groups\n if (!group && ownerGroups.length > 511) {\n throw Error(\"User \" + ownerUser.username + \" already has 512 groups, and can not be added to group \" + requestOptions.groupId + \". Consequently item \" + requestOptions.id + \" can not be shared to the group.\");\n }\n var promise;\n var revert;\n // decide if we need to add them or upgrade them\n if (group) {\n // they are in the group...\n // check member type\n if (shouldPromote && group.userMembership.memberType === \"member\") {\n // promote them\n promise = updateUserMemberships({\n id: requestOptions.groupId,\n users: [ownerUser.username],\n newMemberType: \"admin\",\n authentication: requestOptions.authentication,\n })\n .then(function (results) {\n // convert the result into the right type\n var notAdded = results.results.reduce(function (acc, entry) {\n if (!entry.success) {\n acc.push(entry.username);\n }\n return acc;\n }, []);\n // and return it\n return Promise.resolve({ notAdded: notAdded });\n })\n .catch(function () { return ({ notAdded: [ownerUser.username] }); });\n revert = function (sharingResults) {\n return updateUserMemberships({\n id: requestOptions.groupId,\n users: [ownerUser.username],\n newMemberType: \"member\",\n authentication: requestOptions.authentication,\n })\n .then(function () { return sharingResults; })\n .catch(function () { return sharingResults; });\n };\n }\n else {\n // they are already an admin in the group\n // return the same response the API would if we added them\n promise = Promise.resolve({ notAdded: [] });\n revert = function (sharingResults) { return Promise.resolve(sharingResults); };\n }\n }\n else {\n // attempt to add user to group\n var userType = shouldPromote ? \"admins\" : \"users\";\n // can't currently determine if the group is within the admin's\n // org without performing a search, so attempt to add and handle\n // the api error\n promise = addGroupUsers((_a = {\n id: requestOptions.groupId\n },\n _a[userType] = [ownerUser.username],\n _a.authentication = requestOptions.authentication,\n _a))\n .then(function (results) {\n // results.errors includes an ArcGISAuthError when the group\n // is in a different org, but notAdded is empty, throw here\n // to normalize the results in below catch\n if (results.errors && results.errors.length) {\n throw results.errors[0];\n }\n return results;\n })\n .catch(function () { return ({ notAdded: [ownerUser.username] }); });\n revert = function (sharingResults) {\n return removeGroupUsers({\n id: requestOptions.groupId,\n users: [ownerUser.username],\n authentication: requestOptions.authentication,\n }).then(function () {\n // always resolves, suppress any resolved errors\n return sharingResults;\n });\n };\n }\n return {\n promise: promise.then(function (membershipResponse) {\n if (membershipResponse.notAdded.length) {\n throw new Error(errorMessage);\n }\n return membershipResponse;\n }),\n revert: revert,\n };\n}\n//# sourceMappingURL=share-item-with-group.js.map","import { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"../util/get-portal-url\";\nimport { getUserMembership } from \"./helpers\";\nimport { isItemSharedWithGroup } from \"./is-item-shared-with-group\";\nimport { getUser } from \"../users/get-user\";\n/**\n * Stop sharing an item with a group, either as an\n * [item owner](https://developers.arcgis.com/rest/users-groups-and-items/unshare-item-as-item-owner-.htm),\n * [group admin](https://developers.arcgis.com/rest/users-groups-and-items/unshare-item-as-group-admin-.htm) or\n * organization admin.\n *\n * ```js\n * import { unshareItemWithGroup } from '@esri/arcgis-rest-portal';\n *\n * unshareItemWithGroup({\n * id: \"abc123\",\n * groupId: \"xyz987\",\n * owner: \"some-owner\",\n * authentication: session\n * })\n * ```\n *\n * @param requestOptions - Options for the request.\n * @returns A Promise that will resolve with the data from the response.\n */\nexport function unshareItemWithGroup(requestOptions) {\n return isItemSharedWithGroup(requestOptions)\n .then(function (isShared) {\n // not shared\n if (!isShared) {\n // exit early with success response\n return Promise.resolve({\n itemId: requestOptions.id,\n shortcut: true,\n notUnsharedFrom: []\n });\n }\n var username = requestOptions.authentication.username, owner = requestOptions.owner;\n // next check if the user is a member of the group\n return Promise.all([\n getUserMembership(requestOptions),\n getUser({\n username: username,\n authentication: requestOptions.authentication\n })\n ])\n .then(function (_a) {\n var membership = _a[0], currentUser = _a[1];\n var itemOwner = owner || username;\n var isItemOwner = itemOwner === username;\n var isAdmin = currentUser.role === 'org_admin' && !currentUser.roleId;\n if (!isItemOwner && !isAdmin && ['admin', 'owner'].indexOf(membership) < 0) {\n // abort and reject promise\n throw Error(\"This item can not be unshared from group \" + requestOptions.groupId + \" by \" + username + \" as they not the item owner, an org admin, group admin or group owner.\");\n }\n // let the sharing call go\n return unshareFromGroup(requestOptions);\n })\n .then(function (sharingResponse) {\n if (sharingResponse.notUnsharedFrom.length) {\n throw Error(\"Item \" + requestOptions.id + \" could not be unshared to group \" + requestOptions.groupId);\n }\n else {\n // all is well\n return sharingResponse;\n }\n });\n });\n}\nfunction unshareFromGroup(requestOptions) {\n var username = requestOptions.authentication.username;\n var itemOwner = requestOptions.owner || username;\n // decide what url to use\n // default to the non-owner url...\n var url = getPortalUrl(requestOptions) + \"/content/items/\" + requestOptions.id + \"/unshare\";\n // but if they are the owner, we use a different path...\n if (itemOwner === username) {\n url = getPortalUrl(requestOptions) + \"/content/users/\" + itemOwner + \"/items/\" + requestOptions.id + \"/unshare\";\n }\n // now its finally time to do the sharing\n requestOptions.params = {\n groups: requestOptions.groupId\n };\n return request(url, requestOptions);\n}\n//# sourceMappingURL=unshare-item-with-group.js.map","/* Copyright (c) 2017-2019 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { getPortalUrl } from \"./get-portal-url\";\n/**\n * Get the portal\n * @param requestOptions\n */\nexport function getSelf(requestOptions) {\n // just delegate to getPortal w/o an id\n return getPortal(null, requestOptions);\n}\n/**\n * ```js\n * import { getPortal } from \"@esri/arcgis-rest-request\";\n * //\n * getPortal()\n * getPortal(\"fe8\")\n * getPortal(null, { portal: \"https://custom.maps.arcgis.com/sharing/rest/\" })\n * ```\n * Fetch information about the specified portal by id. If no id is passed, portals/self will be called.\n * Note that if you intend to request a portal by id and it is different from the portal specified by options.authentication, you must also pass options.portal.\n * @param id\n * @param requestOptions\n */\nexport function getPortal(id, requestOptions) {\n // construct the search url\n var idOrSelf = id ? id : \"self\";\n var url = getPortalUrl(requestOptions) + \"/portals/\" + idOrSelf;\n // default to a GET request\n var options = __assign({ httpMethod: \"GET\" }, requestOptions);\n // send the request\n return request(url, options);\n}\n//# sourceMappingURL=get-portal.js.map","import { getPortalUrl as getPortalApiUrl, } from \"@esri/arcgis-rest-portal\";\n/**\n * ```js\n * import { getPortalUrl } from \"@esri/hub-common\";\n * // from a portal API URL\n * let portalUrl = getPortalUrl(\"https://org.maps.arcgis.com/sharing/rest\"); // https://org.maps.arcgis.com\n * // from an enterprise portal self response (IPortal)\n * let portalSelf = { isPortal: true, portalHostname: \"server.example.org\" };\n * portalUrl = getPortalUrl(portalSelf); // https://server.example.org\n * // from an online portal self response (IPortal)\n * portalSelf = { isPortal: false, urlKey: \"org\", customBaseUrl: \"maps.arcgis.com\" };\n * portalUrl = getPortalUrl(portalSelf); // https://org.maps.arcgis.com\n * // from hub request options (IHubRequestOptions) with a portal self (IPortal)\n * let requestOptions = { isPortal: false, portalSelf };\n * portalUrl = getPortalUrl(requestOptions); // https://org.maps.arcgis.com\n * // from request options (IRequestOptions) with a portal (string)\n * requestOptions = { portal: \"https://org.maps.arcgis.com/sharing/rest\" };\n * portalUrl = getPortalUrl(requestOptions); // https://org.maps.arcgis.com\n * ```\n * Derive a portal's base URL from the portal's API URL, a portal object, or request options\n * @param urlOrObject a portal API URL, a portal object, or request options containing either of those\n * @returns The portal base URL, defaults to `https://www.arcgis.com`\n */\nexport function getPortalUrl(urlOrObject) {\n if (typeof urlOrObject === \"string\") {\n // assume this is the URL of the portal API\n // and strip the `/sharing/rest`\n return urlOrObject.replace(/\\/sharing\\/rest\\/?$/, \"\");\n }\n if (typeof urlOrObject === \"object\") {\n // build URL from portal self object, which could be\n // either a property of the object (request options) or the object itself\n var portalSelf = urlOrObject.portalSelf;\n var portal = portalSelf || urlOrObject;\n var portalHostname = portal.portalHostname, urlKey = portal.urlKey, customBaseUrl = portal.customBaseUrl;\n if (portalHostname || (urlKey && customBaseUrl)) {\n // user passed in a portal object, we'll use that to build the URL\n if (portal.isPortal) {\n return \"https://\" + portal.portalHostname;\n }\n else {\n return \"https://\" + portal.urlKey + \".\" + portal.customBaseUrl;\n }\n }\n }\n // urlOrObj is either undefined, or a request options w/o portal self\n // get portal API URL and parse portal URL from that\n return getPortalUrl(getPortalApiUrl(urlOrObject));\n}\n//# sourceMappingURL=get-portal-url.js.map","/**\n * Mapping between the AGO Env's and the Hub's asset CDNs\n */\nexport var HUB_CDN_URLMAP = {\n devext: \"https://d1011m9qpnz5mw.cloudfront.net\",\n qaext: \"https://dyq9ux9ryu4qj.cloudfront.net\",\n www: \"https://d1iq7pbacwn5rb.cloudfront.net\"\n};\n//# sourceMappingURL=hub-cdn-urlmap.js.map","import { getPortalUrl } from \"./get-portal-url\";\nimport { HUB_CDN_URLMAP } from \"./hub-cdn-urlmap\";\n// TODO: should this take IHubRequestOptions as well as a portal?\n// if so, address when we tackle https://github.com/Esri/hub.js/issues/321\n/**\n * Given a Portal object, return the full Hub locale asset url\n * Used for fetching translations\n * @param {Object} portal Portal Self\n */\nexport function getHubLocaleAssetUrl(portal) {\n if (portal.isPortal) {\n // Enterprise - use Site app as source for assets\n var baseUrl = getPortalUrl(portal);\n return baseUrl + \"/apps/sites\";\n }\n else {\n // AGO - Convert portalHostname into CDN url\n var index = portal.portalHostname.split(\".\")[0];\n var base = HUB_CDN_URLMAP[index] || HUB_CDN_URLMAP.www;\n return base + \"/opendata-ui/assets\";\n }\n}\n//# sourceMappingURL=get-hub-locale-asset-url.js.map","import { getPortalUrl } from \"./get-portal-url\";\n/**\n * ```js\n * import { getPortalApiUrl } from \"@esri/hub-common\";\n * // from a portal base URL\n * let portalApiUrl = getPortalApiUrl(\"https://org.maps.arcgis.com\"); // https://org.maps.arcgis.com/sharing/rest\n * // from an enterprise portal self response (IPortal)\n * let portalSelf = { isPortal: true, portalHostname: \"server.example.org\" };\n * portalApiUrl = getPortalApiUrl(portalSelf); // https://server.example.org/sharing/rest\n * // from an online portal self response (IPortal)\n * portalSelf = { isPortal: false, urlKey: \"org\", customBaseUrl: \"maps.arcgis.com\" };\n * portalApiUrl = getPortalApiUrl(portalSelf); // https://org.maps.arcgis.com/sharing/rest\n * // from hub request options (IHubRequestOptions) with a portal self (IPortal)\n * let requestOptions = { isPortal: false, portalSelf };\n * portalApiUrl = getPortalApiUrl(requestOptions); // https://org.maps.arcgis.com/sharing/rest\n * // from request options (IRequestOptions) with a portal (string)\n * requestOptions = { portal: \"https://org.maps.arcgis.com/sharing/rest\" };\n * portalApiUrl = getPortalApiUrl(requestOptions); // https://org.maps.arcgis.com/sharing/rest\n * ```\n * Derive a portal's API URL from the portal's base URL, a portal object, or request options\n * @param urlOrObject a portal base URL, a portal object, or request options containing either of those\n * @returns The portal API URL, defaults to `https://www.arcgis.com/sharing/rest`\n */\nexport function getPortalApiUrl(urlOrObject) {\n return getPortalUrl(urlOrObject) + \"/sharing/rest\";\n}\n//# sourceMappingURL=get-portal-api-url.js.map","/**\n * Add protocol or upgrade http to https\n * @param {string} url\n */\nexport function upgradeProtocol(url) {\n if (url.indexOf(\"http\") === -1) {\n return \"https://\" + url;\n }\n else if (url.indexOf(\"http://\") !== -1) {\n return url.replace(/^http:/i, \"https:\");\n }\n return url;\n}\n//# sourceMappingURL=upgrade-protocol.js.map","/**\n * Remove protocol if present\n * @param {string} hostname Hostname\n */\nexport function stripProtocol(hostname) {\n hostname = hostname.toLowerCase();\n if (hostname.includes(\"//\")) {\n hostname = hostname.split(\"//\")[1];\n }\n return hostname;\n}\n//# sourceMappingURL=strip-protocol.js.map","/**\n * Given a url without a protocol or with either http or https, return an array\n * that contains both the http and https version\n * @param {string} uri Url with either http or https, or no protocol\n * @private\n */\nexport function _getHttpAndHttpsUris(uri) {\n if (!uri) {\n return [];\n }\n var domain = uri.replace(/^http(s?):\\/\\//, \"\");\n return [\"http://\" + domain, \"https://\" + domain];\n}\n//# sourceMappingURL=_get-http-and-https-uris.js.map","/**\n * Wrapper over window.location\n * @private\n */\n/* istanbul ignore next */\nexport function _getLocation() {\n /* istanbul ignore next */\n if (window) {\n return window.location;\n }\n}\n//# sourceMappingURL=_get-location.js.map","/**\n * Parse the portal url, and if it matches one of the AGO\n * Url patterns, return the correct Hub Url\n * If portalUrl does not match an AGO pattern, this will\n * return `undefined`\n * @param portalUrl\n * @private\n */\nexport function _getHubUrlFromPortalHostname(portalUrl) {\n var result;\n if (portalUrl.match(/(qaext|\\.mapsqa)\\.arcgis.com/)) {\n result = \"https://hubqa.arcgis.com\";\n }\n else if (portalUrl.match(/(devext|\\.mapsdevext)\\.arcgis.com/)) {\n result = \"https://hubdev.arcgis.com\";\n }\n else if (portalUrl.match(/(www|\\.maps)\\.arcgis.com/)) {\n result = \"https://hub.arcgis.com\";\n }\n return result;\n}\n//# sourceMappingURL=_get-hub-url-from-portal-hostname.js.map","import { _getHubUrlFromPortalHostname } from \"./_get-hub-url-from-portal-hostname\";\n/**\n * Return the Hub Url based on the portal self\n * @param portal\n */\nexport function getHubUrlFromPortal(portal) {\n if (portal.isPortal) {\n throw new Error(\"Hub Url is not available in ArcGIS Enterprise\");\n }\n else {\n return _getHubUrlFromPortalHostname(portal.portalHostname);\n }\n}\n//# sourceMappingURL=get-hub-url-from-portal.js.map","import { getHubUrlFromPortal } from \"./get-hub-url-from-portal\";\n/**\n * Return the Portal url based on the portal self\n * @param {Object} portal Portal Self\n */\nexport function getHubApiUrlFromPortal(portal) {\n return getHubUrlFromPortal(portal) + \"/api/v3\";\n}\n//# sourceMappingURL=get-hub-api-url-from-portal.js.map","import { getPortalUrl } from \"./get-portal-url\";\n/**\n * Return the URL of the item's page in the Portal Home application\n * @param itemId The item's ID\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @returns URL to the item's data REST end point, defaults to `https://www.arcgis.com/home/item.html?id={item.id}`\n */\nexport function getItemHomeUrl(itemId, portalUrlOrObject) {\n var portalUrl = getPortalUrl(portalUrlOrObject);\n return portalUrl + \"/home/item.html?id=\" + itemId;\n}\n//# sourceMappingURL=get-item-home-url.js.map","import { getPortalApiUrl } from \"./get-portal-api-url\";\n// NOTE: this fn is tested via getItemDataUrl tests\n/**\n * Get the fully qualified URL to the REST end point for an item.\n * @param item w/ id and access\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @param token token for the current user's session; will only be appended as a query parameter if the item's access is **not** `public`\n * @returns URL to the item's REST end point, defaults to `https://www.arcgis.com/sharing/rest/content/items/{item.id}?f=json`\n */\nexport var getItemApiUrl = function (item, portalUrlOrObject, token) {\n var id = item.id, access = item.access;\n var url = getPortalApiUrl(portalUrlOrObject) + \"/content/items/\" + id;\n var params = new URLSearchParams({ f: \"json\" });\n if (access !== \"public\" && token) {\n params.append(\"token\", token);\n }\n return url + \"?\" + params.toString();\n};\n//# sourceMappingURL=get-item-api-url.js.map","import { getItemApiUrl } from \"./get-item-api-url\";\n/**\n * Get the fully qualified URL to the data REST end point for an item\n * @param item w/ id and access\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @param token token for the current user's session; will only be appended as a query parameter if the item's access is **not** `public`\n * @returns URL to the item's data REST end point, defaults to `https://www.arcgis.com/sharing/rest/content/items/{item.id}/data`\n */\nexport var getItemDataUrl = function (item, portalUrlOrObject, token) {\n var url = getItemApiUrl(item, portalUrlOrObject, token);\n var pattern = \"\\\\/\" + item.id + \"\\\\?f=json\";\n var regExp = new RegExp(pattern);\n // TODO: re-append f param based on item.type?\n return (url && url.replace(regExp, \"/\" + item.id + \"/data\").replace(/\\&token/, \"?token\"));\n};\n//# sourceMappingURL=get-item-data-url.js.map","/**\n * Convert urls in a string to hyperlinks\n * @param {content} string\n */\nexport function convertUrlsToAnchorTags(content) {\n var urls = content.match(/((((ftp|https?):\\/\\/)|(w{3}\\.))[-\\w@:%_+.~#?,&//=]+)/g);\n if (urls) {\n urls.forEach(function (url) {\n content = content.replace(url, '<a target=\"_blank\" href=\"' + url + '\">' + url + \"</a>\");\n });\n }\n return content.replace(\"(\", \"<br/>(\");\n}\n//# sourceMappingURL=convert-urls-to-anchor-tags.js.map","import { capitalize } from \"../util\";\nexport * from \"./build-url\";\nexport * from \"./get-hub-locale-asset-url\";\nexport * from \"./get-portal-api-url\";\nexport * from \"./get-portal-url\";\nexport * from \"./hub-cdn-urlmap\";\nexport * from \"./upgrade-protocol\";\nexport * from \"./strip-protocol\";\nexport * from \"./_get-http-and-https-uris\";\nexport * from \"./_get-location\";\nexport * from \"./get-hub-api-url-from-portal\";\nexport * from \"./get-hub-url-from-portal\";\nexport * from \"./get-item-home-url\";\nexport * from \"./get-item-api-url\";\nexport * from \"./get-item-data-url\";\nexport * from \"./convert-urls-to-anchor-tags\";\nvar MAP_OR_FEATURE_SERVER_URL_REGEX = /\\/(map|feature)server/i;\n/**\n *\n * @param url\n * @returns true if the url is of a map or feature service\n */\nexport var isMapOrFeatureServerUrl = function (url) {\n return MAP_OR_FEATURE_SERVER_URL_REGEX.test(url);\n};\n/**\n * parses map or feature service type from URL\n * @param url map or feature service URL\n * @returns item type, either \"Map Service\" or \"Feature Service\"\n * or undefined for other types of URLs\n */\nexport var getServiceTypeFromUrl = function (url) {\n var match = url.match(MAP_OR_FEATURE_SERVER_URL_REGEX);\n var mapOrFeature = match && match[1];\n return mapOrFeature && capitalize(mapOrFeature) + \" Service\";\n};\n//# sourceMappingURL=index.js.map","import { getPortalApiUrl } from \"./urls\";\nimport { _getHubUrlFromPortalHostname } from \"./urls/_get-hub-url-from-portal-hostname\";\n/**\n * ```js\n * import { getHubApiUrl() } from \"@esri/hub-common\";\n * //\n * getHubApiUrl({ portal: \"https://custom.maps.arcgis.com/sharing/rest\" })\n * >> \"https://hub.arcgis.com\"\n * ```\n * Retrieves the Hub API Url associated with a specific ArcGIS Online organization.\n * @param urlOrObject a Portal URL, Portal API URL, request options object, or Portal self object\n * @returns the associated Hub API Url as a string.\n */\nexport function getHubApiUrl(urlOrObject) {\n var hubApiUrl = urlOrObject && urlOrObject.hubApiUrl;\n if (hubApiUrl) {\n // this is request options w/ hubApiUrl already defined\n return hubApiUrl;\n }\n return _getHubUrlFromPortalHostname(getPortalApiUrl(urlOrObject));\n}\n//# sourceMappingURL=api.js.map","/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { request } from \"@esri/arcgis-rest-request\";\nimport { UserSession } from \"@esri/arcgis-rest-auth\";\n/**\n * A thin wrapper around [`UserSession.completeOAuth2()`](https://esri.github.io/arcgis-rest-js/api/auth/UserSession/#completeOAuth2) that sets search tags and other relevant metadata for newly created community users.\n */\n/* istanbul ignore next */\nexport function completeOAuth2(options, win) {\n if (win === void 0) { win = window; }\n var match = win.location.href.match(/access_token=(.+)&expires_in=.+&username=([^&]+)/);\n var token = match[1];\n var user = decodeURIComponent(match[2]);\n var baseUrl = \"https://www.arcgis.com/sharing/rest/community/users/\" + user;\n return request(baseUrl, {\n params: { token: token },\n httpMethod: \"GET\"\n }).then(function (response) {\n if (Date.now() - response.created < 5000) {\n return request(baseUrl + \"/update\", {\n params: {\n token: token,\n tags: [\"hubRole:participant\", \"org:\" + response.orgId],\n access: \"public\"\n }\n }).then(function () {\n return UserSession.completeOAuth2(options);\n });\n }\n else {\n return UserSession.completeOAuth2(options);\n }\n });\n}\n//# sourceMappingURL=auth.js.map","var app = [\n \"Application\",\n \"City Engine Web Scene\",\n \"CityEngine Web Scene\",\n \"Dashboard\",\n \"Insights Page\",\n \"Insights Workbook\",\n \"Operation View\",\n \"Web Mapping Application\",\n \"StoryMap\",\n \"Web Experience\",\n \"Urban Model\",\n];\nvar dataset = [\n \"CSV Collection\",\n \"CSV\",\n \"Feature Collection Template\",\n \"Feature Collection\",\n \"Feature Layer\",\n \"Feature Service\",\n \"File Geodatabase\",\n \"GeoJSON\",\n \"GeoJson\",\n \"KML Collection\",\n \"KML\",\n \"Microsoft Excel\",\n \"Raster Layer\",\n \"Shapefile\",\n \"Stream Service\",\n \"Table\",\n];\nvar document = [\n \"CAD Drawing\",\n \"Document Link\",\n \"Hub Page\",\n \"Site Page\",\n \"Image\",\n \"iWork Keynote\",\n \"iWork Numbers\",\n \"iWork Pages\",\n \"Microsoft Powerpoint\",\n \"Microsoft Visio\",\n \"Microsoft Word\",\n \"Notebook\",\n \"PDF\",\n \"Pro Map\",\n \"Report Template\",\n];\nvar event = [\"Hub Event\"];\nvar feedback = [\"Form\", \"Quick Capture Project\"];\nvar initiative = [\"Hub Initiative\"];\nvar solution = [\"Solution\"];\nvar template = [\"Hub Initiative Template\"];\nvar map = [\n \"Image Collection\",\n \"Image Service\",\n \"Map Service Layer\",\n \"Map Service\",\n \"Scene Service\",\n \"Scene Layer\",\n \"Vector Tile Service\",\n \"Web Map Service\",\n \"Web Map Tile Service\",\n \"Web Map\",\n \"Web Scene\",\n \"WFS\",\n \"WMS\",\n \"WMTS\",\n];\nvar other = [\n \"360 VR Experience\",\n \"AppBuilder Widget Package\",\n \"Application Configuration\",\n \"ArcPad Package\",\n \"Code Attachment\",\n \"Code Sample\",\n \"Desktop Add In\",\n \"Desktop Application Template\",\n \"Desktop Application\",\n \"Desktop Style\",\n \"Explorer Add In\",\n \"Explorer Layer\",\n \"Geocoding Service\",\n \"Geometry Service\",\n \"Geoprocessing Package\",\n \"Geoprocessing Sample\",\n \"Geoprocessing Service\",\n \"Layer File\",\n \"Layer Package\",\n \"Layer Template\",\n \"Layer\",\n \"Layout\",\n \"Locator Package\",\n \"Map Area\",\n \"Map Document\",\n \"Map Package\",\n \"Map Service Definition\",\n \"Map Template\",\n \"Mobile Application\",\n \"Mobile Map Package\",\n \"Native Application\",\n \"Network Analysis Service\",\n \"Operations Dashboard Add In\",\n \"Project Package\",\n \"Project Template\",\n \"Raster Function Template\",\n \"Rule Package\",\n \"Scene Package\",\n \"Service Definition\",\n \"SQLite Geodatabase\",\n \"Style\",\n \"Tile Package\",\n \"Vector Tile Package\",\n \"Workflow Manager Package\",\n];\nvar site = [\"Hub Site Application\", \"Site Application\"];\nexport var collections = {\n app: app,\n dataset: dataset,\n document: document,\n event: event,\n feedback: feedback,\n initiative: initiative,\n template: template,\n solution: solution,\n map: map,\n other: other,\n site: site,\n};\n//# sourceMappingURL=collections.js.map","import { collections } from \"./collections\";\nvar app = collections.app, dataset = collections.dataset, document = collections.document, event = collections.event, feedback = collections.feedback, initiative = collections.initiative, map = collections.map, other = collections.other, site = collections.site;\nvar downloadableTypes = [\n \"360 VR Experience\",\n \"Application\",\n \"CityEngine Web Scene\",\n \"Code Sample\",\n \"CSV Collection\",\n \"CSV\",\n \"CAD Drawing\",\n \"Desktop Application\",\n \"Desktop Application Template\",\n \"Desktop Style\",\n \"File Geodatabase\",\n \"GeoJson\",\n \"Geoprocessing Package\",\n \"Geoprocessing Sample\",\n \"Image\",\n \"iWork Keynote\",\n \"iWork Numbers\",\n \"KML Collection\",\n \"KML\",\n \"Layer\",\n \"Layer File\",\n \"Layer Package\",\n \"Layout\",\n \"Locator Package\",\n \"Map Package\",\n \"Map Service Definition\",\n \"Map Template\",\n \"Microsoft Excel\",\n \"Microsoft Powerpoint\",\n \"Microsoft Visio\",\n \"Microsoft Word\",\n \"Notebook\",\n \"Operations Dashboard Add In\",\n \"PDF\",\n \"Pro Map\",\n \"Project Package\",\n \"Project Template\",\n \"Raster function template\",\n \"Rule Package\",\n \"Service Definition\",\n \"Shapefile\",\n \"Vector Tile Package\",\n \"Workflow Manager Package\",\n];\nvar downloadableTypeKeywords = [\"Data\"];\nvar apiTypes = [\"Feature Service\", \"Map Service\", \"Image Service\"];\n// TODO: remove this at next breaking version\n// we're just keeping this for backwards compatibility\nexport var categories = {\n app: app.concat(feedback),\n dataset: dataset,\n document: document,\n event: event,\n initiative: initiative,\n map: map,\n other: other,\n site: site,\n downloadableTypes: downloadableTypes,\n downloadableTypeKeywords: downloadableTypeKeywords,\n apiTypes: apiTypes,\n};\n// TODO: move this function and supporting arrays to another module\n/**\n * Is the item type downloadable in the Hub app\n * @param item ArcGIS item with type and type keywords\n */\nexport function isDownloadable(item) {\n return (downloadableTypes.indexOf(item.type) !== -1 ||\n (item.typeKeywords &&\n downloadableTypeKeywords.some(function (downloadableTypeKeyword) {\n return item.typeKeywords.some(function (typeKeyword) { return typeKeyword === downloadableTypeKeyword; });\n })));\n}\n//# sourceMappingURL=categories.js.map","import { getProp } from \"./objects\";\nimport { request } from \"@esri/arcgis-rest-request\";\nexport function createExtent(xmin, ymin, xmax, ymax, wkid) {\n if (wkid === void 0) { wkid = 4326; }\n return {\n xmin: xmin,\n ymin: ymin,\n xmax: xmax,\n ymax: ymax,\n // type: 'extent',\n spatialReference: {\n wkid: wkid,\n },\n };\n}\n/**\n * Turns an extent into a bbox\n * @param envelope extent\n */\nexport function extentToBBox(envelope) {\n return [\n [envelope.xmin, envelope.ymin],\n [envelope.xmax, envelope.ymax],\n ];\n}\nexport var GLOBAL_EXTENT = {\n xmin: -180,\n ymin: -90,\n xmax: 180,\n ymax: 90,\n spatialReference: {\n wkid: 4326,\n },\n};\n/**\n * Gets the geographic extent for an org\n * @param hubRequestOptions\n */\nexport function getGeographicOrgExtent(hubRequestOptions) {\n var portal = hubRequestOptions.portalSelf;\n var orgExtent = portal.defaultExtent;\n var geometryServiceUrl = getProp(portal, \"helperServices.geometry.url\");\n // Define a default global extent object\n if (!geometryServiceUrl) {\n return Promise.resolve(GLOBAL_EXTENT);\n }\n if (!orgExtent) {\n return Promise.resolve(GLOBAL_EXTENT);\n }\n var url = geometryServiceUrl + \"/project\";\n // geometry params...\n var geometryParam = {\n geometryType: \"esriGeometryEnvelope\",\n geometries: [orgExtent],\n };\n var options = {\n httpMethod: \"POST\",\n params: {\n geometries: JSON.stringify(geometryParam),\n transformForward: false,\n transformation: \"\",\n inSR: orgExtent.spatialReference.wkid,\n outSR: 4326,\n f: \"json\",\n },\n };\n // add in auth if it's passed\n if (hubRequestOptions.authentication) {\n options.authentication = hubRequestOptions.authentication;\n }\n return request(url, options)\n .then(function (response) {\n var geom = response.geometries[0];\n return {\n xmin: geom.xmin,\n ymin: geom.ymin,\n xmax: geom.xmax,\n ymax: geom.ymax,\n spatialReference: {\n wkid: 4326,\n },\n };\n })\n .catch(function (ex) {\n return GLOBAL_EXTENT;\n });\n}\n/**\n * Get the default org extent as a bbox for use on item.extent\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getOrgExtentAsBBox(hubRequestOptions) {\n return getGeographicOrgExtent(hubRequestOptions).then(function (extent) {\n return extentToBBox(extent);\n });\n}\n/**\n * checks if the extent is a valid BBox (2 element array of coordinate pair arrays)\n * @param extent\n * @returns\n */\nexport var isBBox = function (extent) {\n return (Array.isArray(extent) &&\n Array.isArray(extent[0]) &&\n Array.isArray(extent[1]));\n};\nexport function isExtentCoordinateArray(extent) {\n /* tslint:disable no-console */\n console.warn(\"DEPRECATED: use isBBox() instead\");\n /* tslint:enable no-console */\n return isBBox(extent);\n}\nfunction isExtentJSON(extent) {\n return [\"xmin\", \"ymin\", \"xmax\", \"ymax\"].every(function (key) { return typeof extent[key] === \"number\"; });\n}\n/**\n * Check if the given extent is in a known format\n * @param {Object} extent extent in any format\n * @return {Boolean} indicator\n */\nexport function isValidExtent(extent) {\n return (!!extent &&\n [isExtentCoordinateArray, isExtentJSON].some(function (test) { return test(extent); }));\n}\nexport var bBoxToPolygon = function (bBox) {\n var _a = bBox[0], xmin = _a[0], ymin = _a[1], _b = bBox[1], xmax = _b[0], ymax = _b[1];\n var rings = [\n [\n [xmin, ymin],\n [xmax, ymin],\n [xmax, ymax],\n [xmin, ymax],\n [xmin, ymin],\n ],\n ];\n var wkid = 4326;\n return {\n rings: rings,\n spatialReference: {\n wkid: wkid,\n },\n };\n};\n//# sourceMappingURL=extent.js.map","export var STANDARD_LICENSES = [\n {\n type: \"CC0-1.0\",\n abbr: \"CC0\",\n name: \"Public Domain Dedication\",\n url: \"http://creativecommons.org/publicdomain/zero/1.0\",\n },\n {\n type: \"CC-BY-4.0\",\n abbr: \"CC BY\",\n name: \"Attribution 4.0 International\",\n url: \"http://creativecommons.org/licenses/by/4.0\",\n },\n {\n type: \"CC-BY-3.0\",\n abbr: \"CC BY 3.0\",\n name: \"Attribution 3.0 Unported\",\n url: \"http://creativecommons.org/licenses/by/3.0\",\n },\n {\n type: \"CC-BY-2.5\",\n abbr: \"CC BY 2.5\",\n name: \"Attribution 2.5 Generic\",\n url: \"http://creativecommons.org/licenses/by/2.5\",\n },\n {\n type: \"CC-BY-2.0\",\n abbr: \"CC BY 2.0\",\n name: \"Attribution 2.0 Generic\",\n url: \"http://creativecommons.org/licenses/by/2.0\",\n },\n {\n type: \"CC-BY-1.0\",\n abbr: \"CC BY 1.0\",\n name: \"Attribution 1.0 Generic\",\n url: \"http://creativecommons.org/licenses/by/1.0\",\n },\n {\n type: \"CC-BY-SA-4.0\",\n abbr: \"CC BY-SA\",\n name: \"Attribution-ShareAlike 4.0 International\",\n url: \"http://creativecommons.org/licenses/by-sa/4.0\",\n },\n {\n type: \"CC-BY-SA-3.0\",\n abbr: \"CC BY-SA 3.0\",\n name: \"Attribution-ShareAlike 3.0 Unported\",\n url: \"http://creativecommons.org/licenses/by-sa/3.0\",\n },\n {\n type: \"CC-BY-SA-2.5\",\n abbr: \"CC BY-SA 2.5\",\n name: \"Attribution-ShareAlike 2.5 Generic\",\n url: \"http://creativecommons.org/licenses/by-sa/2.5\",\n },\n {\n type: \"CC-BY-SA-2.0\",\n abbr: \"CC BY-SA 2.0\",\n name: \"Attribution-ShareAlike 2.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-sa/2.0\",\n },\n {\n type: \"CC-BY-SA-1.0\",\n abbr: \"CC BY-SA 1.0\",\n name: \"Attribution-ShareAlike 1.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-sa/1.0\",\n },\n {\n type: \"CC-BY-ND-4.0\",\n abbr: \"CC BY-ND\",\n name: \"Attribution-NoDerivatives 4.0 International\",\n url: \"http://creativecommons.org/licenses/by-nd/4.0\",\n },\n {\n type: \"CC-BY-ND-3.0\",\n abbr: \"CC BY-ND 3.0\",\n name: \"Attribution-NoDerivs 3.0 Unported\",\n url: \"http://creativecommons.org/licenses/by-nd/3.0\",\n },\n {\n type: \"CC-BY-ND-2.5\",\n abbr: \"CC BY-ND 2.5\",\n name: \"Attribution-NoDerivs 2.5 Generic\",\n url: \"http://creativecommons.org/licenses/by-nd/2.5\",\n },\n {\n type: \"CC-BY-ND-2.0\",\n abbr: \"CC BY-ND 2.0\",\n name: \"Attribution-NoDerivs 2.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-nd/2.0\",\n },\n {\n type: \"CC-BY-ND-1.0\",\n abbr: \"CC BY-ND 1.0\",\n name: \"Attribution-NoDerivs 1.0 Generic\",\n url: \"http://creativecommons.org/licenses/by-nd/1.0\",\n },\n {\n type: \"CC-BY-NC-4.0\",\n abbr: \"CC BY-NC\",\n name: \"Attribution-NonCommercial 4.0 International\",\n url: \"https://creativecommons.org/licenses/by-nc/4.0\",\n },\n {\n type: \"CC-BY-NC-3.0\",\n abbr: \"CC BY-NC 3.0\",\n name: \"Attribution-NonCommercial 3.0 Unported\",\n url: \"https://creativecommons.org/licenses/by-nc/3.0\",\n },\n {\n type: \"CC-BY-NC-2.5\",\n abbr: \"CC BY-NC 2.5\",\n name: \"Attribution-NonCommercial 2.5 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc/2.5\",\n },\n {\n type: \"CC-BY-NC-2.0\",\n abbr: \"CC BY-NC 2.0\",\n name: \"Attribution-NonCommercial 2.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc/2.0\",\n },\n {\n type: \"CC-BY-NC-1.0\",\n abbr: \"CC BY-NC 1.0\",\n name: \"Attribution-NonCommercial 1.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc/1.0\",\n },\n {\n type: \"CC-BY-NC-SA-4.0\",\n abbr: \"CC BY-NC-SA\",\n name: \"Attribution-NonCommercial-ShareAlike 4.0 International\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/4.0\",\n },\n {\n type: \"CC-BY-NC-SA-3.0\",\n abbr: \"CC BY-NC-SA 3.0\",\n name: \"Attribution-NonCommercial-ShareAlike 3.0 Unported\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/3.0\",\n },\n {\n type: \"CC-BY-NC-SA-2.5\",\n abbr: \"CC BY-NC-SA 2.5\",\n name: \"Attribution-NonCommercial-ShareAlike 2.5 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/2.5\",\n },\n {\n type: \"CC-BY-NC-SA-2.0\",\n abbr: \"CC BY-NC-SA 2.0\",\n name: \"Attribution-NonCommercial-ShareAlike 2.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/2.0\",\n },\n {\n type: \"CC-BY-NC-SA-1.0\",\n abbr: \"CC BY-NC-SA 1.0\",\n name: \"Attribution-NonCommercial-ShareAlike 1.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-sa/1.0\",\n },\n {\n type: \"CC-BY-NC-ND-4.0\",\n abbr: \"CC BY-NC-ND\",\n name: \"Attribution-NonCommercial-NoDerivatives 4.0 International\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/4.0\",\n },\n {\n type: \"CC-BY-NC-ND-3.0\",\n abbr: \"CC BY-NC-ND 3.0\",\n name: \"Attribution-NonCommercial-NoDerivs 3.0 Unported\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/3.0\",\n },\n {\n type: \"CC-BY-NC-ND-2.5\",\n abbr: \"CC BY-NC-ND 2.5\",\n name: \"Attribution-NonCommercial-NoDerivs 2.5 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/2.5\",\n },\n {\n type: \"CC-BY-NC-ND-2.0\",\n abbr: \"CC BY-NC-ND 2.0\",\n name: \"Attribution-NonCommercial-NoDerivs 2.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/2.0\",\n },\n {\n type: \"CC-BY-NC-ND-1.0\",\n abbr: \"CC BY-NC-ND 1.0\",\n name: \"Attribution-NonCommercial-NoDerivs 1.0 Generic\",\n url: \"https://creativecommons.org/licenses/by-nc-nd/1.0\",\n },\n {\n type: \"PDDL-1.0\",\n abbr: \"PDDL\",\n name: \"ODC Public Domain Dedication and License\",\n url: \"http://opendatacommons.org/licenses/pddl/summary\",\n },\n {\n type: \"ODbL-1.0\",\n abbr: \"ODbL\",\n name: \"ODC Open Database License\",\n url: \"http://opendatacommons.org/licenses/odbl/summary\",\n },\n {\n type: \"ODC-BY-1.0\",\n abbr: \"ODC BY\",\n name: \"ODC Attribution License\",\n url: \"http://opendatacommons.org/licenses/by/summary\",\n },\n];\n/**\n * generates the structured license of an item based on its\n * configured \"licenseInfo\"\n * @param rawLicense an item's raw licenseInfo string\n * @returns {IStructuredLicense}\n */\nexport function getStructuredLicense(rawLicense) {\n var structuredLicense;\n rawLicense = rawLicense || \"\";\n // (1) start by assuming it's either a custom license, or, if there's no\n // raw license, then there's no license at all\n structuredLicense = {\n type: rawLicense ? \"custom\" : \"none\",\n text: rawLicense,\n };\n // (2) Check for standard licenses: If the name, abbr, or url of any standard\n // license is in the raw license text, we assume that is the license.\n var hasStandardLicense = false;\n var matchingStandardLicenses = STANDARD_LICENSES.filter(function (standardLicense) {\n return licenseTextContainsStandardLicenseAttributes(rawLicense, standardLicense);\n });\n if (matchingStandardLicenses.length) {\n hasStandardLicense = true;\n structuredLicense = matchingStandardLicenses.pop();\n }\n // (3) if not a standard license, we check if the raw license is a url or link\n if (!hasStandardLicense) {\n var url = void 0;\n // a. check if the the raw license is simply a url\n if (isParseableAsURL(rawLicense)) {\n url = rawLicense;\n }\n // b. check if the raw license is simply a link (i.e. an anchor tag with an href)\n else if (isSingleAnchorWithHrefAttribute(rawLicense)) {\n var hrefRegex = new RegExp(/href\\s?=\\s?[\"'](.*?)[\"']/);\n var match = rawLicense.match(hrefRegex);\n var href = match[1];\n url = href;\n }\n if (url) {\n structuredLicense.url = url;\n structuredLicense.text = \"\";\n }\n }\n if (!structuredLicense.text)\n delete structuredLicense.text;\n return structuredLicense;\n}\n/**\n * helper function to determine if a raw license is one of the standard licenses.\n * We say it is if the raw license includes the name, url or abbreviation of the\n * standard license\n * @param rawLicense an item's raw licenseInfo string\n * @param standardLicense one of the standard licenses\n * @returns {boolean}\n */\nfunction licenseTextContainsStandardLicenseAttributes(rawLicense, standardLicense) {\n rawLicense = rawLicense.toLowerCase();\n return (rawLicense.includes(standardLicense.name.toLowerCase()) ||\n rawLicense.includes(standardLicense.url.toLowerCase()) ||\n rawLicense.includes(standardLicense.abbr.toLowerCase()));\n}\n/**\n * helper function to determine if an input string can be parsed\n * as a URL with a protocol\n * @param value string to check\n * @returns {boolean}\n */\nfunction isParseableAsURL(value) {\n try {\n var url = new URL(value);\n return !!url.protocol;\n }\n catch (err) {\n // just return fals if the URL couldn't be parsed\n return false;\n }\n}\n/**\n * helper function to determine if the raw license is simply a link, i.e. a single\n * anchor tag with an href attribute: <a href=\"https://google.com\">Click</a> or <a href=\"https://google.com\" />\n * @param rawLicense an item's raw licenseInfo string\n * @returns {boolean}\n */\nfunction isSingleAnchorWithHrefAttribute(rawLicense) {\n var isSingleAnchorTagRegex = new RegExp(/^<a[\\s]+(href\\s?=\\s?[\"'].*?[\"'])+([^>]?)>((?:.(?!\\<\\/a\\>))*.)?<\\/a>$|^<a[\\s]+(href\\s?=\\s?[\"'].*?[\"'])+([^>]?)\\/>/);\n return isSingleAnchorTagRegex.test(rawLicense);\n}\n//# sourceMappingURL=get-structured-license.js.map","/**\n * Use this module for functions that do not need to be used by consumers (yet),\n * but may be shared between hub.js modules, and/or need to be tested\n * to get 100% coverage w/o writing cumbersome tests of higher level functions.\n *\n * Consuming will not be able to import these functions.\n *\n * It's probably a good pattern to add functions here first and then\n * move them to index.ts only when they are needed by a consumer.\n */\nimport { __assign } from \"tslib\";\nimport { bBoxToPolygon, isBBox } from \"../extent\";\n/**\n * Create a new content with updated boundary properties\n * @param content original content\n * @param boundary boundary provenance\n * @returns\n */\nexport var setContentBoundary = function (content, boundary) {\n // update content's item and boundary\n var properties = __assign(__assign({}, (content.item.properties || {})), { boundary: boundary });\n var item = __assign(__assign({}, content.item), { properties: properties });\n var updated = __assign(__assign({}, content), { item: item });\n return __assign(__assign({}, updated), { boundary: getContentBoundary(updated) });\n};\n/**\n * Create a new content with updated extent and derived properties like boundary\n * @param content original content\n * @param extent new extent\n * @returns a new content with the updated extent and boundary\n */\nexport var setContentExtent = function (content, extent) {\n // update content's item and extent\n var item = __assign(__assign({}, content.item), { extent: extent });\n var updated = __assign(__assign({}, content), { item: item, extent: extent });\n // derive boundary from content properties\n var boundary = getContentBoundary(updated);\n return __assign(__assign({}, updated), { boundary: boundary });\n};\nvar getContentBoundary = function (content) {\n var _a;\n var item = content.item;\n var extent = item.extent;\n var isValidItemExtent = isBBox(extent);\n // user specified provenance is stored in item.properties\n var provenance = ((_a = item.properties) === null || _a === void 0 ? void 0 : _a.boundary) ||\n // but we default to item if the item has an extent\n (isValidItemExtent ? \"item\" : undefined);\n var geometry;\n switch (provenance) {\n case \"item\":\n geometry = isValidItemExtent ? bBoxToPolygon(extent) : null;\n break;\n case \"none\":\n geometry = null;\n break;\n // TODO: handle other provenances\n }\n // TODO: derive and return center\n return {\n provenance: provenance,\n geometry: geometry,\n };\n};\n//# sourceMappingURL=_internal.js.map","import { __assign, __spreadArrays } from \"tslib\";\nimport { collections } from \"../collections\";\nimport { categories as allCategories, isDownloadable } from \"../categories\";\nimport { isBBox } from \"../extent\";\nimport { includes, isGuid } from \"../utils\";\nimport { getProp } from \"../objects\";\nimport { getStructuredLicense } from \"../items/get-structured-license\";\nimport { getServiceTypeFromUrl } from \"../urls\";\nimport { setContentExtent } from \"./_internal\";\nimport { camelize } from \"../util\";\nfunction collectionToFamily(collection) {\n var overrides = {\n other: \"content\",\n solution: \"template\",\n };\n return overrides[collection] || collection;\n}\nvar cache = {};\n// TODO: remove this at next breaking version\n/**\n * ```js\n * import { getCategory } from \"@esri/hub-common\";\n * //\n * getCategory('Feature Layer')\n * > 'dataset'\n * ```\n * **DEPRECATED: Use getCollection() instead**\n * returns the Hub category for a given item type\n * @param itemType The ArcGIS [item type](https://developers.arcgis.com/rest/users-groups-and-items/items-and-item-types.htm).\n * @returns the category of a given item type.\n */\nexport function getCategory(itemType) {\n if (itemType === void 0) { itemType = \"\"; }\n /* tslint:disable no-console */\n console.warn(\"DEPRECATED: Use getCollection() instead. getCategory will be removed at v10.0.0\");\n /* tslint:enable no-console */\n var collection = getCollection(itemType);\n // for backwards compatibility\n return collection === \"feedback\" ? \"app\" : collection;\n}\n/**\n * ```js\n * import { getTypes } from \"@esri/hub-common\";\n * //\n * getTypes('site')\n * > [ 'hub site application' ]\n * ```\n * To do.\n * @param category The ArcGIS Hub category.\n * @returns all the item types for the given category.\n *\n */\nexport function getTypes(category) {\n if (category === void 0) { category = \"\"; }\n return allCategories[category.toLowerCase()];\n}\n/**\n * ```js\n * import { normalizeItemType } from \"@esri/hub-common\";\n * //\n * normalizeItemType(item)\n * > [ 'Hub Site Application' ]\n * ```\n * @param item Item object.\n * @returns type of the input item.\n *\n */\nexport function normalizeItemType(item) {\n if (item === void 0) { item = {}; }\n var ret = item.type;\n var typeKeywords = item.typeKeywords || [];\n if (item.type === \"Site Application\" ||\n (item.type === \"Web Mapping Application\" &&\n includes(typeKeywords, \"hubSite\"))) {\n ret = \"Hub Site Application\";\n }\n if (item.type === \"Site Page\" ||\n (item.type === \"Web Mapping Application\" &&\n includes(typeKeywords, \"hubPage\"))) {\n ret = \"Hub Page\";\n }\n if (item.type === \"Hub Initiative\" &&\n includes(typeKeywords, \"hubInitiativeTemplate\")) {\n ret = \"Hub Initiative Template\";\n }\n if (item.type === \"Web Mapping Application\" &&\n includes(typeKeywords, \"hubSolutionTemplate\")) {\n ret = \"Solution\";\n }\n return ret;\n}\n/**\n * ```js\n * import { getTypeCategories } from \"@esri/hub-common\";\n * //\n * getTypeCategories(item)\n * > [ 'Hub Site Application' ]\n * ```\n * @param item Item object.\n * @returns typeCategory of the input item.\n *\n */\nexport function getTypeCategories(item) {\n if (item === void 0) { item = {}; }\n var type = normalizeItemType(item);\n var category = getCategory(type);\n if (category) {\n // upper case first letter and return as element in array for backwards compatibility\n var chars = Array.from(category);\n chars[0] = chars[0].toUpperCase();\n return [chars.join(\"\")];\n }\n else {\n return [\"Other\"];\n }\n}\n/**\n * ```js\n * import { getCollection } from \"@esri/hub-common\";\n * //\n * getCollection('Feature Layer')\n * > 'dataset'\n * ```\n * Get the Hub collection for a given item type\n * @param itemType The ArcGIS [item type](https://developers.arcgis.com/rest/users-groups-and-items/items-and-item-types.htm).\n * @returns the Hub collection of a given item type.\n */\nexport function getCollection(itemType) {\n if (itemType === void 0) { itemType = \"\"; }\n if (cache[itemType]) {\n return cache[itemType];\n }\n for (var _i = 0, _a = Object.keys(collections); _i < _a.length; _i++) {\n var collection = _a[_i];\n for (var _b = 0, _c = collections[collection]; _b < _c.length; _b++) {\n var type = _c[_b];\n if (itemType.toLowerCase() === type.toLowerCase()) {\n cache[itemType] = collection;\n return collection;\n }\n }\n }\n}\n/**\n * Case-insensitive check if the type is \"Feature Service\"\n * @param {string} type - item's type\n * @returns {boolean}\n */\nexport var isFeatureService = function (type) {\n return type && type.toLowerCase() === \"feature service\";\n};\n/**\n * parse layer id from a service URL\n * @param {string} url\n * @returns {string} layer id\n */\nexport var getLayerIdFromUrl = function (url) {\n var endsWithNumberSegmentRegEx = /\\/\\d+$/;\n var matched = url && url.match(endsWithNumberSegmentRegEx);\n return matched && matched[0].slice(1);\n};\n/**\n * return the layerId if we can tell that item is a single layer service\n * @param {*} item from AGO\n * @returns {string} layer id\n */\nexport var getItemLayerId = function (item) {\n // try to parse it from the URL, but failing that we check for\n // the Singlelayer typeKeyword, which I think is set when you create the item in AGO\n // but have not verified that, nor that we should alway return '0' in that case\n return (getLayerIdFromUrl(item.url) ||\n (isFeatureService(item.type) &&\n includes(item.typeKeywords, \"Singlelayer\") &&\n \"0\"));\n};\n/**\n * given an item, get the id to use w/ the Hub API\n * @param item\n * @returns Hub API id (hubId)\n */\nexport var getItemHubId = function (item) {\n if (item.access !== \"public\") {\n // the hub only indexes public items\n return;\n }\n var id = item.id;\n var layerId = getItemLayerId(item);\n return layerId ? id + \"_\" + layerId : id;\n};\n/**\n * ```js\n * import { getContentIdentifier } from \"@esri/hub-common\";\n * //\n * getContentIdentifier(content, site)\n * > 'f12hhjk32' // id\n * // OR\n * > 'content-slug' // human-readable slug\n * ```\n * Returns the preferred identifier for a piece of content (determined by content type):\n * - Content from the 'template' and 'feedback' families return the standard id field\n * - Pages that are linked to the site parameter will return the slug defined by the site. Otherwise, the page id will be returned\n * - All other content will return the highest available item in the following hierarchy:\n * 1. slug - includes org prefix if the site parameter is a portal or has an orgKey different from the slug prefix\n * 2. hubId\n * 3. id\n * @param content The IHubContent item\n * @param site The site to compare content against\n * @returns the preferred id for the given content.\n */\nexport function getContentIdentifier(content, site) {\n // We don't currently support slugs for hub initiative templates, solutions or surveys\n if (includes([\"template\", \"feedback\"], content.family)) {\n return content.id;\n }\n // If it is a hub page linked to a site, return the page slug at the\n // site data instead. Because this one is the original one that was used\n // to create the page url (not mutable once created) and the slug (below)\n // generated by the hub-indexer could simply change with page name.\n if (isPageContent(content)) {\n // check if the page is linked to the current site\n var pages = getProp(site, \"data.values.pages\") || [];\n // if so, return the page slug otherwise the page id\n var page = pages.find(function (p) { return p.id === content.id; });\n return page ? page.slug : content.id;\n }\n // If a slug is present, always return it\n if (content.slug) {\n var slug = void 0;\n var orgKey = getProp(site, \"domainInfo.orgKey\");\n // Use namespaced slug when on the umbrella site\n if (getProp(site, \"data.values.isUmbrella\")) {\n slug = content.slug;\n }\n else {\n // Use shortened slug if the slug's namespace is the same as the orgKey\n slug = removeContextFromSlug(content.slug, orgKey);\n }\n return slug;\n }\n return content.hubId || content.id;\n}\n//////////////////////\n// Slug Helpers\n//////////////////////\n/**\n * Parse item ID and layer ID (if any) from dataset record ID\n *\n * @param datasetId Hub API dataset record id ({itemId}_{layerId} or {itemId})\n * @returns A hash with the `itemId` and `layerId` (if any)\n */\nexport function parseDatasetId(datasetId) {\n var _a = datasetId ? datasetId.split(\"_\") : [], itemId = _a[0], layerId = _a[1];\n return { itemId: itemId, layerId: layerId };\n}\n/**\n * Determine if an identifier is a Hub API slug\n *\n * @param identifier Hub API slug ({orgKey}::{title-as-slug} or {title-as-slug})\n * or record id ((itemId}_{layerId} or {itemId})\n * @returns true if the identifier is valid _and_ is **not** a record id\n */\nexport function isSlug(identifier) {\n var itemId = parseDatasetId(identifier).itemId;\n if (!itemId || isGuid(itemId)) {\n // it's either invalid, or an item id, or a dataset id\n return false;\n }\n // otherwise assume it's a slug\n return true;\n}\n/**\n * Add a context (prefix) to slug if it doesn't already have one\n *\n * @param slug Hub API slug (with or without context)\n * @param context usually a portal's orgKey\n * @returns slug with context ({context}::{slug})\n */\nexport function addContextToSlug(slug, context) {\n // the slug has an org key already e.g. dc::crime-incidents\n if (/.+::.+/.test(slug)) {\n return slug;\n // the slug belongs to the org that owns the site e.g. crime-incidents\n }\n else {\n return context + \"::\" + slug;\n }\n}\n/**\n * Remove context (prefix) from a slug\n *\n * @param slug Hub API slug with context\n * @param context usually a portal's orgKey\n * @returns slug without context\n */\nexport function removeContextFromSlug(slug, context) {\n if (context && slug.match(context + \"::\")) {\n return slug.split(context + \"::\")[1];\n }\n else {\n return slug;\n }\n}\n/**\n * Splits item category strings at slashes and discards the \"Categories\" keyword\n *\n * ```\n * [\"/Categories/Boundaries\", \"/Categories/Planning and cadastre/Property records\", \"/Categories/Structure\"]\n * ```\n * Should end up being\n * ```\n * [\"Boundaries\", \"Planning and cadastre\", \"Property records\", \"Structure\"]\n * ```\n *\n * @param categories - an array of strings\n * @private\n */\nexport function parseItemCategories(categories) {\n if (!categories)\n return categories;\n var exclude = [\"categories\", \"\"];\n var parsed = categories.map(function (cat) { return cat.split(\"/\"); });\n var flattened = parsed.reduce(function (acc, arr, _) { return __spreadArrays(acc, arr); }, []);\n return flattened.filter(function (cat) { return !includes(exclude, cat.toLowerCase()); });\n}\n/**\n * return the Hub family given an item's type\n * @param type item type\n * @returns Hub family\n */\nexport function getFamily(type) {\n var family;\n // override default behavior for the rows that are highlighted in yellow here:\n // https://esriis.sharepoint.com/:x:/r/sites/ArcGISHub/_layouts/15/Doc.aspx?sourcedoc=%7BADA1C9DC-4F6C-4DE4-92C6-693EF9571CFA%7D&file=Hub%20Routes.xlsx&nav=MTBfe0VENEREQzI4LUZFMDctNEI0Ri04NjcyLThCQUE2MTA0MEZGRn1fezIwMTIwMEJFLTA4MEQtNEExRC05QzA4LTE5MTAzOUQwMEE1RH0&action=default&mobileredirect=true&cid=df1c874b-c367-4cea-bc13-7bebfad3f2ac\n switch ((type || \"\").toLowerCase()) {\n case \"image service\":\n family = \"dataset\";\n break;\n case \"feature service\":\n case \"raster layer\":\n // TODO: check if feature service has > 1 layer first?\n family = \"map\";\n break;\n case \"microsoft excel\":\n family = \"document\";\n break;\n case \"cad drawing\":\n case \"feature collection template\":\n case \"report template\":\n family = \"content\";\n break;\n default:\n // by default derive from collection\n family = collectionToFamily(getCollection(type));\n }\n return family;\n}\n/**\n * DEPRECATED: Use getFamily() instead.\n *\n * get the HubType for a given item or item type\n *\n * @param itemOrType an item or item.type\n */\nexport function getItemHubType(itemOrType) {\n /* tslint:disable no-console */\n console.warn(\"DEPRECATED: Use getFamily() instead. getItemHubType() will be removed at v10.0.0\");\n /* tslint:enable no-console */\n if (typeof itemOrType === \"string\") {\n itemOrType = { type: itemOrType };\n }\n var itemType = normalizeItemType(itemOrType);\n // TODO: not all categories are Hub types, may need to validate\n return getCollection(itemType);\n}\n/**\n * Convert a Portal item to Hub content\n *\n * @param item Portal Item\n * @returns Hub content\n * @export\n */\nexport function itemToContent(item) {\n var createdDate = new Date(item.created);\n var createdDateSource = \"item.created\";\n var properties = item.properties;\n var content = Object.assign({}, item, {\n identifier: item.id,\n // no server errors when fetching the item directly\n errors: [],\n // store a reference to the item\n item: item,\n // NOTE: this will overwrite any existing item.name, which is\n // The file name of the item for file types. Read-only.\n // presumably there to use as the default file name when downloading\n // we don't store item.name in the Hub API and we use name for title\n name: item.title,\n // TODO: hubType is no longer used, remove it at next breaking change\n hubType: getItemHubType(item),\n categories: parseItemCategories(item.categories),\n itemCategories: item.categories,\n // can we strip HTML from description, and do we need to trim it to a X chars?\n summary: item.snippet || item.description,\n publisher: {\n name: item.owner,\n username: item.owner,\n },\n permissions: {\n visibility: item.access,\n control: item.itemControl || \"view\",\n },\n // Hub app configuration metadata from item properties\n actionLinks: properties && properties.links,\n hubActions: properties && properties.actions,\n metrics: properties && properties.metrics,\n isDownloadable: isDownloadable(item),\n // default boundary from item.extent\n license: { name: \"Custom License\", description: item.accessInformation },\n // dates and sources we will enrich these later...\n createdDate: createdDate,\n createdDateSource: createdDateSource,\n publishedDate: createdDate,\n publishedDateSource: createdDateSource,\n updatedDate: new Date(item.modified),\n updatedDateSource: \"item.modified\",\n structuredLicense: getStructuredLicense(item.licenseInfo),\n });\n return setContentExtent(setContentType(content, item.type), item.extent);\n}\n/**\n * Convert a Hub API dataset resource to Hub Content\n *\n * @param {DatasetResource} Dataset resource\n * @returns {IHubContent} Hub content object\n * @export\n */\nexport function datasetToContent(dataset) {\n // extract item from dataset, create content from the item\n var item = datasetToItem(dataset);\n var content = itemToContent(item);\n // We remove these because the indexer doesn't actually\n // preserve the original item categories so this attribute is invalid\n delete content.itemCategories;\n // overwrite or add enrichments from Hub API\n var hubId = dataset.id, attributes = dataset.attributes;\n var \n // common enrichments\n errors = attributes.errors, boundary = attributes.boundary, extent = attributes.extent, metadata = attributes.metadata, modified = attributes.modified, modifiedProvenance = attributes.modifiedProvenance, slug = attributes.slug, searchDescription = attributes.searchDescription, groupIds = attributes.groupIds, \n // map and feature server enrichments\n server = attributes.server, layers = attributes.layers, \n // NOTE: the Hub API also returns the following server properties\n // but we should be able to get them from the above server object\n // currentVersion, capabilities, tileInfo, serviceSpatialReference\n // maxRecordCount, supportedQueryFormats, etc\n // feature and raster layer enrichments\n layer = attributes.layer, recordCount = attributes.recordCount, statistics = attributes.statistics, \n // NOTE: the Hub API also returns the following layer properties\n // but we should be able to get them from the above layer object\n // supportedQueryFormats, supportsAdvancedQueries, advancedQueryCapabilities, useStandardizedQueries\n // geometryType, objectIdField, displayField, fields,\n // org properties?\n orgId = attributes.orgId, orgName = attributes.orgName, organization = attributes.organization, orgExtent = attributes.orgExtent, \n // NOTE: for layers and tables the Hub API returns the layer type\n // (\"Feature Layer\", \"Table\", \"Raster Layer\") instead of the item type\n type = attributes.type;\n // NOTE: we could throw or return if there are errors\n // to prevent type errors trying to read properties below\n content.errors = errors;\n // common enrichments\n content.boundary = boundary;\n if (!isBBox(item.extent) && extent && isBBox(extent.coordinates)) {\n // we fall back to the extent derived by the API\n // which prefers layer or service extents and ultimately\n // falls back to the org's extent\n content.extent = extent.coordinates;\n }\n // setting this to null signals to enrichMetadata to skip this\n content.metadata = metadata || null;\n if (content.modified !== modified) {\n // capture the enriched modified date\n // NOTE: the item modified date is still available on content.item.modified\n content.modified = modified;\n content.updatedDate = new Date(modified);\n content.updatedDateSource = modifiedProvenance;\n }\n content.slug = slug;\n if (searchDescription) {\n // overwrite default summary (from snippet) w/ search description\n content.summary = searchDescription;\n }\n content.groupIds = groupIds;\n // server enrichments\n content.server = server;\n content.layers = layers;\n // layer enrichments\n content.layer = layer;\n content.recordCount = recordCount;\n content.statistics = statistics;\n // org enrichments\n if (orgId) {\n content.org = {\n id: orgId,\n name: orgName || organization,\n extent: orgExtent,\n };\n }\n // return a content with updated hubId and type\n // along w/ related properties like identifier, family, etc\n return setContentType(setContentHubId(content, hubId), type);\n}\n/**\n * Convert a Hub API dataset resource to a portal item\n *\n * @param {DatasetResource} Dataset resource\n * @returns {IItem} portal item\n * @export\n */\nexport function datasetToItem(dataset) {\n if (!dataset) {\n return;\n }\n var id = dataset.id, attributes = dataset.attributes;\n if (!attributes) {\n return;\n }\n // parse item id\n var itemId = parseDatasetId(id).itemId;\n // read item properties from attributes\n // NOTE: we attempt to read all item properties\n // even though some may not be currently returned\n var \n // start w/ item properties from\n // https://developers.arcgis.com/rest/users-groups-and-items/item.htm\n owner = attributes.owner, orgId = attributes.orgId, created = attributes.created, \n // the Hub API returns item.modified in attributes.itemModified (below)\n modified = attributes.modified, \n // NOTE: we use attributes.name to store the title or the service/layer name\n // but in Portal name is only used for file types to store the file name (read only)\n name = attributes.name, title = attributes.title, type = attributes.type, typeKeywords = attributes.typeKeywords, description = attributes.description, snippet = attributes.snippet, tags = attributes.tags, thumbnail = attributes.thumbnail, \n // the Hub API returns item.extent in attributes.itemExtent (below)\n // extent,\n categories = attributes.categories, contentStatus = attributes.contentStatus, \n // the Hub API doesn't currently return spatialReference\n spatialReference = attributes.spatialReference, \n // the Hub API doesn't currently return accessInformation\n accessInformation = attributes.accessInformation, licenseInfo = attributes.licenseInfo, culture = attributes.culture, url = attributes.url, access = attributes.access, \n // the Hub API doesn't currently return proxyFilter\n proxyFilter = attributes.proxyFilter, properties = attributes.properties, \n // the Hub API doesn't currently return appCategories, industries,\n // languages, largeThumbnail, banner, screenshots, listed, ownerFolder\n appCategories = attributes.appCategories, industries = attributes.industries, languages = attributes.languages, largeThumbnail = attributes.largeThumbnail, banner = attributes.banner, screenshots = attributes.screenshots, listed = attributes.listed, ownerFolder = attributes.ownerFolder, size = attributes.size, \n // the Hub API doesn't currently return protected\n isProtected = attributes.protected, commentsEnabled = attributes.commentsEnabled, \n // the Hub API doesn't currently return numComments, numRatings,\n // avgRating, numViews, itemControl, scoreCompleteness\n numComments = attributes.numComments, numRatings = attributes.numRatings, avgRating = attributes.avgRating, numViews = attributes.numViews, itemControl = attributes.itemControl, scoreCompleteness = attributes.scoreCompleteness, \n // additional attributes we'll need\n // to derive the above values when missing\n itemExtent = attributes.itemExtent, itemModified = attributes.itemModified, modifiedProvenance = attributes.modifiedProvenance, serviceSpatialReference = attributes.serviceSpatialReference;\n // layer datasets will get their type from the layer\n // so we will need to derive the item type from the URL\n var serviceType = url && getServiceTypeFromUrl(url);\n // build and return an item from properties\n // NOTE: we currently do NOT provide default values\n // (i.e. null for scalar attributes, [] for arrays, etc)\n // for attributes that are not returned by the Hub API\n // this helps distinguish an item that comes from the API\n // but forces all consumers to do handle missing properties\n return {\n id: itemId,\n owner: owner,\n orgId: orgId,\n created: created,\n // for feature layers, modified will usually come from the layer so\n // we prefer itemModified, but fall back to modified if it came from the item\n modified: (itemModified ||\n (modifiedProvenance === \"item.modified\" && modified)),\n title: (title || name),\n type: serviceType || type,\n typeKeywords: typeKeywords,\n description: description,\n tags: tags,\n snippet: snippet,\n thumbnail: thumbnail,\n extent: itemExtent ||\n /* istanbul ignore next: API should always return itemExtent, but we default to [] just in case */ [],\n categories: categories,\n contentStatus: contentStatus,\n spatialReference: spatialReference || serviceSpatialReference,\n accessInformation: accessInformation,\n licenseInfo: licenseInfo,\n culture: culture,\n url: url,\n access: access,\n size: size,\n protected: isProtected,\n proxyFilter: proxyFilter,\n properties: properties,\n appCategories: appCategories,\n industries: industries,\n languages: languages,\n largeThumbnail: largeThumbnail,\n banner: banner,\n screenshots: screenshots,\n listed: listed,\n ownerFolder: ownerFolder,\n commentsEnabled: commentsEnabled,\n numComments: numComments,\n numRatings: numRatings,\n avgRating: avgRating,\n numViews: numViews,\n itemControl: itemControl,\n scoreCompleteness: scoreCompleteness,\n };\n}\n/**\n * returns a new content that has the specified type and\n * and updated related properties like normalizedType, family, etc\n * @param content orignal content\n * @param type new type\n * @returns new content\n */\nexport var setContentType = function (content, type) {\n // get family and normalized type based on new type\n var normalizedType = normalizeItemType(__assign(__assign({}, content.item), { type: type }));\n var family = getFamily(normalizedType);\n var contentTypeIcon = getContentTypeIcon(normalizedType);\n var contentTypeLabel = getContentTypeLabel(normalizedType, content.isProxied);\n // TODO: don't we need to update content.item.type too?\n var updated = __assign(__assign({}, content), { type: type,\n family: family,\n normalizedType: normalizedType,\n contentTypeIcon: contentTypeIcon,\n contentTypeLabel: contentTypeLabel });\n // update the relative URL to the content\n // which is based on type and family\n return appendContentUrls(updated, {\n relative: getContentRelativeUrl(updated),\n });\n};\n/**\n * Compute the content type icon based on the normalizedType\n * @param normalizedType\n * @returns content type icon\n */\nexport var getContentTypeIcon = function (normalizedType) {\n var _a;\n var type = camelize(normalizedType || \"\");\n var iconMap = {\n appbuilderExtension: \"file\",\n appbuilderWidgetPackage: \"widgets-source\",\n application: \"web\",\n arcgisProMap: \"desktop\",\n cadDrawing: \"file-cad\",\n cityEngineWebScene: \"urban-model\",\n codeAttachment: \"file-code\",\n colorSet: \"palette\",\n contentCategorySet: \"label\",\n cSV: \"file-csv\",\n cSVCollection: \"file-csv\",\n dashboard: \"dashboard\",\n desktopApplication: \"desktop\",\n documentLink: \"link\",\n excaliburImageryProject: \"file\",\n explorerMap: \"file\",\n exportPackage: \"file\",\n featureCollection: \"data\",\n featureCollectionTemplate: \"file\",\n featureLayer: \"data\",\n featureService: \"collection\",\n fileGeodatabase: \"data\",\n form: \"survey\",\n geocodingService: \"file\",\n geodataService: \"file\",\n geometryService: \"file\",\n geopackage: \"file\",\n geoprocessingService: \"file\",\n globeLayer: \"layers\",\n globeService: \"file\",\n hubInitiative: \"mountain-summit-nocap\",\n hubInitiativeTemplate: \"initiative-template-outlines-thick\",\n hubPage: \"browser\",\n hubSiteApplication: \"web\",\n image: \"file-image\",\n imageService: \"data\",\n insightsModel: \"file\",\n insightsPage: \"graph-moving-average\",\n insightsTheme: \"palette\",\n insightsWorkbook: \"graph-moving-average\",\n iWorkPages: \"file-text\",\n iWorkKeynote: \"presentation\",\n iWorkNumbers: \"file-report\",\n kML: \"data\",\n kMLCollection: \"data\",\n layer: \"layers\",\n layerPackage: \"layers\",\n locatorPackage: \"file\",\n mapArea: \"file\",\n mapDocument: \"map-contents\",\n mapImageLayer: \"collection\",\n mapPackage: \"file\",\n mapService: \"collection\",\n microsoftExcel: \"file-report\",\n microsoftPowerpoint: \"presentation\",\n microsoftWord: \"file-text\",\n mission: \"file\",\n mobileMapPackage: \"map-contents\",\n nativeApplication: \"mobile\",\n nativeApplicationInstaller: \"file\",\n nativeApplicationTemplate: \"file\",\n mobileApplication: \"mobile\",\n networkAnalysisService: \"file\",\n notebook: \"code\",\n orientedImageryCatalog: \"file\",\n orthoMappingProject: \"file\",\n orthoMappingTemplate: \"file\",\n pDF: \"file-pdf\",\n quickCaptureProject: \"mobile\",\n rasterLayer: \"map\",\n realTimeAnalytic: \"file\",\n relationalDatabaseConnection: \"file\",\n reportTemplate: \"file\",\n sceneLayer: \"data\",\n sceneService: \"urban-model\",\n serviceDefinition: \"file\",\n shapefile: \"data\",\n solution: \"solutions\",\n sqliteGeodatabase: \"file\",\n statisticalDataCollection: \"file\",\n storyMap: \"tour\",\n symbolSet: \"file\",\n table: \"table\",\n urbanModel: \"urban-model\",\n vectorTileService: \"map\",\n visioDocument: \"conditional-rules\",\n webExperience: \"apps\",\n webMap: \"map\",\n webMappingApplication: \"apps\",\n webScene: \"urban-model\",\n wFS: \"map\",\n wMS: \"map\",\n wMTS: \"map\",\n workflowManagerService: \"file\",\n workforceProject: \"list-check\",\n };\n return (_a = iconMap[type]) !== null && _a !== void 0 ? _a : \"file\";\n};\n/**\n * Compute the content type label\n * @param normalizedType\n * @param isProxied\n * @returns content type label\n */\nexport var getContentTypeLabel = function (normalizedType, isProxied) {\n return isProxied ? \"CSV\" : camelize(normalizedType || \"\");\n};\n/**\n * returns a new content that has the specified hubId and updated identifier\n * @param content orignal content\n * @param hubId new hubId\n * @returns new content\n */\nexport var setContentHubId = function (content, hubId) {\n var id = content.id, slug = content.slug;\n // get the identifier which is based on hubId\n var identifier = slug || hubId || id;\n var updated = __assign(__assign({}, content), { hubId: hubId, identifier: identifier });\n // update the relative URL to the content\n // which is based on identifier\n return appendContentUrls(updated, {\n relative: getContentRelativeUrl(updated),\n });\n};\n/**\n * Calculates the relative and absolute urls for a given content on a specific site\n *\n * @param content\n * @param siteModel\n * @returns relative and absolute urls\n */\nexport var getContentSiteUrls = function (content, siteModel) {\n // compute relative URL using a site specific identifier\n var siteIdentifier = getContentIdentifier(content, siteModel);\n var relative = getContentRelativeUrl(content, siteIdentifier);\n // get the absolute URL to this content on the site\n var siteUrl = getProp(siteModel, \"item.url\").replace(/\\/$/, \"\");\n var absolute = \"\" + siteUrl + relative;\n return { relative: relative, absolute: absolute };\n};\n/**\n * append the absolute URL to the content on the site\n * also updates the relative URL in case the\n * @param content\n * @param siteModel\n * @returns\n */\nexport var setContentSiteUrls = function (content, siteModel) {\n var _a = getContentSiteUrls(content, siteModel), relative = _a.relative, site = _a.absolute;\n // append the updated URLs to a new content\n return appendContentUrls(content, {\n relative: relative,\n site: site,\n });\n};\n// URL helpers\nvar appendContentUrls = function (content, newUrls) {\n // merge new urls into existing ones and return a new content\n var urls = __assign(__assign({}, content.urls), newUrls);\n return __assign(__assign({}, content), { urls: urls });\n};\nvar getContentRelativeUrl = function (content, siteIdentifier) {\n var family = content.family;\n // prefer site specific identifier if passed in\n var identifier = siteIdentifier || content.identifier;\n // solution types have their own logic\n var contentUrl = getSolutionUrl(content);\n if (!contentUrl) {\n var pluralizedFamilies = [\n \"app\",\n \"dataset\",\n \"document\",\n \"map\",\n \"template\",\n ];\n // default to the catchall content route\n var path = \"/content\";\n if (content.family === \"feedback\") {\n // exception\n path = \"/feedback/surveys\";\n }\n else if (isPageContent(content)) {\n // pages are in the document family,\n // but instead of showing the page's metadata on /documents/about\n // but we render the page on the pages route\n path = \"/pages\";\n }\n else if (pluralizedFamilies.indexOf(family) > -1) {\n // the rule\n path = \"/\" + family + \"s\";\n }\n contentUrl = path + \"/\" + identifier;\n }\n return contentUrl;\n};\nvar getSolutionUrl = function (content) {\n var _a;\n var hubUrl;\n var normalizedType = content.normalizedType, identifier = content.identifier;\n if (normalizedType === \"Solution\") {\n // NOTE: as per the above spreadsheet,\n // solution types are now in the Template family\n // but we don't send them to the route for initiative templates\n if (((_a = content.typeKeywords) === null || _a === void 0 ? void 0 : _a.indexOf(\"Deployed\")) > 0) {\n // deployed solutions go to the generic content route\n hubUrl = \"/content/\" + identifier;\n }\n // others go to the solution about route\n hubUrl = \"/templates/\" + identifier + \"/about\";\n }\n return hubUrl;\n};\n// page helpers\n// TODO: we check both \"Hub Page\" and \"Site Page\" because we don't know whether the site is a portal or not\n// In the future, the site object will have a site.isPortal() function that we can leverage\n// instead of hardcoding the types here.\n// TODO: should this be based on normalizedType instead?\nvar isPageContent = function (content) {\n return includes([\"Hub Page\", \"Site Page\"], content.type);\n};\n//# sourceMappingURL=index.js.map","\"use strict\";\n\n/**\n * Implementation of atob() according to the HTML and Infra specs, except that\n * instead of throwing INVALID_CHARACTER_ERR we return null.\n */\nfunction atob(data) {\n // Web IDL requires DOMStrings to just be converted using ECMAScript\n // ToString, which in our case amounts to using a template literal.\n data = `${data}`;\n // \"Remove all ASCII whitespace from data.\"\n data = data.replace(/[ \\t\\n\\f\\r]/g, \"\");\n // \"If data's length divides by 4 leaving no remainder, then: if data ends\n // with one or two U+003D (=) code points, then remove them from data.\"\n if (data.length % 4 === 0) {\n data = data.replace(/==?$/, \"\");\n }\n // \"If data's length divides by 4 leaving a remainder of 1, then return\n // failure.\"\n //\n // \"If data contains a code point that is not one of\n //\n // U+002B (+)\n // U+002F (/)\n // ASCII alphanumeric\n //\n // then return failure.\"\n if (data.length % 4 === 1 || /[^+/0-9A-Za-z]/.test(data)) {\n return null;\n }\n // \"Let output be an empty byte sequence.\"\n let output = \"\";\n // \"Let buffer be an empty buffer that can have bits appended to it.\"\n //\n // We append bits via left-shift and or. accumulatedBits is used to track\n // when we've gotten to 24 bits.\n let buffer = 0;\n let accumulatedBits = 0;\n // \"Let position be a position variable for data, initially pointing at the\n // start of data.\"\n //\n // \"While position does not point past the end of data:\"\n for (let i = 0; i < data.length; i++) {\n // \"Find the code point pointed to by position in the second column of\n // Table 1: The Base 64 Alphabet of RFC 4648. Let n be the number given in\n // the first cell of the same row.\n //\n // \"Append to buffer the six bits corresponding to n, most significant bit\n // first.\"\n //\n // atobLookup() implements the table from RFC 4648.\n buffer <<= 6;\n buffer |= atobLookup(data[i]);\n accumulatedBits += 6;\n // \"If buffer has accumulated 24 bits, interpret them as three 8-bit\n // big-endian numbers. Append three bytes with values equal to those\n // numbers to output, in the same order, and then empty buffer.\"\n if (accumulatedBits === 24) {\n output += String.fromCharCode((buffer & 0xff0000) >> 16);\n output += String.fromCharCode((buffer & 0xff00) >> 8);\n output += String.fromCharCode(buffer & 0xff);\n buffer = accumulatedBits = 0;\n }\n // \"Advance position by 1.\"\n }\n // \"If buffer is not empty, it contains either 12 or 18 bits. If it contains\n // 12 bits, then discard the last four and interpret the remaining eight as\n // an 8-bit big-endian number. If it contains 18 bits, then discard the last\n // two and interpret the remaining 16 as two 8-bit big-endian numbers. Append\n // the one or two bytes with values equal to those one or two numbers to\n // output, in the same order.\"\n if (accumulatedBits === 12) {\n buffer >>= 4;\n output += String.fromCharCode(buffer);\n } else if (accumulatedBits === 18) {\n buffer >>= 2;\n output += String.fromCharCode((buffer & 0xff00) >> 8);\n output += String.fromCharCode(buffer & 0xff);\n }\n // \"Return output.\"\n return output;\n}\n/**\n * A lookup table for atob(), which converts an ASCII character to the\n * corresponding six-bit number.\n */\n\nconst keystr =\n \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\";\n\nfunction atobLookup(chr) {\n const index = keystr.indexOf(chr);\n // Throw exception if character is not in the lookup string; should not be hit in tests\n return index < 0 ? undefined : index;\n}\n\nmodule.exports = atob;\n","\"use strict\";\n\n/**\n * btoa() as defined by the HTML and Infra specs, which mostly just references\n * RFC 4648.\n */\nfunction btoa(s) {\n let i;\n // String conversion as required by Web IDL.\n s = `${s}`;\n // \"The btoa() method must throw an \"InvalidCharacterError\" DOMException if\n // data contains any character whose code point is greater than U+00FF.\"\n for (i = 0; i < s.length; i++) {\n if (s.charCodeAt(i) > 255) {\n return null;\n }\n }\n let out = \"\";\n for (i = 0; i < s.length; i += 3) {\n const groupsOfSix = [undefined, undefined, undefined, undefined];\n groupsOfSix[0] = s.charCodeAt(i) >> 2;\n groupsOfSix[1] = (s.charCodeAt(i) & 0x03) << 4;\n if (s.length > i + 1) {\n groupsOfSix[1] |= s.charCodeAt(i + 1) >> 4;\n groupsOfSix[2] = (s.charCodeAt(i + 1) & 0x0f) << 2;\n }\n if (s.length > i + 2) {\n groupsOfSix[2] |= s.charCodeAt(i + 2) >> 6;\n groupsOfSix[3] = s.charCodeAt(i + 2) & 0x3f;\n }\n for (let j = 0; j < groupsOfSix.length; j++) {\n if (typeof groupsOfSix[j] === \"undefined\") {\n out += \"=\";\n } else {\n out += btoaLookup(groupsOfSix[j]);\n }\n }\n }\n return out;\n}\n\n/**\n * Lookup table for btoa(), which converts a six-bit number into the\n * corresponding ASCII character.\n */\nconst keystr =\n \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\";\n\nfunction btoaLookup(index) {\n if (index >= 0 && index < 64) {\n return keystr[index];\n }\n\n // Throw INVALID_CHARACTER_ERR exception here -- won't be hit in the tests.\n return undefined;\n}\n\nmodule.exports = btoa;\n","\"use strict\";\n\nconst atob = require(\"./lib/atob\");\nconst btoa = require(\"./lib/btoa\");\n\nmodule.exports = {\n atob,\n btoa\n};\n","import { SearchQueryBuilder } from \"@esri/arcgis-rest-portal\";\nimport { btoa } from \"abab\";\nimport { flattenArray } from \"../util\";\nexport var WGS84_WKID = \"4326\";\nexport var PORTAL_EXPORT_TYPES = {\n csv: {\n name: \"CSV\",\n itemTypes: [\"CSV\", \"CSV Collection\"],\n supportsProjection: true,\n },\n kml: {\n name: \"KML\",\n itemTypes: [\"KML\", \"KML Collection\"],\n supportsProjection: false,\n },\n shapefile: {\n name: \"Shapefile\",\n itemTypes: [\"Shapefile\"],\n supportsProjection: true,\n },\n fileGeodatabase: {\n name: \"File Geodatabase\",\n itemTypes: [\"File Geodatabase\"],\n supportsProjection: true,\n },\n geojson: {\n name: \"GeoJson\",\n itemTypes: [\"GeoJson\"],\n supportsProjection: false,\n },\n excel: {\n name: \"Excel\",\n itemTypes: [\"Microsoft Excel\"],\n supportsProjection: true,\n },\n featureCollection: {\n name: \"Feature Collection\",\n itemTypes: [\"Feature Collection\"],\n supportsProjection: true,\n },\n};\n/**\n * Puts a spatial reference into a serialized format that can be used\n * for item typeKeywords.\n *\n * **Note**: discards \"latestWkid\"\n *\n * In the past we used `JSON.stringify`, but that causes problems because\n * it can include commas which are interpreted by the portal [update item call](https://developers.arcgis.com/rest/users-groups-and-items/update-item.htm)\n * as being separate typekeywords. With `JSON.stringify`, equality was also\n * dependent on the order of the properties in the spatial reference.\n *\n * Check https://developers.arcgis.com/web-map-specification/objects/spatialReference/\n * for more details on what this object looks like.\n */\nexport function serializeSpatialReference(spatialReference) {\n if (typeof spatialReference === \"object\") {\n var wkid = spatialReference.wkid, wkt = spatialReference.wkt;\n return wkid ? wkid + \"\" : btoa(wkt);\n }\n else {\n return spatialReference;\n }\n}\n/**\n * spatialRefId can currently take the form of either a WKID string or a\n * serialized ISpatialReference object.\n *\n * TODO - we shouldn't need this function. Instead, spatialRefId should\n * always be consistent, maybe by using serializeSpatialReference\n *\n * @private\n */\nfunction parseSpatialRefId(spatialRefId) {\n var _spatialRefId;\n try {\n _spatialRefId = JSON.parse(spatialRefId);\n }\n catch (_a) {\n _spatialRefId = spatialRefId;\n }\n return _spatialRefId;\n}\n/**\n * Builds the Portal API query string to search for exports from a given dataset\n *\n * @param itemId - The dataset ID\n * @param options - A set of options including item types, layerId, and spatialRefId\n * @returns\n */\nexport function buildExistingExportsPortalQuery(itemId, options) {\n var _a = maybeExtractOptions(options), onlyTypes = _a.onlyTypes, layerId = _a.layerId, spatialRefId = _a.spatialRefId;\n var formatInfos = Object.keys(PORTAL_EXPORT_TYPES).map(function (key) { return PORTAL_EXPORT_TYPES[key]; });\n var noProjectionItemTypes = new Set(flattenArray(formatInfos\n .filter(function (info) { return !info.supportsProjection; })\n .map(function (info) { return info.itemTypes; })));\n var types;\n if (!onlyTypes) {\n types = flattenArray(formatInfos.map(function (info) { return info.itemTypes; }));\n }\n else {\n types = onlyTypes;\n }\n var queryBuilder = new SearchQueryBuilder()\n .startGroup()\n .match(getExportItemTypeKeyword(itemId))\n .in(\"typekeywords\")\n .and()\n .match(getExportLayerTypeKeyword(layerId))\n .in(\"typekeywords\")\n .endGroup()\n .and()\n .startGroup();\n buildExportTypesClause(queryBuilder, {\n types: types,\n spatialRefId: spatialRefId,\n noProjectionItemTypes: noProjectionItemTypes,\n });\n queryBuilder.endGroup();\n return queryBuilder.toParam();\n}\nfunction maybeExtractOptions(options) {\n if (options) {\n return {\n onlyTypes: options.onlyTypes,\n layerId: options.layerId,\n spatialRefId: options.spatialRefId,\n };\n }\n return {};\n}\nfunction buildExportTypesClause(builder, options) {\n var types = options.types, noProjectionItemTypes = options.noProjectionItemTypes, spatialRefId = options.spatialRefId;\n var getSpatialRefIdWithDefaults = function (_spatialRefId, itemType) {\n var ret = WGS84_WKID;\n if (_spatialRefId && !noProjectionItemTypes.has(itemType)) {\n ret = _spatialRefId;\n }\n return ret;\n };\n var buildQueryForType = function (type, _builder) {\n _builder\n .startGroup()\n .match(/\\s/g.test(type) ? type : \"\\\"\" + type + \"\\\"\") // temporary logic until https://github.com/Esri/arcgis-rest-js/issues/916 is resolved\n .in(\"type\")\n .and()\n .match(getSpatialRefTypeKeyword(getSpatialRefIdWithDefaults(spatialRefId, type)))\n .in(\"typekeywords\")\n .endGroup();\n };\n types.forEach(function (type, i) {\n buildQueryForType(type, builder);\n if (i < types.length - 1) {\n builder.or();\n }\n });\n}\n/**\n * Generates typekeyword for identifying which spatialRefId an export is\n * @param spatialRefId - either a WKID, WKT, or stringified ISpatialReference\n * @private\n */\nexport function getSpatialRefTypeKeyword(spatialRefId) {\n var parsedSpatialReference = parseSpatialRefId(spatialRefId);\n var serializedSpatialReference = serializeSpatialReference(parsedSpatialReference);\n return \"spatialRefId:\" + serializedSpatialReference;\n}\n/**\n * Returns the keyword identifying exports by the item they originate from\n * @param itemId - ID for the item from which the export originated\n * @private\n */\nexport function getExportItemTypeKeyword(itemId) {\n return \"exportItem:\" + itemId;\n}\n/**\n * Returns the keyword identifying exports by the layer they originate from\n * @param layerId - ID for the layer from which the export originated\n * @private\n */\nexport function getExportLayerTypeKeyword(layerId) {\n // NOTE - Layer Id's need to be padded with \"0\" so that /search results are predictable. Searches for typeKeywords:\"exportLayer:1\" don't work.\n // See https://github.com/Esri/hub.js/pull/472 for more information.\n // TODO - use `filter` when Enterprise Sites adds support.\n return layerId ? \"exportLayer:0\" + layerId : \"exportLayer:null\";\n}\n//# sourceMappingURL=build-existing-exports-portal-query.js.map","import { failSafe } from \"../utils\";\nimport { unprotectGroup, removeGroup } from \"@esri/arcgis-rest-portal\";\n/**\n * Unprotect and Remove a Group.\n * Assumed caller has checked that the current user should be able\n * to unprotect and remove the group. Underlying calls are failsafe\n * so a failure to unprotect or remove the group will not reject\n * @param {IUserGroupOptions} userGroupOptions id and authentication\n * @private\n */\nexport function _unprotectAndRemoveGroup(userGroupOptions) {\n var failSafeUnprotect = failSafe(unprotectGroup, { success: true });\n var failSafeRemove = failSafe(removeGroup, { success: true });\n return failSafeUnprotect(userGroupOptions).then(function () {\n return failSafeRemove(userGroupOptions);\n });\n}\n//# sourceMappingURL=_unprotect-and-remove-group.js.map","import { getWithDefault } from \"../../../objects/get-with-default\";\n/**\n * @private\n */\nexport function _consolidateResults(context) {\n var autoAddResult = context.autoAddResult, inviteResult = context.inviteResult, primaryEmailResult = context.primaryEmailResult, secondaryEmailResult = context.secondaryEmailResult;\n var combinedEmailResults;\n if (primaryEmailResult || secondaryEmailResult) {\n var validResults = [primaryEmailResult, secondaryEmailResult].filter(function (r) { return r; });\n var combinedSuccess = validResults.every(function (r) { return r.success; });\n var combinedErrors = validResults.reduce(function (collection, r) { return collection.concat(getWithDefault(r, \"errors\", [])); }, []);\n combinedEmailResults = {\n success: combinedSuccess\n };\n if (combinedErrors.length) {\n combinedEmailResults.errors = combinedErrors;\n }\n }\n var overallSuccess = [autoAddResult, inviteResult, combinedEmailResults]\n .filter(function (r) { return r; })\n .every(function (r) { return r.success; });\n return {\n success: overallSuccess,\n autoAdd: autoAddResult,\n invite: inviteResult,\n email: combinedEmailResults\n };\n}\n//# sourceMappingURL=_consolidate-results.js.map","import { ArcGISRequestError } from \"@esri/arcgis-rest-request\";\nimport { getProp } from \"../../../objects/get-prop\";\nimport { includes } from \"../../../utils\";\n/**\n * @private\n *\n * Coerce autoAdd response into a more similar interface as\n * the other rest calls.\n *\n * If any users are not auto added, an error is added to the response\n * and unadded users are placed into the invitation list\n */\nexport function _formatAutoAddResponse(rawResponse, context) {\n if (rawResponse) {\n var success = !getProp(rawResponse, \"notAdded.length\") && !rawResponse.errors;\n context.autoAddResult = { success: success };\n if (!success) {\n var errors = rawResponse.errors || [];\n if (getProp(rawResponse, \"notAdded.length\")) {\n errors.push(new ArcGISRequestError(\"Users not auto-added: \" + rawResponse.notAdded.join(\", \")));\n }\n context.autoAddResult.errors = errors;\n // Move unadded users to invite list;\n var unaddedUsers = context.usersToAutoAdd.filter(function (user) {\n return includes(rawResponse.notAdded, user.username);\n });\n context.usersToInvite = context.usersToInvite.concat(unaddedUsers);\n }\n }\n return context;\n}\n//# sourceMappingURL=_format-auto-add-response.js.map","/**\n * @private\n *\n * returns whether or not the users are in the same org\n */\nexport function _canEmailUser(recipient, sender) {\n return recipient.orgId === sender.orgId;\n}\n//# sourceMappingURL=_can-email-user.js.map","/**\n * @private\n */\nexport function _isOrgAdmin(user) {\n return user.role === \"org_admin\" && !user.roleId;\n}\n//# sourceMappingURL=_is-org-admin.js.map","import { createOrgNotification } from \"@esri/arcgis-rest-portal\";\n/**\n * Attempts to email members of the requesting user's organization.\n *\n * @param {IUser[]} users Users to email (must be in the same org as the requesting user)\n * @param {IEmail} email\n * @param {IAuthenticationManager} authentication\n * @param {boolean} isOrgAdmin // Whether the requesting user in an org admin\n *\n * @returns {object|null} A promise that resolves to the result of the transaction (null if no users are passed in)\n */\nexport function emailOrgUsers(users, email, authentication, isOrgAdmin) {\n var response = Promise.resolve(null);\n if (users.length) {\n var args = {\n authentication: authentication,\n message: email.body,\n subject: email.subject,\n notificationChannelType: \"email\",\n users: users.map(function (u) { return u.username; })\n };\n if (!isOrgAdmin) {\n args.batchSize = 1;\n }\n response = createOrgNotification(args);\n }\n return response;\n}\n//# sourceMappingURL=email-org-users.js.map","import { _canEmailUser } from \"../../add-users-workflow/utils/_can-email-user\";\nimport { _isOrgAdmin } from \"../../add-users-workflow/utils/_is-org-admin\";\nimport { getProp, getWithDefault } from \"../../../objects\";\nimport { emailOrgUsers } from \"../workflow-sections/email-org-users\";\n/**\n * @private\n *\n * If a secondary authentication is passed in AND\n * an email object is passed in AND\n * the previous invitation call was successful:\n *\n * Send an email notification to the invited\n * users that are part of the secondary authentication's org\n */\nexport function _processSecondaryEmail(context) {\n var response = Promise.resolve(context);\n // If secondaryRO provided, send email to the invited users in the secondaryRO's org (typically a community org)\n if (context.email &&\n context.secondaryRO &&\n getProp(context, \"inviteResult.success\")) {\n var secondaryUser_1 = getWithDefault(context, \"secondaryRO.portalSelf.user\", {});\n var secondaryOrgUsersToEmail = context.usersToInvite.filter(function (u) {\n return _canEmailUser(u, secondaryUser_1);\n });\n response = emailOrgUsers(secondaryOrgUsersToEmail, context.email, context.secondaryRO.authentication, _isOrgAdmin(secondaryUser_1)).then(function (result) {\n context.secondaryEmailResult = result;\n return context;\n });\n }\n return response;\n}\n//# sourceMappingURL=_process-secondary-email.js.map","import { addGroupUsers } from \"@esri/arcgis-rest-portal\";\n/**\n *\n * Attempts to auto-add users to a group\n *\n * @param {string} id ID of the group the users will be added to\n * @param {IUser[]} users\n * @param {IAuthenticationManager} authentication\n *\n * @returns {IAddGroupUsersResult|null} Result of the transaction (null if no users are passed in)\n */\nexport function autoAddUsers(id, users, authentication) {\n var response = Promise.resolve(null);\n if (users.length) {\n var args = {\n id: id,\n users: users.map(function (u) { return u.username; }),\n authentication: authentication\n };\n response = addGroupUsers(args);\n }\n return response;\n}\n//# sourceMappingURL=auto-add-users.js.map","import { getProp } from \"../../../objects/get-prop\";\nimport { autoAddUsers } from \"../workflow-sections/auto-add-users\";\nimport { _formatAutoAddResponse } from \"./_format-auto-add-response\";\n/**\n * @private\n */\nexport function _processAutoAdd(context) {\n return autoAddUsers(getProp(context, \"groupId\"), getProp(context, \"usersToAutoAdd\"), getProp(context, \"primaryRO.authentication\")).then(function (rawResponse) { return _formatAutoAddResponse(rawResponse, context); });\n}\n//# sourceMappingURL=_process-auto-add.js.map","import { inviteGroupUsers, } from \"@esri/arcgis-rest-portal\";\n/**\n *\n * Attempts to invite users to a group\n *\n * @param {string} id ID of the group the users will be invited to\n * @param {object[]} users\n * @param {object} authentication\n * @param {number} expiration How long the invite will be active (in minutes)\n * @param {string} role What role should they be added as. Defaults to group member\n *\n * @returns {object|null} Result of the transaction (null if no users are passed in)\n */\nexport function inviteUsers(id, users, authentication, expiration, // default to 2 week expiration TODO: is this actually 2 weeks?\nrole // default to group member, but allow for team_admin as well\n) {\n if (expiration === void 0) { expiration = 20160; }\n if (role === void 0) { role = \"group_member\"; }\n var response = Promise.resolve(null);\n if (users.length) {\n var args = {\n id: id,\n users: users.map(function (u) { return u.username; }),\n authentication: authentication,\n role: role,\n expiration: expiration,\n };\n response = inviteGroupUsers(args);\n }\n return response;\n}\n//# sourceMappingURL=invite-users.js.map","import { getProp } from \"../../../objects/get-prop\";\nimport { inviteUsers } from \"../workflow-sections/invite-users\";\n/**\n * @private\n */\nexport function _processInvite(context) {\n return inviteUsers(getProp(context, \"groupId\"), getProp(context, \"usersToInvite\"), getProp(context, \"primaryRO.authentication\")).then(function (result) {\n context.inviteResult = result;\n return context;\n });\n}\n//# sourceMappingURL=_process-invite.js.map","import { getProp } from \"../../../objects/get-prop\";\nimport { _isOrgAdmin } from \"../utils/_is-org-admin\";\nimport { emailOrgUsers } from \"../workflow-sections/email-org-users\";\n/**\n * @private\n *\n * Send email notification if an email object is present and\n * the previous invitation call was successful\n */\nexport function _processPrimaryEmail(context) {\n var response = Promise.resolve(context);\n // Email users if invite succeeds\n if (context.email && getProp(context, \"inviteResult.success\")) {\n response = emailOrgUsers(context.usersToEmail, context.email, context.primaryRO.authentication, _isOrgAdmin(context.requestingUser)).then(function (result) {\n context.primaryEmailResult = result;\n return context;\n });\n }\n return response;\n}\n//# sourceMappingURL=_process-primary-email.js.map","/**\n * @private\n *\n * A user can be auto-added if they are part of the requesting user's e-org\n * or c-org and the requesting user has the assignToGroups privilege\n */\nexport function _getAutoAddUsers(users, requestingUser) {\n var usersToAutoAdd = [];\n if (requestingUser.privileges.indexOf(\"portal:admin:assignToGroups\") !== -1) {\n var orgIds_1 = [requestingUser.orgId, requestingUser.cOrgId].filter(function (o) { return o; });\n usersToAutoAdd = users.filter(function (u) { return orgIds_1.indexOf(u.orgId) !== -1; });\n }\n return usersToAutoAdd;\n}\n//# sourceMappingURL=_get-auto-add-users.js.map","import { _getAutoAddUsers } from \"./_get-auto-add-users\";\n/**\n * @private\n *\n * A user will be invited if they cannot be auto-added\n */\nexport function _getInviteUsers(users, requestingUser) {\n var autoAddedUsers = _getAutoAddUsers(users, requestingUser);\n return users.filter(function (user) { return !autoAddedUsers.some(function (aau) { return aau.username === user.username; }); });\n}\n//# sourceMappingURL=_get-invite-users.js.map","import { _canEmailUser } from \"./_can-email-user\";\nimport { _getInviteUsers } from \"./_get-invite-users\";\n/**\n * @private\n *\n * A user can be emailed if they are invited (not auto-added)\n * and the _canEmailUser condition is met\n */\nexport function _getEmailUsers(users, requestingUser, includeSelf) {\n if (includeSelf === void 0) { includeSelf = false; }\n var invitedUsers = _getInviteUsers(users, requestingUser);\n var emailUsers = invitedUsers.filter(function (user) {\n return _canEmailUser(user, requestingUser);\n });\n if (includeSelf) {\n emailUsers.push(requestingUser);\n }\n return emailUsers;\n}\n//# sourceMappingURL=_get-email-users.js.map","import { getProp } from \"../../objects/get-prop\";\nimport { getWithDefault } from \"../../objects/get-with-default\";\nimport { cloneObject } from \"../../util\";\nimport { _consolidateResults } from \"./output-processors/_consolidate-results\";\nimport { _processAutoAdd } from \"./output-processors/_process-auto-add\";\nimport { _processInvite } from \"./output-processors/_process-invite\";\nimport { _processPrimaryEmail } from \"./output-processors/_process-primary-email\";\nimport { _processSecondaryEmail } from \"./output-processors/_process-secondary-email\";\nimport { _getAutoAddUsers } from \"./utils/_get-auto-add-users\";\nimport { _getEmailUsers } from \"./utils/_get-email-users\";\nimport { _getInviteUsers } from \"./utils/_get-invite-users\";\n/**\n * Adds, invites or emails users about joining a group\n * based on the permissions of the requesting user. The\n * function returns a hash of results indicating which\n * operations were attempted and whether they were successful.\n *\n * In general, this algorithm will auto-add all the users\n * that it can, invite the others, and send emails to eligible\n * invited users (See below for more details)\n *\n * Here are a couple caveats to be aware of:\n * 1) If the requestingUser can auto-add to the group (A.K.A. has\n * portal:admin:assignToGroups) no email will be sent, period.\n * 2) Emails can only be sent to members of the same org as the\n * requesting user if they have been invited (not auto-added)\n * to the group. If emails must to be sent to invited members\n * of a second org (e.g a community org), an authenticated user\n * of the second org must be passed in (see secondaryRO)\n * 3) If no email is passed in, no email will be sent\n * 4) If auto-adding fails, the unadded users will be invited\n *\n * @param {string} groupId\n * @param {IUser[]} allUsers\n * @param {IHubRequestOptions} primaryRO Info and authentication for the requesting user\n * @param {IEmail} [email] Email to be sent (if qualifying users are passed in)\n * @param {IHubRequestOptions} [secondaryRO] Info and authentication for emailing members of a secondary organization (typically a community org)\n *\n * @returns {IConsolidatedResult} The operations attempted, whether they were successful and any errors\n */\nexport function addUsersToGroup(groupId, allUsers, primaryRO, email, secondaryRO) {\n // Extract requesting user\n var requestingUser = cloneObject(getWithDefault(primaryRO, \"portalSelf.user\", {}));\n requestingUser.cOrgId = getProp(primaryRO, \"portalSelf.portalProperties.hub.settings.communityOrg.orgId\");\n // Context for each process segment\n var context = {\n groupId: groupId,\n allUsers: allUsers,\n primaryRO: primaryRO,\n email: email,\n secondaryRO: secondaryRO,\n requestingUser: requestingUser,\n usersToAutoAdd: _getAutoAddUsers(allUsers, requestingUser),\n usersToInvite: _getInviteUsers(allUsers, requestingUser),\n usersToEmail: _getEmailUsers(allUsers, requestingUser, getProp(email, \"copyMe\"))\n };\n return _processAutoAdd(context)\n .then(_processInvite)\n .then(_processPrimaryEmail)\n .then(_processSecondaryEmail)\n .then(_consolidateResults);\n}\n//# sourceMappingURL=add-users-to-group.js.map","import { unprotectItem, removeItem } from \"@esri/arcgis-rest-portal\";\nimport { failSafe } from \"../utils\";\n/**\n * Unprotect and Remove an Item\n * Assumes caller has checked that the curernt user should be able to\n * unprotect and remove the item. Underlying calls are failsafe\n * so a failure to unprotect or temove the item will not reject.\n * @param {IUserItemOptions} userItemOptions id and authentication\n * @private\n */\nexport function _unprotectAndRemoveItem(userItemOptions) {\n var failSafeUnprotect = failSafe(unprotectItem, { success: true });\n var failSafeRemove = failSafe(removeItem, { success: true });\n return failSafeUnprotect(userItemOptions).then(function () {\n return failSafeRemove(userItemOptions);\n });\n}\n//# sourceMappingURL=_unprotect-and-remove-item.js.map","/**\n * Apply a hash of properties to an array of items.\n * Extracted to simplify testing.\n * @param {array} items Array of items to apply the properties to\n * @param {object} props hash of properties to apply to the item\n */\nexport function applyPropertiesToItems(items, props) {\n return items.map(function (item) {\n if (!item.properties) {\n item.properties = {};\n }\n Object.assign(item.properties, props);\n return item;\n });\n}\n//# sourceMappingURL=apply-properties-to-items.js.map","/**\n * Delete a property from an object using a deep path\n * MODIFIES PASSED TARGET\n * @param {Object} target Object from which we want to delete the property\n * @param {string} path Dotted path to the property we want to delete\n */\nexport function deleteProp(target, lookupStr) {\n if (typeof target !== \"object\" || target === null)\n return;\n if (typeof lookupStr !== \"string\")\n return;\n var lookupKeys = lookupStr.split(\".\");\n for (var i = 0; i < lookupKeys.length - 1; i++) {\n if (!target.hasOwnProperty(lookupKeys[i]))\n return;\n target = target[lookupKeys[i]];\n }\n delete target[lookupKeys[lookupKeys.length - 1]];\n}\n//# sourceMappingURL=delete-prop.js.map","import { cloneObject } from \"../util\";\n/**\n * Given a model, return a serialized clone that can be sent to\n * the items api\n * @param {Object} model Item model {item:{}, data:{}}\n */\nexport function serializeModel(model) {\n var serialized = cloneObject(model.item);\n serialized.text = JSON.stringify(model.data);\n return serialized;\n}\n//# sourceMappingURL=serialize-model.js.map","import { updateItem } from \"@esri/arcgis-rest-portal\";\nimport { serializeModel } from \"./serialize-model\";\nimport { failSafe } from \"../utils\";\n/**\n * Update a model's item, wrapped in a failSafe so this will not blow up if\n * the user lacks rights somehow. This should be used in places where there is\n * a high-probability that the current user CAN update the item.\n * @param {Object} model Model object to be updated\n * @param {IRequestOptions} requestOptions\n */\nexport function failSafeUpdate(model, requestOptions) {\n var failSafedUpdate = failSafe(updateItem, {\n id: model.item.id,\n success: true\n });\n var opts = Object.assign({ item: serializeModel(model) }, requestOptions);\n return failSafedUpdate(opts);\n}\n//# sourceMappingURL=fail-safe-update.js.map","import { getItem, getItemData } from \"@esri/arcgis-rest-portal\";\n/**\n * Gets the full item/data model for an item\n * @param {string} id Id of the item to fetch\n * @param {Object} requestOptions\n */\nexport function getModel(id, requestOptions) {\n return Promise.all([\n getItem(id, requestOptions),\n getItemData(id, requestOptions)\n ]).then(function (result) {\n // shape this into a model\n return {\n item: result[0],\n data: result[1]\n };\n });\n}\n//# sourceMappingURL=get-model.js.map","import { failSafe } from \"../utils\";\nimport { getModel } from \"./get-model\";\n/**\n * To streamline passing of either a model id or the model itself, we use this function\n * to extract the model or fetch it, and return it. It uses `failSafe` and if the item\n * is not accessible for whatever reason, will return a model-ish object with `isMissing: true`\n * It is up to the caller to take approriate action\n * @param {String} modelType the type of model to extract from the options hash\n * @param {Object} options Something that extends IRequestOptions\n */\nexport function getModelFromOptions(modelType, options) {\n var modelProp = modelType + \"Model\";\n var idProp = modelType + \"Id\";\n // if the options hash has the model, return it\n if (options[modelProp]) {\n return Promise.resolve(options[modelProp]);\n }\n else {\n if (options[idProp]) {\n var failSafeModel = failSafe(getModel, {\n item: { id: options[idProp] },\n isMissing: true\n });\n return failSafeModel(options[idProp], options);\n }\n else {\n throw new Error(\"getModelFromOptions requires either a .\" + modelProp + \" or .\" + idProp + \" property.\");\n }\n }\n}\n//# sourceMappingURL=get-model-from-options.js.map","/**\n* adlib - v3.0.6 - Thu Dec 17 2020 17:08:08 GMT-0800 (Pacific Standard Time)\n* Copyright (c) 2017-2020 Dave Bouwman / Esri\n* Apache-2.0\n*/\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * Return the value of a deep property, using a path.\n */\nvar getWithDefault = function (obj, path, defaultValue) {\n if ( defaultValue === void 0 ) defaultValue = undefined;\n\n return path\n .split('.')\n .reduce(function (o, p) { return o ? o[p] : defaultValue; }, obj);\n};\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * Simply Map over the props of an object\n */\nfunction mapValues (obj, fn) {\n var keys = Object.keys(obj);\n // console.info(`keys: ${keys}`);\n var newObject = keys.reduce(function(acc, currentKey) {\n // console.log(` acc: ${JSON.stringify(acc)} curKey: ${currentKey}`);\n acc[currentKey] = fn(obj[currentKey], currentKey, obj);\n return acc;\n }, {});\n // console.info(` output: ${JSON.stringify(newObject)}`);\n return newObject;\n}\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\nvar isDate = function (v) { return v instanceof Date; };\n\nvar isFunction = function (v) { return typeof v === 'function'; };\n\nvar isObject = function (v) { return typeof v === 'object'; };\n\nvar isRegExp = function (v) { return v instanceof RegExp; };\n\nfunction deepMapValues(object, callback, propertyPath) {\n propertyPath = propertyPath || '';\n if(Array.isArray(object)){\n return object.map(deepMapValuesIteratee);\n }\n else if(object && isObject(object) && !isDate(object) && !isRegExp(object) && !isFunction(object)){\n return Object.assign({}, object, mapValues(object, deepMapValuesIteratee));\n }\n else {\n var output = callback(object, propertyPath);\n return output;\n }\n\n function deepMapValuesIteratee(value, key){\n var valuePath = propertyPath ? propertyPath + '.' + key : key;\n return deepMapValues(value, callback, valuePath);\n }\n}\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\nvar isObject$1 = function (v) { return typeof v === 'object'; };\n\n/**\n * Trim a tree decorated with `{{delete:NNN}}`\n */\nfunction arborist (object, propertyPath) {\n\n if(Array.isArray(object)){\n // filter out any nulls...\n var arrResults = object.map(iteratee).filter(function (entry) {\n // need to ensure entry is actually NULL vs just falsey\n return entry !== null && entry !== undefined;\n });\n return pruneArray(arrResults);\n\n } if(object && isObject$1(object) ) {\n\n return pruneObject(mapValues(object, iteratee));\n\n } else {\n\n return getPropertyValue(object);\n }\n\n function iteratee(value, key){\n return arborist(value);\n }\n}\n\n/**\n * Prune an array\n * For all the entries in the array...\n * if the entry is a naked string and contains `{{delete:NNN}}`\n * get maximum NNN value\n * then\n * if maxN === 0\n * return an empty array\n * if maxN > 0\n * return `{{delete:maxN-1}}`\n * else\n * return array\n */\nfunction pruneArray (arrResults) {\n var res = arrResults;\n // is any entry a string w/ {{delete}}?\n var maxLevel = arrResults.reduce(function (maxLevel, e) {\n if (isString(e) && hasDelete(e)) {\n var lvl = getLevel(e);\n if (lvl > maxLevel) {\n maxLevel = lvl;\n }\n }\n return maxLevel;\n }, -1);\n\n if (maxLevel > -1) {\n if (maxLevel === 0) {\n res = [];\n } else {\n res = \"{{delete:\" + (maxLevel - 1) + \"}}\";\n }\n }\n\n return res;\n}\n\n\nfunction pruneObject (objResults) {\n // console.log(` pruneObject:: working on ${JSON.stringify(objResults)}`);\n var startVal = {obj: {}, maxLevel: -1 };\n var res;\n // cook a new clone object, and track the maxLevel\n var reduction = Object.keys(objResults).reduce(function (acc, key) {\n var val = objResults[key];\n if (isString(val) && hasDelete(val)) {\n var lvl = getLevel(val);\n if (lvl > acc.maxLevel) {\n acc.maxLevel = lvl;\n }\n } else {\n // only add the prop if it's not a `{{delete:NNN}}`\n acc.obj[key] = val;\n }\n return acc;\n }, startVal);\n // if -1, we return entire object...\n // if 0 we just remove the prop...\n // if 1 we return undefined...\n // if > 1 we return the deleteVal\n if (reduction.maxLevel > 0 ) {\n if (reduction.maxLevel === 1) {\n res = undefined;\n } else {\n res = \"{{delete:\" + (reduction.maxLevel - 1) + \"}}\";\n }\n } else {\n res = reduction.obj;\n }\n\n // console.log(` returning ${JSON.stringify(res)}`);\n return res;\n}\n\n/**\n * Get a value for a property, handling the `{{delete:NNN}}` syntax\n */\nfunction getPropertyValue (val){\n var output = val;\n\n if (typeof val === 'string') {\n if (hasDelete(val)) {\n output = getDeleteValue(val);\n }\n }\n return output;\n}\n\n/**\n * Given a string with `{{delete:NNN}}`\n * if NNN === 0 return undefined\n * else return `{{delete:NNN - 1}}`\n */\nfunction getDeleteValue (val) {\n var output = val;\n var level = getLevel(val);\n if (level === 0) {\n output = undefined;\n } else {\n output = \"{{delete:\" + level + \"}}\";\n }\n return output;\n}\n\n/**\n * Extract the level from a `{{delete:NNN}}`\n */\nvar getLevel = function (value) { return parseInt(value.replace(/{|}/g, '').split(':')[1]); };\n\n/**\n * Simple check if a value has `{{delete` in it\n */\nfunction hasDelete (value) {\n if (value && typeof value === 'string') {\n return value.indexOf('{{delete') > -1;\n } else {\n return false;\n }\n}\n\nvar isString = function (v) { return typeof v === 'string'; };\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * Optional Transform\n * Supports a declarative syntax for optional template properties\n *\n * {{some.object.key:optional:2}}\n *\n * In this example, if defined, the value of `some.object.key` is used.\n * If not defined, then the optional transform is utilized\n * and a post-processing step is executed which will remove two parent levels\n * from the output structure\n */\n\nfunction optionalTransform(key, value, settings, level) {\n if ( level === void 0 ) level = 0;\n\n // console.log(`optional: ${key}, ${value}, ${level}`);\n var val = value;\n if (!value) {\n val = \"{{delete:\" + level + \"}}\";\n }\n return val;\n}\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\n\n/**\n * ```js\n * import { cloneObject } from \"./cloneObject\";\n * const original = { foo: \"bar\" }\n * const copy = cloneObject(original)\n * copy.foo // \"bar\"\n * copy === original // false\n * ```\n * Make a deep clone, including arrays. Does not handle functions!\n *\n * Copied from @esri/hub-common to avoid bringing along that package's\n * dependencies, @esri/hub-common should be made a dependency if more\n * functions are needed from it in the future\n */\nvar cloneObject = function (obj) {\n var clone = {};\n // first check array\n if (Array.isArray(obj)) {\n clone = obj.map(cloneObject);\n } else if (typeof obj === \"object\") {\n for (var i in obj) {\n if (obj[i] != null && typeof obj[i] === \"object\") {\n clone[i] = cloneObject(obj[i]);\n } else {\n clone[i] = obj[i];\n }\n }\n } else {\n clone = obj;\n }\n return clone;\n};\n\n/* Copyright (c) 2017-2019 Esri Inc.\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n http://www.apache.org/licenses/LICENSE-2.0\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License. */\nvar HANDLEBARS = /{{\\s*?[\\w].*?}}/g;\n\nvar isString$1 = function (v) { return typeof v === 'string'; };\n\nfunction _swap(parameter, settings, transforms) {\n var value;\n // console.info(`_swap: param: ${parameter}`);\n // Parameters can optionally call transform functions\n // e.g. \"{{ipsum:translateLatin}}\"\n // so extract {{<parameter>:<transformFunction>:<key||value>}}\n var transformCheck = parameter.split(':');\n if (transformCheck.length > 1) {\n // we have a request to use a transform...\n var key = transformCheck[0];\n var fn = transformCheck[1];\n // we default to using the value...\n var param;\n if (transformCheck[2]){\n param = transformCheck[2];\n }\n if(transforms && transforms[fn] && typeof transforms[fn] === 'function') {\n // get the value from the param\n value = getWithDefault(settings, key);\n // transform it...\n value = transforms[fn](key, value, settings, param);\n } else {\n throw new Error((\"Attempted to apply non-existant transform \" + fn + \" on \" + key + \" with params \" + parameter));\n }\n } else {\n // we just get the value\n value = getWithDefault(settings, parameter);\n }\n return value;\n}\n\n/**\n * Does a propertyPath exist on a target\n */\nfunction _propertyPathExists (propertyPath, target) {\n // remove any transforms\n var cleanPath = propertyPath.split(':')[0];\n var value = getWithDefault(target, cleanPath, null);\n if (value !== null && value !== undefined) {\n return true;\n } else {\n return false;\n }\n}\n\n/**\n * Is the value considered valid\n */\nfunction _isValue (val) {\n return val || val === '' || val === 0;\n}\n\n// Combine a Template with Settings\nfunction adlib (template, settings, transforms) {\n if ( transforms === void 0 ) transforms = null;\n\n transforms = cloneObject(transforms) || {};\n if (transforms.optional) {\n throw new Error('Please do not pass in an `optional` transform; adlib provides that internally.');\n } else {\n transforms.optional = optionalTransform;\n }\n\n var res = deepMapValues(template, function(templateValue, templatePath){\n // Only string templates\n if (!isString$1(templateValue)) {\n return templateValue;\n }\n\n // When we match \"{{layer.fields..}}\"\n var settingsValue;\n\n var hbsEntries = templateValue.match(HANDLEBARS);\n\n if (hbsEntries && hbsEntries.length) {\n // console.log(`Got a ${hbsEntries.length} handlebar entries...`);\n // iterate over the entries...\n var values = hbsEntries.map(function (entry) {\n var isStaticValue = false;\n // console.info(`Matched ${entry}...`);\n // strip off the curlies and trim any leading/trailing whitespace...\n var path = entry.replace(/{|}/g, '').trim();\n // check for || which indicate a hiearchy\n if (path.indexOf('||') > -1) {\n var paths = path.split('||').map(function (path) { return path.trim(); });\n var numberOfPaths = paths.length;\n // here we check each option, in order, and return the first with a value in the hash, OR the last\n path = paths.find(function (pathOption, idx) {\n // console.info(`Checking to see if ${pathOption} is in settings hash...`);\n var exists = _propertyPathExists(pathOption, settings);\n if (!exists) {\n if ((idx + 1) === numberOfPaths) {\n // console.info(`Got to last entry, and still did not find anything... assuming ${pathOption} is a static value...`);\n isStaticValue = true;\n // check if we can convert this into a number...\n if (!isNaN(pathOption)) {\n pathOption = parseInt(pathOption);\n }\n return pathOption;\n } else {\n return false;\n }\n } else {\n return pathOption;\n }\n });\n }\n // setup the return value...\n var result = {\n key: entry,\n value: path\n };\n // if we have a valid object path, value comes from _swap\n if (!isStaticValue) {\n var swap = _swap(path, settings, transforms);\n result.value = _isValue(swap) ? swap : entry;\n }\n // console.info(`Value: ${JSON.stringify(result)}`);\n return result;\n });\n\n values.forEach(function (v) {\n // console.log(`Comparing ${templateValue} with ${v.key}`)\n if (templateValue === v.key) {\n // console.log(`template matches key, returning ${v.value}`);\n // if the value is a string...\n if (typeof v.value === 'string') {\n // and it's numeric-ish\n if(!isNaN(v.value) && v.value !== '') {\n // and has a . in it...\n if (v.value.indexOf('.') > -1) {\n // parse as a float...\n v.value = parseFloat(v.value);\n } else {\n // parse as an int\n v.value = parseInt(v.value);\n }\n }\n }\n settingsValue = v.value;\n } else {\n // a little extra regex dance to match the '||' because '|'\n // is a Very Special Regex Character and we need to super\n // escape them for the regex to work\n // console.log(`KEY ${v.key}`);\n // console.log(`TEMPLATE ${templateValue}`);\n templateValue = templateValue.replace(v.key, v.value);\n // console.log(`template did not match key, interpolating value ${v.value} into template to produce ${templateValue}`);\n }\n });\n\n // if we have a value, let's return that...\n if (_isValue(settingsValue)) {\n // console.log(`We found a value so we return it ${settingsValue}`);\n return settingsValue;\n } else {\n // console.log(`We did not find a value so we return the template ${templateValue}`);\n // but if we don't, lets return the template itself\n return templateValue;\n }\n } else {\n // console.log(`We did not find a hbs match, so we return the template ${templateValue}`);\n // no match, return the templateValue...\n return templateValue;\n }\n });\n return arborist(res);\n}\n\n// read a template and spit out unique values\nfunction listDependencies (template) {\n if (typeof template !== 'string') {\n template = JSON.stringify(template);\n }\n\n try {\n return Array.from(\n new Set(\n template.match(HANDLEBARS)\n )\n )\n .map(function (term) {\n return term.replace(/^{{/g, '').replace(/}}$/g, '').replace(/:.+$/, '')\n // Node > 10 and browsers support this w/ a lookahead\n // won't need to use the replace\n // /(?<={{)[\\w].*?(?=}})/g\n })\n } catch (e) {\n console.error(e);\n }\n}\n\nexport { adlib, arborist, deepMapValues, getPropertyValue, getWithDefault, listDependencies, mapValues, optionalTransform, pruneArray, pruneObject };\n","import { adlib } from \"adlib\";\n/**\n * Interpolates handlebars-style placeholders on an object graph\n * @param template\n * @param settings\n * @param transforms\n */\nexport function interpolate(template, settings, transforms) {\n return adlib(template, settings, transforms);\n}\n//# sourceMappingURL=interpolate.js.map","import { interpolate } from \"./interpolate\";\n/**\n * Interpolate the item id back into any {{appid}} instances\n * in the item. Allows for self-referencing in templates\n * @param {object} model Item Model\n */\nexport function interpolateItemId(model) {\n var settings = { item: { id: model.item.id }, appid: model.item.id };\n var transforms = {\n toISO: function (_, v) {\n return v;\n }\n };\n return interpolate(model, settings, transforms);\n}\n//# sourceMappingURL=interpolate-item-id.js.map","import { cloneObject } from \"../util\";\nexport var itemPropsNotInTemplates = [\n \"id\",\n \"isOrgItem\",\n \"proxyFilter\",\n \"ownerFolder\",\n \"protected\",\n \"owner\",\n \"created\",\n \"modified\",\n \"guid\",\n \"name\",\n \"access\",\n \"size\",\n \"listed\",\n \"numComments\",\n \"numRatings\",\n \"avgRating\",\n \"numViews\",\n \"scoreCompleteness\",\n \"groupDesignations\",\n \"listed\",\n \"screenshots\",\n \"banner\",\n \"appCategories\",\n \"industries\",\n \"languages\",\n \"largeThumbnail\"\n];\n/**\n * Given an item, remove a standard set of properties not needed in a template\n * TODO: This should land in a templating helper lib in hub.js\n * @param {Object} item Item to be normalized\n */\nexport function normalizeSolutionTemplateItem(item) {\n var template = cloneObject(item);\n itemPropsNotInTemplates.forEach(function (prop) {\n delete template[prop];\n });\n // set a bunch of things we do want\n template.extent = \"{{organization.defaultExtentBBox}}\";\n return template;\n}\n//# sourceMappingURL=normalize-solution-template-item.js.map","import { cloneObject } from \"../util\";\nimport { deepStringReplace } from \"../objects\";\n/**\n * Replaces instances of item ids on an item model\n * @param {Object} obj Object graph to traverse\n * @param {string} itemId id to replace with `{{appid}}`\n */\nexport function replaceItemId(obj, itemId, replacement) {\n if (replacement === void 0) { replacement = \"{{appid}}\"; }\n var clone = cloneObject(obj);\n var re = new RegExp(itemId, \"g\");\n return deepStringReplace(clone, re, replacement);\n}\n//# sourceMappingURL=replace-item-id.js.map","import { shareItemWithGroup, } from \"@esri/arcgis-rest-portal\";\n/**\n * Share an item to a set of groups\n * @param {String} itemId Iten Id to share to the groups\n * @param {Array} groups Array of group id's to which the item will be shared\n * @param {String} owner optional Owner username to determine which endpoint to hit\n * @param {*} requestOptions\n */\nexport function shareItemToGroups(itemId, groups, requestOptions, owner) {\n return Promise.all(groups.map(function (groupId) {\n var opt = Object.assign({}, { id: itemId, groupId: groupId }, requestOptions);\n if (owner) {\n opt.owner = owner;\n }\n return shareItemWithGroup(opt);\n }));\n}\n//# sourceMappingURL=share-item-to-groups.js.map","import { unprotectItem } from \"@esri/arcgis-rest-portal\";\n/**\n * Given a model, determine if it is protected, and unprotect it if it is.\n * Otherwise, just resolve with the same result.\n * @param {Object} model Model Object\n * @param {IRequestOptions} requestOptions\n */\nexport function unprotectModel(model, requestOptions) {\n if (model.item.protected) {\n var opts = Object.assign({ id: model.item.id }, requestOptions);\n return unprotectItem(opts);\n }\n else {\n // act as though we did it\n return Promise.resolve({ success: true });\n }\n}\n//# sourceMappingURL=unprotect-model.js.map","import { unshareItemWithGroup, } from \"@esri/arcgis-rest-portal\";\n/**\n * Unshare an item from a set of groups\n * @param {String} itemId Item Id to unshare from groups\n * @param {Array} groups Array of group id's from which the item will be unshared\n * @param {String} owner optional Owner username to determine which endpoint to hit\n * @param {IRequestOptions} requestOptions\n */\nexport function unshareItemFromGroups(itemId, groups, requestOptions, owner) {\n return Promise.all(groups.map(function (groupId) {\n var opt = Object.assign({}, { id: itemId, groupId: groupId }, requestOptions);\n if (owner) {\n opt.owner = owner;\n }\n return unshareItemWithGroup(opt);\n }));\n}\n//# sourceMappingURL=unshare-item-from-groups.js.map","import { searchItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Check if a site/page exists with a specific name\n */\nexport function doesItemExistWithTitle(itemTitle, options, authMgr) {\n // if options have multiple properties, put them into one string separated with 'AND'\n var optionsQuery = Object.keys(options)\n .map(function (key) {\n return key + \":\\\"\" + options[key] + \"\\\"\";\n })\n .join(\" AND \");\n var opts = {\n q: \"title:\\\"\" + itemTitle + \"\\\" AND \" + optionsQuery,\n authentication: authMgr\n };\n return searchItems(opts)\n .then(function (searchResponse) { return searchResponse.results.length > 0; })\n .catch(function (e) {\n throw Error(\"Error in doesItemExistWithTitle \" + e);\n });\n}\n//# sourceMappingURL=does-item-exist-with-title.js.map","import { doesItemExistWithTitle } from \"./does-item-exist-with-title\";\n/**\n * Given a title, construct a site/page title that is unique\n * if that title exists, this fn will add a number on the end, and increment until\n * an available title is found\n * @param {string} title site/page title to ensure if unique\n * @param {object} options an object that can be passed in to the q, eg. typekeywords, type\n * @param {object} authMgr auth info tells the function what url to use for the \"root\" of the API,\n * if missing, it will search against PROD\n * @param {number} step Number to increment. Defaults to 0\n */\nexport function getUniqueItemTitle(title, options, authMgr, step) {\n if (step === void 0) { step = 0; }\n var combinedName = title;\n if (step) {\n combinedName = title + \" \" + step;\n }\n return doesItemExistWithTitle(combinedName, options, authMgr)\n .then(function (result) {\n if (result) {\n step++;\n return getUniqueItemTitle(title, options, authMgr, step);\n }\n else {\n return combinedName;\n }\n })\n .catch(function (e) {\n throw Error(\"Error in getUniqueItemTitle \" + e);\n });\n}\n//# sourceMappingURL=get-unique-item-title.js.map","import { __assign, __spreadArrays } from \"tslib\";\nimport { batch } from \"../utils/batch\";\nvar MAX_NUM = 100;\n/**\n * Fetches all the pages in a search request\n * @param {SearchFunction} searchFunc\n * @param {ISearchOptions} opts\n * @param {number} limit\n * @param {batchSize} number of concurrent requests at a time\n * @returns {Promise<SearchableType[]>}\n */\nexport function fetchAllPages(searchFunc, opts, limit, batchSize) {\n if (limit === void 0) { limit = -1; }\n var pageSize = opts.num || MAX_NUM;\n var firstStart = opts.start || 1;\n // If a limit is provided, we don't have to use the first request to get the\n // total count before sending things off to batch(). So instead we fake the first\n // response just to set things up.\n var promise = limit === -1\n ? searchFunc(__assign(__assign({}, opts), { num: pageSize, start: firstStart }))\n : Promise.resolve({\n nextStart: firstStart,\n total: limit,\n results: [],\n num: pageSize\n });\n return promise\n .then(function (firstResponse) {\n // no more requests needed, return the first response\n if (firstResponse.nextStart === -1)\n return [firstResponse];\n // generate batch requests for the remaining pages to fetch\n var starts = [];\n for (var i = firstResponse.nextStart; i <= firstResponse.total; i += pageSize) {\n starts.push(i);\n }\n var batchSearchFunc = function (start) {\n return searchFunc(__assign(__assign({}, opts), { start: start, num: pageSize }));\n };\n return batch(starts, batchSearchFunc, batchSize).then(function (responses) { return __spreadArrays([\n firstResponse\n ], responses); });\n })\n .then(function (responses) {\n // merge all the search results into a single array\n var results = responses.reduce(function (acc, response) { return __spreadArrays(acc, response.results); }, []);\n // discard results beyond the limit if applicable\n var clipLimit = limit === -1 ? results.length : limit;\n return results.slice(0, clipLimit);\n });\n}\n//# sourceMappingURL=fetch-all-pages.js.map","/**\n * Add a token to the resource request if the request is to the portal\n * @param {string} url Resource Url\n * @param {IRequestOptions} requestOptions\n * @private\n */\nexport function _addTokenToResourceUrl(url, requestOptions) {\n var result = url;\n if (url.indexOf(\"token\") === -1) {\n // no token\n // Note: authentication.portal is a fully org url\n // i.e. https://dcdev.maps.arcgis.com/sharing/rest\n // this may need to be smarter to handle non-public solutions\n // shared across orgs\n if (url.indexOf(requestOptions.authentication.portal) > -1) {\n // is the portal\n result = url + \"?token=\" + requestOptions.authentication.token;\n }\n }\n return result;\n}\n//# sourceMappingURL=_add-token-to-resource-url.js.map","import { getPortalApiUrl } from \"../urls\";\n/**\n * Convert the resources array on an individual template in a solution\n * into an assets array that can be used to upload the resources to\n * the newly created item.\n * @param {object} template Template from a Solution\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function convertSolutionTemplateResourcesToAssets(template, hubRequestOptions) {\n var assets = [];\n if (template.resources && template.bundleItemId) {\n var portalRestUrl = getPortalApiUrl(hubRequestOptions.portalSelf);\n // the resources are stored on the solution item, and that Id is attached\n // into the template as .bundleItemId\n var solutionItemUrl_1 = portalRestUrl + \"/content/items/\" + template.bundleItemId;\n // the resources on the solution are prefixed with the item id of the item the\n // template was created from, which is stored as .itemId\n var prefix_1 = template.itemId;\n // map over the resources and convert them into assets\n assets = template.resources.map(function (name) {\n // we fetch the resource from .url property\n // and we upload it using the .name property\n return {\n name: name,\n type: \"resource\",\n url: solutionItemUrl_1 + \"/resources/\" + prefix_1 + \"-\" + name\n };\n });\n }\n return assets;\n}\n//# sourceMappingURL=convert-solution-template-resources-to-assets.js.map","/**\n * Given a url to an image, return it as a blob\n * @param {String} url Url to fetch the image from. Must have token if it's a non-publi item resource url\n * @param {Object} options additional optinos\n */\nexport function fetchImageAsBlob(url, options) {\n if (options === void 0) { options = {}; }\n if (!options.credentials) {\n options.credentials = \"same-origin\";\n }\n // We use fetch intentionally as the url may or may not be for an item url, so we don't\n // want this to run thru the main request logic\n return fetch(url, options).then(function (response) {\n return response.blob();\n });\n}\n//# sourceMappingURL=fetch-image-as-blob.js.map","import { addItemResource } from \"@esri/arcgis-rest-portal\";\nimport { fetchImageAsBlob } from \"./fetch-image-as-blob\";\n/**\n * Fetch image from a url, and upload as a resource\n * @param {Object} options {id, owner, fileName, url, authentication}\n */\nexport function fetchAndUploadResource(options) {\n // first fetch it as a blob...\n return fetchImageAsBlob(options.url).then(function (file) {\n // upload it to the item...\n return addItemResource({\n id: options.id,\n owner: options.owner,\n name: options.fileName,\n resource: file,\n authentication: options.authentication\n });\n });\n}\n//# sourceMappingURL=fetch-and-upload-resource.js.map","import { fetchImageAsBlob } from \"./fetch-image-as-blob\";\nimport { updateItem } from \"@esri/arcgis-rest-portal\";\n/**\n * Fetch image from a url, then upload to an item as it's thumbnail\n * @param {object} options\n */\nexport function fetchAndUploadThumbnail(options) {\n // first fetch it as a blob...\n return fetchImageAsBlob(options.url)\n .then(function (file) {\n return updateItem({\n item: {\n id: options.id,\n owner: options.owner\n },\n params: {\n fileName: options.fileName,\n thumbnail: file\n },\n authentication: options.authentication\n }).catch(function (_) {\n // resolve b/c this is not crtical\n return Promise.resolve();\n });\n })\n .catch(function (_) {\n return Promise.resolve();\n });\n}\n//# sourceMappingURL=fetch-and-upload-thumbnail.js.map","import { getItemApiUrl } from \"../urls/get-item-api-url\";\n/**\n * Get the fully qualified URL for an item's thumbnail\n * @param item w/ id, thumbnail, and access\n * @param portalUrlOrObject a portal base or API URL, a portal object, or request options containing either of those\n * @param optionsOrToken options including width and/or token for the current user's session; will only be appended as a query parameter if the item's access is **not** `public`\n * @returns URL to the item's thumbnail, defaults to `https://www.arcgis.com/sharing/rest/content/items/{item.id}/info/{item.thumbnail}`. Returns `null` if the item does not have a thumbnail assigned.\n */\nexport function getItemThumbnailUrl(item, portalUrlOrObject, optionsOrToken) {\n if (!item || !item.thumbnail) {\n // TODO: handle image types by returning the image (item data) itself?\n return null;\n }\n // tslint:disable-next-line prefer-const\n var _a = optionsOrToken || {}, token = _a.token, width = _a.width;\n // TODO: at the next breaking change drop support for passing token as string\n if (!token && typeof optionsOrToken === \"string\") {\n token = optionsOrToken;\n }\n var itemApiUrl = getItemApiUrl(item, portalUrlOrObject, token);\n var _b = itemApiUrl.split(\"?\"), baseUrl = _b[0], search = _b[1];\n var searchParams = new URLSearchParams(search);\n searchParams.delete(\"f\");\n if (width) {\n searchParams.append(\"w\", width + \"\");\n }\n var newSearch = searchParams.toString();\n var url = baseUrl + \"/info/\" + item.thumbnail;\n return newSearch ? url + \"?\" + newSearch : url;\n}\n//# sourceMappingURL=get-item-thumbnail-url.js.map","import { getPortalApiUrl } from \"../urls\";\nimport { getItemThumbnailUrl } from \"./get-item-thumbnail-url\";\nimport { getItemResources } from \"@esri/arcgis-rest-portal\";\n/**\n * Given an item, return an array of assets that includes\n * all the resources, as well as the thumbnail\n * @param {object} item Item\n * @param {IHubRequestOptions} IHubRequestOptions\n */\nexport function getItemAssets(item, hubRequestOptions) {\n var portalRestUrl = getPortalApiUrl(hubRequestOptions.portalSelf);\n var itemUrl = portalRestUrl + \"/content/items/\" + item.id;\n // if construct the asset for the thumbnail\n var thumbnailUrl = getItemThumbnailUrl(item, hubRequestOptions);\n var assets = [];\n if (thumbnailUrl) {\n assets.push({\n name: item.thumbnail,\n url: thumbnailUrl,\n type: \"thumbnail\"\n });\n }\n // get all the other resources\n // TODO: see how this works w/ folders\n return getItemResources(item.id, hubRequestOptions).then(function (response) {\n var resourceAssets = response.resources.map(function (e) {\n return {\n name: e.resource,\n type: \"resource\",\n url: itemUrl + \"/resources/\" + e.resource\n };\n });\n return assets.concat(resourceAssets);\n });\n}\n//# sourceMappingURL=get-item-assets.js.map","/**\n * Given a string, return it as a blob\n * NOTE: USE objectToJsonBlob if you're saving a JSON resource!!!\n * NOTE: This is not currently supported in Node\n * @param {string} the string\n */\nexport function stringToBlob(s, type) {\n if (type === void 0) { type = \"application/octet-stream\"; }\n /* istanbul ignore next */\n if (typeof Blob !== \"undefined\") {\n var bytes = [];\n for (var i = 0; i < s.length; i++) {\n bytes[i] = s.charCodeAt(i);\n }\n var encoded = new Uint8Array(bytes);\n return new Blob([encoded], { type: type });\n }\n else {\n throw new Error(\"stringToBlob is not currently supported on Node\");\n }\n}\n//# sourceMappingURL=string-to-blob.js.map","import { fetchAndUploadResource } from \"./fetch-and-upload-resource\";\nimport { fetchAndUploadThumbnail } from \"./fetch-and-upload-thumbnail\";\nimport { _addTokenToResourceUrl } from \"./_add-token-to-resource-url\";\n/**\n * Given an Item and an array of resources, upload them\n * @param {Object} itemModel Item add the resource to\n * @param {Array} resources Array of resources, with urls, to upload to the item\n * @param {Object} requestOptions {authentication}\n */\nexport function uploadResourcesFromUrl(itemModel, resources, requestOptions) {\n if (Array.isArray(resources)) {\n var resourcePromises = resources.reduce(function (acc, resource) {\n if (resource.url) {\n var opts = {\n id: itemModel.item.id,\n owner: itemModel.item.owner,\n fileName: resource.name,\n url: _addTokenToResourceUrl(resource.url, requestOptions),\n authentication: requestOptions.authentication\n };\n if (resource.type === \"thumbnail\") {\n acc.push(fetchAndUploadThumbnail(opts));\n }\n else {\n // treat as a resource\n acc.push(fetchAndUploadResource(opts));\n }\n }\n return acc;\n }, []);\n // Let them resolve...\n return Promise.all(resourcePromises);\n }\n else {\n return Promise.resolve([]);\n }\n}\n//# sourceMappingURL=upload-resources-from-url.js.map","import { getPortalApiUrl } from \"../urls\";\n/**\n * Add a url property to the entries in the assets hash\n * @param {IModelTemplate} template\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function addSolutionResourceUrlToAssets(template, hubRequestOptions) {\n /* istanbul ignore next */\n var assets = template.assets || template.resources || [];\n if (template.bundleItemId) {\n var portalRestUrl = getPortalApiUrl(hubRequestOptions.portalSelf);\n // the resources are stored on the solution item, and that Id is attached\n // into the template as .bundleItemId\n var solutionItemUrl_1 = portalRestUrl + \"/content/items/\" + template.bundleItemId;\n // the resources on the solution are prefixed with the item id of the item the\n // template was created from, which is stored as .itemId\n var prefix_1 = template.itemId;\n // map over the resources and convert them into assets\n assets = assets.map(function (asset) {\n // we fetch the resource from .url property\n // and we upload it using the .name property\n return {\n name: asset.name,\n type: asset.type || \"resource\",\n url: solutionItemUrl_1 + \"/resources/\" + prefix_1 + \"-\" + asset.name\n };\n });\n }\n return assets;\n}\n//# sourceMappingURL=add-solution-resource-url-to-assets.js.map","/**\n * Convert an object to a Blob with type 'application/json'\n * @param {*} obj\n * @returns Blob\n */\nexport function objectToJsonBlob(obj) {\n /* istanbul ignore next */\n if (typeof Blob !== \"undefined\") {\n return new Blob([JSON.stringify(obj)], { type: \"application/json\" });\n }\n else {\n throw new Error(\"objectToJsonBlob is not currently supported on Node\");\n }\n}\n//# sourceMappingURL=object-to-json-blob.js.map","import { __assign } from \"tslib\";\nimport { hubApiRequest } from \"..\";\n/**\n * Search the Hub API\n *\n * @param requestOptions\n * @returns JSONAPI response\n */\nexport function hubApiSearch(requestOptions) {\n // derive default headers if authentication\n var authentication = requestOptions.authentication;\n var headers = authentication &&\n authentication.serialize && { authentication: authentication.serialize() };\n var defaults = {\n headers: headers,\n httpMethod: \"POST\",\n };\n return hubApiRequest(\"/search\", __assign(__assign({}, defaults), requestOptions));\n}\n//# sourceMappingURL=hub-api-search.js.map","/* Copyright (c) 2018-2021 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __spreadArrays } from \"tslib\";\nimport { UserSession } from \"@esri/arcgis-rest-auth\";\nimport { cloneObject, unique } from \"../util\";\n/**\n * Well known APIs\n * Short-forms for specifying common APIs\n * We will likely deprecate this\n */\nexport var SEARCH_APIS = {\n arcgis: {\n label: \"ArcGIS Online\",\n url: \"https://www.arcgis.com\",\n type: \"arcgis\",\n },\n arcgisQA: {\n label: \"ArcGIS Online QAEXT\",\n url: \"https://qaext.arcgis.com\",\n type: \"arcgis\",\n },\n arcgisDEV: {\n label: \"ArcGIS Online DEVEXT\",\n url: \"https://devext.arcgis.com\",\n type: \"arcgis\",\n },\n hub: {\n label: \"ArcGIS Hub\",\n url: \"https://hub.arcgis.com/api\",\n type: \"arcgis-hub\",\n },\n hubDEV: {\n label: \"ArcGIS Hub DEV\",\n url: \"https://hubdev.arcgis.com/api\",\n type: \"arcgis-hub\",\n },\n hubQA: {\n label: \"ArcGIS Hub QA\",\n url: \"https://hubqa.arcgis.com/api\",\n type: \"arcgis-hub\",\n },\n};\n/**\n * @private\n * Convert array of api \"names\" into full ApiDefinitions\n * @param apis\n * @returns\n */\nexport function expandApis(apis) {\n return apis.map(expandApi);\n}\n/**\n * @private\n * Convert an api \"name\" into a full ApiDefinition\n * @param api\n * @returns\n */\nexport function expandApi(api) {\n if (typeof api === \"string\" && api in SEARCH_APIS) {\n return SEARCH_APIS[api];\n }\n else {\n // it's an object, so we trust that it's well formed\n return api;\n }\n}\n/**\n * @private\n * Merge two date ranges by taking the longest span\n * @param dr1\n * @param dr2\n * @returns\n */\nexport function mergeDateRange(dr1, dr2) {\n var result = cloneObject(dr1);\n // feels like there is a more concise way to do this...\n if (dr2.from < dr1.from) {\n result.from = dr2.from;\n }\n if (dr2.to > dr1.to) {\n result.to = dr2.to;\n }\n return result;\n}\n/**\n * @private\n * Merge two [`MatchOptions`](../MatchOptions)\n *\n * Currently a naieve implementation where the arrays are simply merged\n *\n * @param mo1\n * @param mo2\n * @returns\n */\nexport function mergeMatchOptions(mo1, mo2) {\n var result = {};\n // None of these props are required, so we can't just\n // use Object.keys/.entries\n var props = [\"any\", \"all\", \"not\", \"exact\"];\n props.forEach(function (prop) {\n var key = prop;\n var merged = __spreadArrays(getMatchValue(mo1, key), getMatchValue(mo2, key));\n if (merged.length) {\n // remove any dupes and set on the return\n result[key] = merged.filter(unique);\n }\n });\n return result;\n}\n/**\n * Get the value of a property on an IMatchOptions\n *\n * This is complex b/c all the props are optional, and\n * they could be a simple string, or an array of strings.\n *\n * This function normalizes all that and returns an array,\n * which may or may not be empty\n * @param option\n * @param key\n * @returns\n */\nfunction getMatchValue(option, key) {\n var matchValue = [];\n if (option[key]) {\n var val = option[key];\n if (Array.isArray(val)) {\n matchValue = val;\n }\n else {\n matchValue = [val];\n }\n }\n return matchValue;\n}\n/**\n * @private\n * Convert a field value into a MatchOptions if it's not already one\n * @param value\n * @returns\n */\nexport function valueToMatchOptions(value) {\n var result = {};\n if (Array.isArray(value)) {\n result = {\n any: value,\n };\n }\n else {\n if (typeof value === \"string\") {\n result = {\n any: [value],\n };\n }\n if (typeof value === \"object\") {\n result = value;\n }\n }\n return result;\n}\n/**\n * @private\n * Convert a RelativeDate to a DateRange<number>\n * @param relative\n * @returns\n */\nexport function relativeDateToDateRange(relative) {\n // hash of offsets\n var offsetMs = {\n min: 1000 * 60,\n hours: 1000 * 60 * 60,\n days: 1000 * 60 * 60 * 24,\n weeks: 1000 * 60 * 60 * 24 * 7,\n };\n var now = new Date();\n // default\n var result = {\n type: \"date-range\",\n from: now.getTime(),\n to: now.getTime(),\n };\n //\n switch (relative.unit) {\n case \"hours\":\n case \"days\":\n case \"weeks\":\n result.from = result.to - offsetMs[relative.unit] * relative.num;\n break;\n case \"months\":\n // get the current month and subtract num\n now.setMonth(now.getMonth() - relative.num);\n result.from = now.getTime();\n break;\n case \"years\":\n now.setFullYear(now.getFullYear() - relative.num);\n result.from = now.getTime();\n break;\n }\n return result;\n}\n/**\n * @private\n * As a final `ISearchOptions` object gets created, many such objects are created, and\n * need to be systematically \"merged\" so as to return consistently structured `q` and `filter`\n * values.\n * @param so1\n * @param so2\n * @param join\n * @returns\n */\nexport function mergeSearchOptions(so1, so2, join) {\n var result = cloneObject(so1);\n var q = so2.q, filter = so2.filter;\n if (q) {\n result.q = (result.q ? \" (\" + result.q + \" \" + join + \" \" + q + \")\" : q).trim();\n }\n if (filter) {\n result.filter = (result.filter ? \"(\" + result.filter + \" \" + join + \" \" + filter + \")\" : filter).trim();\n }\n return result;\n}\n/**\n * @private\n * Serialize a `MatchOptions` into `q` or `filter` on an `ISearchOptions`\n * @param key\n * @param opts\n * @returns\n */\nexport function serializeMatchOptions(key, opts) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n if (opts.exact) {\n // defined separately for refactoring later\n var userFilterableFields = [\n \"username\",\n \"firstname\",\n \"lastname\",\n \"fullname\",\n \"email\",\n ];\n var itemFilterableFields = [\n \"title\",\n \"tags\",\n \"typekeywords\",\n \"type\",\n \"name\",\n \"owner\",\n ];\n var groupFilterableFields = [\"title\", \"typekeywords\", \"owner\"];\n var filterableFields = __spreadArrays(userFilterableFields, itemFilterableFields, groupFilterableFields);\n if (filterableFields.includes(key)) {\n result.filter = serializeStringOrArray(\"AND\", key, opts.exact);\n }\n else {\n // Treat it the same as .all\n if (typeof opts.exact === \"string\") {\n if (!opts.all) {\n opts.all = [];\n }\n if (typeof opts.all === \"string\") {\n opts.all = [opts.all];\n }\n opts.all.push(opts.exact);\n }\n if (Array.isArray(opts.exact)) {\n if (!opts.all) {\n opts.all = [];\n }\n if (typeof opts.all === \"string\") {\n opts.all = [opts.all];\n }\n opts.all = opts.all.concat(opts.exact);\n }\n }\n }\n // Handle the other props\n if (opts.any) {\n result.q = serializeStringOrArray(\"OR\", key, opts.any);\n }\n if (opts.all) {\n result.q =\n (result.q ? result.q + \" AND \" : \"\") +\n serializeStringOrArray(\"AND\", key, opts.all);\n }\n if (opts.not) {\n // negate the entries if they are not\n result.q =\n (result.q ? result.q + \" AND \" : \"\") +\n serializeStringOrArray(\"OR\", \"-\" + key, opts.not);\n }\n return result;\n}\n/**\n * @private\n * Serialize a DateRange<number> into a Portal Query string\n * @param key\n * @param range\n * @returns\n */\nexport function serializeDateRange(key, range) {\n return {\n q: key + \":[\" + range.from + \" TO \" + range.to + \"]\",\n filter: \"\",\n };\n}\n/**\n * @private\n * Serialize a `string` or `string[]` into a string\n * @param join\n * @param key\n * @param value\n * @returns\n */\nexport function serializeStringOrArray(join, key, value) {\n var q = \"\";\n if (Array.isArray(value)) {\n q = \"(\" + key + \":\\\"\" + value.join(\"\\\" \" + join + \" \" + key + \":\\\"\") + \"\\\")\";\n }\n else {\n q = key + \":\\\"\" + value + \"\\\"\";\n }\n return q;\n}\n/**\n * Create a `.next()` function for a type\n * @param request\n * @param nextStart\n * @param total\n * @param fn\n * @returns\n */\nexport function getNextFunction(request, nextStart, total, fn) {\n var clonedRequest = cloneObject(request);\n // clone will not handle authentication so we do it manually\n if (request.authentication) {\n clonedRequest.authentication = UserSession.deserialize(request.authentication.serialize());\n }\n // figure out the start\n clonedRequest.start = nextStart > -1 ? nextStart : total + 1;\n return function (authentication) {\n if (authentication) {\n clonedRequest.authentication = authentication;\n }\n return fn(clonedRequest);\n };\n}\n/**\n * Construct a the full url to a group thumbnail\n *\n * - If the group has a thumbnail, construct the full url\n * - If the group is not public, append on the token\n * @param portalUrl\n * @param group\n * @param token\n * @returns\n */\nexport function getGroupThumbnailUrl(portalUrl, group, token) {\n var thumbnailUrl = null;\n if (group.thumbnail) {\n thumbnailUrl = portalUrl + \"/community/groups/\" + group.id + \"/info/\" + group.thumbnail;\n if (token && group.access !== \"public\") {\n thumbnailUrl = thumbnailUrl + \"?token=\" + token;\n }\n }\n return thumbnailUrl;\n}\n/**\n * Construct a the full url to a user thumbnail\n *\n * - If the user has a thumbnail, construct the full url\n * - If the user is not public, append on the token\n * @param portalUrl\n * @param user\n * @param token\n * @returns\n */\nexport function getUserThumbnailUrl(portalUrl, user, token) {\n var thumbnailUrl = null;\n if (user.thumbnail) {\n thumbnailUrl = portalUrl + \"/community/users/\" + user.username + \"/info/\" + user.thumbnail;\n if (token && user.access !== \"public\") {\n thumbnailUrl = thumbnailUrl + \"?token=\" + token;\n }\n }\n return thumbnailUrl;\n}\n//# sourceMappingURL=utils.js.map","import { __spreadArrays } from \"tslib\";\nimport { cloneObject } from \"..\";\nimport { mergeDateRange, mergeMatchOptions, mergeSearchOptions, relativeDateToDateRange, serializeDateRange, serializeMatchOptions, valueToMatchOptions, } from \"./utils\";\n// TODO: Implement $dataset\nvar ContentFilterExpansions = {\n $apps: [\n {\n type: {\n any: [\n \"Code Sample\",\n \"Web Mapping Application\",\n \"Mobile Application\",\n \"Application\",\n \"Desktop Application Template\",\n \"Desktop Application\",\n \"Operation View\",\n \"Dashboard\",\n \"Operations Dashboard Extension\",\n \"Workforce Project\",\n \"Insights Workbook\",\n \"Insights Page\",\n \"Insights Model\",\n \"Hub Page\",\n \"Hub Initiative\",\n \"Hub Site Application\",\n \"StoryMap\",\n \"Web Experience\",\n \"Web Experience Template\",\n \"Form\",\n ],\n not: [\n \"Code Attachment\",\n \"Featured Items\",\n \"Symbol Set\",\n \"Color Set\",\n \"Windows Viewer Add In\",\n \"Windows Viewer Configuration\",\n \"Map Area\",\n \"Indoors Map Configuration\",\n ],\n },\n typekeywords: {\n not: [\"MapAreaPackage\", \"SMX\"],\n },\n },\n ],\n $storymap: [\n {\n type: \"StoryMap\",\n },\n {\n type: \"Web Mapping Application\",\n typekeywords: [\"Story Map\"],\n },\n ],\n $dashboard: [\n {\n type: \"Dashboard\",\n typekeywords: {\n any: [\"Dashboard\"],\n not: [\"ArcGIS Operation View\", \"Add In\", \"Extension\"],\n },\n },\n ],\n $dataset: [],\n $experience: [\n {\n type: {\n any: [\"Web Experience\"],\n not: [\"Web Experience Template\"],\n },\n },\n ],\n $site: [\n {\n type: [\"Hub Site Application\", \"Site Application\"],\n },\n {\n type: [\"Web Mapping Application\"],\n typekeywords: [\"hubSite\"],\n },\n ],\n $initiative: [\n {\n type: {\n any: \"Hub Initiative\",\n not: \"Hub Initiative Template\",\n },\n },\n ],\n $document: [\n {\n typekeywords: {\n any: \"Document\",\n not: [\"MapAreaPackage\", \"SMX\"],\n },\n type: {\n any: [\n \"Image\",\n \"Layout\",\n \"Desktop Style\",\n \"Project Template\",\n \"Report Template\",\n \"Pro Report\",\n \"Statistical Data Collection\",\n \"360 VR Experience\",\n \"netCDF\",\n \"PDF\",\n \"CSV\",\n \"Administrative Report\",\n \"Raster function template\",\n ],\n not: [\n \"Image Service\",\n \"Explorer Document\",\n \"Explorer Map\",\n \"Globe Document\",\n \"Scene Document\",\n \"Code Attachment\",\n \"Featured Items\",\n \"Symbol Set\",\n \"ColorSet\",\n \"Windows Viewer Add In\",\n \"Windows Viewer Configuration\",\n \"Map Area\",\n \"Indoors Map Configuration\",\n ],\n },\n },\n ],\n};\n/**\n * @private\n * Convert portal search response to items\n * @param response\n * @returns\n */\nexport function convertPortalResponseToFacets(response) {\n var _a;\n var result = [];\n if ((_a = response.aggregations) === null || _a === void 0 ? void 0 : _a.counts) {\n response.aggregations.counts.forEach(function (entry) {\n var facet = {\n label: entry.fieldName,\n attribute: entry.fieldName,\n type: \"multi-select\",\n };\n var options = [];\n entry.fieldValues.forEach(function (fv) {\n var filter = {\n filterType: \"content\",\n };\n filter[entry.fieldName] = fv.value;\n var fo = {\n label: fv.value,\n value: fv.value,\n count: fv.count,\n selected: false,\n filter: filter,\n };\n options.push(fo);\n });\n facet.options = options;\n result.push(facet);\n });\n }\n return result;\n}\n/**\n * Merge `Filter<\"content\">` objects\n *\n * Useful in components which may get partial filters from a variety of\n * sub-components, which are then combined into a single filter prior\n * to executing the search.\n * @param filters\n * @returns\n */\nexport function mergeContentFilter(filters) {\n // expand all the filters so all prop types are consistent\n var expanded = filters.map(expandContentFilter);\n // now we can merge based on fields\n var dateFields = [\"created\", \"modified\"];\n var specialFields = __spreadArrays([\"filterType\", \"subFilters\", \"term\"], dateFields);\n var result = expanded.reduce(function (acc, entry) {\n // process fields\n Object.entries(entry).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n if (acc.hasOwnProperty(key)) {\n /* istanbul ignore else */\n if (!specialFields.includes(key)) {\n acc[key] = mergeMatchOptions(acc[key], value);\n }\n else if (dateFields.includes(key)) {\n acc[key] = mergeDateRange(acc[key], value);\n }\n else if (key === \"term\") {\n acc[key] = acc[key] + \" \" + value;\n }\n else if (key === \"subFilters\") {\n acc[key] = mergeSubFilters(acc[key], value);\n }\n }\n else {\n acc[key] = cloneObject(value);\n }\n });\n return acc;\n }, {});\n result.filterType = \"content\";\n return result;\n}\nfunction mergeSubFilters(sf1, sf2) {\n // Simplistic implementation: we just merge the arrays\n // in the future we may try to de-dupe things as a safeguard\n return __spreadArrays(sf1, sf2);\n}\n/**\n * Prior to serialization into the query syntax for the backing APIs, we first expand [Filters](../Filter)\n *\n * Filter's can express their intent in a very terse form, but to ensure consistent structures\n * we expand them into their more verbose form.\n *\n * i.e. `title: \"Water\"` expands into `title: { any: [\"Water\"]}`\n *\n * - \"well known\" type values are expanded\n * - i.e. `type: \"$storymap\"` expands into two `subFilter` entries\n * - Fields defined as `string | string[] | MatchOptions` will be converted to a `MatchOptions`\n * - RelativeDate fields are converted to DateRange<number>\n *\n * @param filter\n * @returns\n */\nexport function expandContentFilter(filter) {\n // Expand filter.type first\n var expandedTypeFilter = expandTypeField(filter);\n // Expand subfilters\n // Guard - JS Clients could send in anything...\n if (Array.isArray(filter.subFilters)) {\n // Convert any strings into the coresponding ContentFilterDefinition\n expandedTypeFilter.subFilters = expandedTypeFilter.subFilters.reduce(function (acc, entry) {\n if (typeof entry === \"string\") {\n // if the entry is not a key of ContentFilterExpansions\n // we just skip over it\n if (ContentFilterExpansions[entry]) {\n acc = acc.concat(ContentFilterExpansions[entry]);\n }\n }\n else {\n acc.push(entry); // should be a ContentFilterDefinition\n }\n return acc;\n }, []);\n }\n // Convert all props into MatchOptions/DateRanges\n return convertContentDefinitionToFilter(expandedTypeFilter);\n}\n/**\n * @private\n * Expand from a well-known \"type\" into it's longer form\n *\n * i.e. `type: \"$storymap\"` expands into two subFilters entries\n *\n * @param filter\n * @returns\n */\nexport function expandTypeField(filter) {\n var clone = cloneObject(filter);\n // ensure subFilters is defined as an array\n clone.subFilters = clone.subFilters || [];\n if (clone.type) {\n // if .type is an Array...\n if (Array.isArray(clone.type)) {\n // remove any well-known-keys and move their expansions into subfilters\n clone.type = clone.type.reduce(function (acc, entry) {\n if (isWellKnownType(entry)) {\n // working with dynamic objects in typescript requires some assertions\n var key = entry;\n clone.subFilters = clone.subFilters.concat(lookupTypeFilters(key));\n }\n else {\n acc.push(entry);\n }\n return acc;\n }, []);\n }\n else if (isWellKnownType(clone.type)) {\n var key = clone.type;\n clone.subFilters = clone.subFilters.concat(lookupTypeFilters(key));\n delete clone.type;\n }\n else {\n // Future?: implement \"expansions\" inside MatchOptions\n // For now, we only attempt expansions for filter.type\n // if it's a string, or for strings inside an array\n // Unclear if it's of value to allow short-cuts inside MatchOptions\n }\n }\n return clone;\n}\n/**\n * Is the argument a well-known type \"key\"\n *\n * Accepts `string`, `string[]` or `IMatchOptions`\n * but only string values can possibly be properties\n * on `ContentFilterExpansions`\n * @param key\n * @returns\n */\nfunction isWellKnownType(key) {\n var result = false;\n if (typeof key === \"string\") {\n result = key in ContentFilterExpansions;\n }\n return result;\n}\nfunction lookupTypeFilters(key) {\n return ContentFilterExpansions[key];\n}\n/**\n * @private\n * Convert a `ContentFilterDefinition` to a `ContentFilter`\n *\n * ContentFilter is a narrower version of ContentFilterDefinition, without\n * the union types. Using a ContentFilter makes working with the structure\n * in typescript much easier.\n *\n * @param filter\n * @returns\n */\nexport function convertContentDefinitionToFilter(filter) {\n var result = {};\n if (filter.term) {\n result.term = filter.term;\n }\n var dateProps = [\"created\", \"modified\"];\n // Some properties should not get converted to MatchOptions\n var specialProps = __spreadArrays([\"filterType\", \"subFilters\", \"term\"], dateProps);\n // Do the conversion\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n if (!specialProps.includes(key)) {\n result[key] = valueToMatchOptions(value);\n }\n });\n // Special Cases\n // subFilters; Array of ContentFilterDefinitions\n if (filter.subFilters && Array.isArray(filter.subFilters)) {\n // downcast - would be nice to skip this or use some other constuct\n var sf = filter.subFilters;\n result.subFilters = sf.map(convertContentDefinitionToFilter);\n }\n // Dates; Ensure they are all DateRange<number>\n dateProps.forEach(function (fld) {\n if (filter[fld]) {\n if (filter[fld].type === \"relative-date\") {\n result[fld] = relativeDateToDateRange(filter[fld]);\n }\n else {\n result[fld] = cloneObject(filter[fld]);\n }\n }\n });\n return result;\n}\n/**\n * @private\n * Serialize a `ContentFilter` into an `ISearchOptions` for use with `searchItems`\n * @param filter\n * @returns\n */\nexport function serializeContentFilterForPortal(filter) {\n var searchOptions = convertContentFilterToSearchOptions(filter);\n if (filter.subFilters) {\n var subFilterOptions = filter.subFilters.reduce(function (acc, entry) {\n // Next guard is present b/c this can be used from javascript\n // but our tests are written in typescript which prevents us\n // from hitting the else\n /* istanbul ignore else */\n if (typeof entry === \"object\") {\n acc = mergeSearchOptions(acc, convertContentFilterToSearchOptions(entry), \"OR\");\n }\n return acc;\n }, { q: \"\", filter: \"\" });\n // merge with searchOptions using AND\n searchOptions = mergeSearchOptions(searchOptions, subFilterOptions, \"AND\");\n }\n // term is always last, and pre-pended on searchOptions.q\n if (filter.term) {\n searchOptions.q = (filter.term + \" \" + searchOptions.q).trim();\n }\n return searchOptions;\n}\n/**\n * @private\n * Convert a ContentFilter to a SearchOptions\n *\n * @param filter\n * @returns\n */\nexport function convertContentFilterToSearchOptions(filter) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n var dateProps = [\"created\", \"modified\"];\n var specialProps = __spreadArrays([\"filterType\", \"subFilters\", \"term\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // MatchOptions may go into either q or filter\n if (!specialProps.includes(key)) {\n result = mergeSearchOptions(result, serializeMatchOptions(key, value), \"AND\");\n }\n // Dates only go into q\n if (dateProps.includes(key)) {\n result = mergeSearchOptions(result, serializeDateRange(key, value), \"AND\");\n }\n });\n return result;\n}\n//# sourceMappingURL=content-utils.js.map","import { __spreadArrays } from \"tslib\";\nimport { mergeDateRange, mergeMatchOptions, mergeSearchOptions, relativeDateToDateRange, serializeDateRange, serializeMatchOptions, valueToMatchOptions, } from \".\";\nimport { cloneObject, getProp, setProp } from \"..\";\n/**\n *\n * Merge `Filter<\"group\">` objects\n *\n * Useful in components which may get partial filters from a variety of\n * sub-components, which are then combined into a single filter prior\n * to executing the search.\n * @param filters\n * @returns\n */\nexport function mergeGroupFilters(filters) {\n // expand all the filters so all prop types are consistent\n var expanded = filters.map(expandGroupFilter);\n // now we can merge based on fields\n var dateFields = [\"created\", \"modified\"];\n var specialFields = __spreadArrays([\"filterType\", \"term\"], dateFields);\n // acc is initialized as Filter<group> but also needs it\n // in the function signature... for reasons?!\n var result = expanded.reduce(function (acc, entry) {\n // process fields\n Object.entries(entry).forEach(function (_a) {\n // Note: getProp/setProp are used to get around\n // typescript issues with string indexing\n var key = _a[0], value = _a[1];\n if (acc.hasOwnProperty(key)) {\n var existingValue = getProp(acc, key);\n // if the key is not to a special field\n if (!specialFields.includes(key)) {\n // treat as an IMatchOptions\n setProp(key, mergeMatchOptions(existingValue, value), acc);\n }\n else if (dateFields.includes(key)) {\n // treat as IDateRange\n setProp(key, mergeDateRange(existingValue, value), acc);\n }\n else if (key === \"term\") {\n // append terms\n acc[key] = acc[key] + \" \" + value;\n }\n }\n else {\n // Acc does not have an entry for this yet\n // so just clone it\n setProp(key, cloneObject(value), acc);\n }\n });\n return acc;\n }, {\n filterType: \"group\",\n });\n return result;\n}\n/**\n * Prior to serialization into the query syntax for the backing APIs, we first expand [Filters](../Filter)\n *\n * Filter's can express their intent in a very terse form, but to ensure consistent structures\n * we expand them into their more verbose form.\n *\n * i.e. `title: \"Water\"` expands into `title: { any: [\"Water\"]}`\n *\n * - Fields defined as `string | string[] | MatchOptions` will be converted to a `MatchOptions`\n * - RelativeDate fields are converted to DateRange<number>\n *\n * @param filter\n * @returns\n */\nexport function expandGroupFilter(filter) {\n var result = {};\n var dateProps = [\"created\", \"modified\"];\n // Some properties should not get converted to MatchOptions\n var specialProps = __spreadArrays([\"term\", \"searchUserAccess\"], dateProps);\n // Do the conversion\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // handle Matchish fields\n if (!specialProps.includes(key)) {\n // setProp side-steps typescript complaining\n setProp(key, valueToMatchOptions(value), result);\n }\n // Handle date fields\n if (dateProps.includes(key)) {\n var dateFieldValue = cloneObject(getProp(filter, key));\n if (getProp(filter, key + \".type\") === \"relative-date\") {\n setProp(key, relativeDateToDateRange(dateFieldValue), result);\n }\n else {\n setProp(key, dateFieldValue, result);\n }\n }\n });\n // searchUserAccess is boolean, so we check if the prop exists\n // vs checking if the value is truthy\n if (filter.hasOwnProperty(\"searchUserAccess\")) {\n result.searchUserAccess = filter.searchUserAccess;\n }\n if (filter.term) {\n result.term = filter.term;\n }\n return result;\n}\n/**\n * @private\n * Serialize an `IGroupFilterDefinition` into an `ISearchOptions` for use\n * with `searchGroups`\n * @param filter\n * @returns\n */\nexport function serializeGroupFilterForPortal(filter) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n var dateProps = [\"created\", \"modified\"];\n var specialProps = __spreadArrays([\"term\", \"searchUserAccess\", \"filterType\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // MatchOptions fields\n if (!specialProps.includes(key)) {\n result = mergeSearchOptions(result, serializeMatchOptions(key, value), \"AND\");\n }\n // Dates only go into q\n if (dateProps.includes(key)) {\n result = mergeSearchOptions(result, serializeDateRange(key, value), \"AND\");\n }\n });\n // searchUserAccess is also a top-level property\n if (filter.hasOwnProperty(\"searchUserAccess\")) {\n result.searchUserAccess = filter.searchUserAccess;\n }\n // add the term\n if (filter.term) {\n result.q = (filter.term + \" \" + result.q).trim();\n }\n return result;\n}\n//# sourceMappingURL=group-utils.js.map","import { __spreadArrays } from \"tslib\";\nimport { cloneObject, getProp, mergeDateRange, mergeMatchOptions, mergeSearchOptions, relativeDateToDateRange, serializeDateRange, serializeMatchOptions, setProp, valueToMatchOptions, } from \"..\";\n/**\n *\n * Merge `Filter<\"user\">` objects\n *\n * Useful in components which may get partial filters from a variety of\n * sub-components, which are then combined into a single filter prior\n * to executing the search.\n * @param filters\n * @returns\n */\nexport function mergeUserFilters(filters) {\n // expand all the filters so all prop types are consistent\n var expanded = filters.map(expandUserFilter);\n // now we can merge based on fields\n var dateFields = [\"created\", \"modified\", \"lastlogin\"];\n var specialFields = __spreadArrays([\"disabled\", \"term\", \"filterType\"], dateFields);\n // acc is initialized as Filter<group> but also needs it\n // in the function signature... for reasons?!\n var result = expanded.reduce(function (acc, entry) {\n // process fields\n Object.entries(entry).forEach(function (_a) {\n // Note: getProp/setProp are used to get around\n // typescript issues with string indexing\n var key = _a[0], value = _a[1];\n if (acc.hasOwnProperty(key)) {\n var existingValue = getProp(acc, key);\n // if the key is not to a special field\n if (!specialFields.includes(key)) {\n // treat as an IMatchOptions\n setProp(key, mergeMatchOptions(existingValue, value), acc);\n }\n else if (dateFields.includes(key)) {\n // treat as IDateRange\n setProp(key, mergeDateRange(existingValue, value), acc);\n }\n else if (key === \"term\") {\n // append terms\n acc[key] = acc[key] + \" \" + value;\n }\n }\n else {\n // Acc does not have an entry for this yet\n // so just clone it\n setProp(key, cloneObject(value), acc);\n }\n });\n return acc;\n }, {\n filterType: \"user\",\n });\n return result;\n}\n/**\n * Prior to serialization into the query syntax for the backing APIs, we first expand [Filters](../Filter)\n *\n * Filter's can express their intent in a very terse form, but to ensure consistent structures\n * we expand them into their more verbose form.\n *\n * i.e. `firstname: \"John\"` expands into `firstname: { any: [\"John\"]}`\n *\n * - Fields defined as `string | string[] | MatchOptions` will be converted to a `MatchOptions`\n * - RelativeDate fields are converted to DateRange<number>\n * @param filter\n * @returns\n */\nexport function expandUserFilter(filter) {\n var result = {};\n var dateProps = [\"created\", \"modified\", \"lastlogin\"];\n var specialProps = __spreadArrays([\"disabled\", \"term\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // handle Matchish fields\n if (!specialProps.includes(key)) {\n // setProp side-steps typescript complaining\n setProp(key, valueToMatchOptions(value), result);\n }\n // Handle date fields\n if (dateProps.includes(key)) {\n var dateFieldValue = cloneObject(getProp(filter, key));\n if (getProp(filter, key + \".type\") === \"relative-date\") {\n setProp(key, relativeDateToDateRange(dateFieldValue), result);\n }\n else {\n setProp(key, dateFieldValue, result);\n }\n }\n });\n // disabled is boolean, so we check if the prop exists\n // vs checking if the value is truthy\n if (filter.hasOwnProperty(\"disabled\")) {\n result.disabled = filter.disabled;\n }\n if (filter.term) {\n result.term = filter.term;\n }\n return result;\n}\n/**\n * @private\n * Serialize an `IUserFilterDefinition` into an `ISearchOptions` for use\n * with `searchUsers`\n * @param filter\n * @returns\n */\nexport function serializeUserFilterForPortal(filter) {\n var result = {\n q: \"\",\n filter: \"\",\n };\n var dateProps = [\"created\", \"modified\", \"lastlogin\"];\n var specialProps = __spreadArrays([\"term\", \"filterType\"], dateProps);\n Object.entries(filter).forEach(function (_a) {\n var key = _a[0], value = _a[1];\n // MatchOptions fields\n if (!specialProps.includes(key)) {\n result = mergeSearchOptions(result, serializeMatchOptions(key, value), \"AND\");\n }\n // Dates only go into q\n if (dateProps.includes(key)) {\n result = mergeSearchOptions(result, serializeDateRange(key, value), \"AND\");\n }\n });\n // disabled is also a top-level property\n if (filter.hasOwnProperty(\"disabled\")) {\n result.disabled = filter.disabled;\n }\n // add the term\n if (filter.term) {\n // Note: this is slightly different from other types\n result.q = (\"(\" + filter.term + \") \" + result.q).trim();\n }\n return result;\n}\n//# sourceMappingURL=user-utils.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { expandContentFilter, serializeContentFilterForPortal, convertPortalResponseToFacets, } from \"./content-utils\";\nimport { searchItems } from \"@esri/arcgis-rest-portal\";\nimport { expandApi, getNextFunction } from \".\";\nimport { cloneObject, itemToContent, setContentSiteUrls, } from \"..\";\n/**\n * Search for content via the Portal or Hub API\n * @param filter\n * @param options\n */\nexport function _searchContent(filter, options) {\n var _a;\n return __awaiter(this, void 0, void 0, function () {\n var expanded, api, searchPromise, so;\n return __generator(this, function (_b) {\n expanded = expandContentFilter(filter);\n api = expandApi(options.api || \"arcgis\");\n // map over the apis, depending on the type we issue the queries\n // const searchPromises = apis.map((api) => {\n // Portal Search\n if (api.type === \"arcgis\") {\n so = serializeContentFilterForPortal(expanded);\n // pass auth forward\n if (options.authentication) {\n so.authentication = options.authentication;\n }\n else {\n so.portal = api.url + \"/sharing/rest\";\n }\n // Aggregations\n if ((_a = options.aggregations) === null || _a === void 0 ? void 0 : _a.length) {\n so.countFields = options.aggregations.join(\",\");\n so.countSize = 200;\n }\n // copy over various options\n // TODO: Dry this up - typscript makes this... inconvenient\n if (options.num) {\n so.num = options.num;\n }\n if (options.sortField) {\n so.sortField = options.sortField;\n }\n if (options.sortOrder) {\n so.sortOrder = options.sortOrder;\n }\n if (options.site) {\n so.site = cloneObject(options.site);\n }\n searchPromise = searchPortal(so);\n }\n else {\n // Hub API Search\n // TODO: Implement hub api content search\n searchPromise = Promise.resolve({\n total: 0,\n results: [],\n facets: [],\n hasNext: false,\n next: function () {\n Promise.resolve(null);\n },\n });\n }\n // });\n // return for results\n return [2 /*return*/, searchPromise];\n });\n });\n}\n/**\n * Internal portal search, which then converts items to Content, and\n * if a Site was passed, also sets urls\n *\n * @param searchOptions\n * @param site\n * @returns\n */\nfunction searchPortal(searchOptions) {\n return searchItems(searchOptions).then(function (resp) {\n var hasNext = resp.nextStart > -1;\n var content = resp.results.map(itemToContent);\n if (searchOptions.site) {\n content = content.map(function (entry) {\n return setContentSiteUrls(entry, searchOptions.site);\n });\n }\n // convert aggregations into facets\n var facets = convertPortalResponseToFacets(resp);\n return {\n total: resp.total,\n results: content,\n facets: facets,\n hasNext: hasNext,\n next: getNextFunction(searchOptions, resp.nextStart, resp.total, searchPortal),\n };\n });\n}\n//# sourceMappingURL=_searchContent.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { searchGroups as portalGroupSearch } from \"@esri/arcgis-rest-portal\";\nimport { expandApi, getNextFunction } from \".\";\nimport { expandGroupFilter, serializeGroupFilterForPortal, } from \"./group-utils\";\nimport { cloneObject, getGroupThumbnailUrl } from \"..\";\n/**\n * Search Groups using Filter<\"group\">\n *\n * Currently just returns ISearchResult<IGroup>\n * @param filter\n * @param options\n * @returns\n */\nexport function _searchGroups(filter, options) {\n var _a;\n return __awaiter(this, void 0, void 0, function () {\n var expanded, api, so, token, us, portalUrl;\n return __generator(this, function (_b) {\n expanded = expandGroupFilter(filter);\n api = expandApi(options.api || \"arcgis\");\n if (api.type === \"arcgis\") {\n so = serializeGroupFilterForPortal(expanded);\n token = \"\";\n // if we have auth, pass it forward\n // otherwise set the portal property\n if (options.authentication) {\n so.authentication = options.authentication;\n us = options.authentication;\n token = us.token;\n }\n else {\n so.portal = api.url + \"/sharing/rest\";\n }\n // TODO: Dry this up - typscript makes this... inconvenient\n if (options.num) {\n so.num = options.num;\n }\n if (options.sortField) {\n so.sortField = options.sortField;\n }\n if (options.sortOrder) {\n so.sortOrder = options.sortOrder;\n }\n portalUrl = api.url + \"/sharing/rest\";\n if ((_a = so.authentication) === null || _a === void 0 ? void 0 : _a.portal) {\n portalUrl = so.authentication.portal;\n }\n if (options.site) {\n so.site = cloneObject(options.site);\n }\n return [2 /*return*/, searchPortalGroups(so)];\n }\n else {\n throw new Error(\"_searchGroups is not implemented for non-arcgis apis\");\n }\n return [2 /*return*/];\n });\n });\n}\n/**\n * Internal function that searches for groups using the ArcGIS Portal API\n * @param searchOptions\n * @returns\n */\nfunction searchPortalGroups(searchOptions) {\n var _a;\n var teamLinkify = function (group) {\n group.siteTeamUrl = searchOptions.site.item.url + \"/teams/\" + group.id + \"/about\";\n return group;\n };\n var portalUrl = ((_a = searchOptions.authentication) === null || _a === void 0 ? void 0 : _a.portal) ||\n \"https://www.arcgis.com/sharing/rest\";\n var token;\n if (searchOptions.authentication) {\n var us = searchOptions.authentication;\n token = us.token;\n }\n var thumbnailify = function (group) {\n group.thumbnailUrl = getGroupThumbnailUrl(portalUrl, group, token);\n return group;\n };\n // execute the search\n return portalGroupSearch(searchOptions).then(function (response) {\n var _a, _b;\n var hasNext = response.nextStart > -1;\n // upgrade thumbnail url\n var results = response.results.map(thumbnailify);\n // generate the site team url if site url is provided\n if ((_b = (_a = searchOptions.site) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.url) {\n results = response.results.map(teamLinkify);\n }\n return {\n hasNext: hasNext,\n total: response.total,\n results: results,\n next: getNextFunction(searchOptions, response.nextStart, response.total, searchPortalGroups),\n };\n });\n}\n//# sourceMappingURL=_searchGroups.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { cloneObject, expandApi, expandUserFilter, getNextFunction, getUserThumbnailUrl, serializeUserFilterForPortal, } from \"..\";\nimport { searchUsers as portalUserSearch, } from \"@esri/arcgis-rest-portal\";\n/**\n * Search for Users via the Portal API.\n *\n * **Note** Authentication is required\n *\n * Note: in the future, there may be options to search via\n * a Hub specific API\n * @param filter\n * @param options\n * @returns\n */\nexport function _searchUsers(filter, options) {\n return __awaiter(this, void 0, void 0, function () {\n var expanded, api, searchOptions;\n return __generator(this, function (_a) {\n // JS Clients may not pass in authentication\n if (!options.authentication) {\n throw new Error(\"Authentication required to search for users.\");\n }\n expanded = expandUserFilter(filter);\n api = expandApi(options.api || \"arcgis\");\n if (api.type === \"arcgis\") {\n searchOptions = serializeUserFilterForPortal(expanded);\n // carry the auth forward\n searchOptions.authentication = options.authentication;\n // TODO: Dry this up - typscript makes this... inconvenient\n if (options.num) {\n searchOptions.num = options.num;\n }\n if (options.sortField) {\n searchOptions.sortField = options.sortField;\n }\n if (options.sortOrder) {\n searchOptions.sortOrder = options.sortOrder;\n }\n if (options.site) {\n searchOptions.site = cloneObject(options.site);\n }\n return [2 /*return*/, searchPortalUsers(searchOptions)];\n }\n else {\n throw new Error(\"_searchUsers is not implemented for non-arcgis apis\");\n }\n return [2 /*return*/];\n });\n });\n}\n/**\n * Internal function that executes the user search along with\n * some simple enrichments\n * @param searchOptions\n * @returns\n */\nfunction searchPortalUsers(searchOptions) {\n var portalUrl = searchOptions.authentication.portal;\n var token = searchOptions.authentication.token;\n // Partially applied functions for mapping over the results\n var userLinkify = function (user) {\n user.profileUrl = searchOptions.site.item.url + \"/people/\" + user.username + \"/profile\";\n return user;\n };\n var thumbnailify = function (user) {\n if (user.thumbnail) {\n user.thumbnailUrl = getUserThumbnailUrl(portalUrl, user, token);\n }\n return user;\n };\n return portalUserSearch(searchOptions).then(function (response) {\n var _a, _b;\n var hasNext = response.nextStart > -1;\n // upgrade thumbnail url\n var results = response.results.map(thumbnailify);\n // generate the site team url if site url is provided\n if ((_b = (_a = searchOptions.site) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.url) {\n results = response.results.map(userLinkify);\n }\n return {\n hasNext: hasNext,\n total: response.total,\n results: results,\n next: getNextFunction(searchOptions, response.nextStart, response.total, searchPortalUsers),\n };\n });\n}\n//# sourceMappingURL=_searchUsers.js.map","import { __awaiter, __generator } from \"tslib\";\n/**\n * Parse a response object, and throw if it contains an error.\n * Just a wrapper to hide some platform idiosyncracies\n * @param {Response} response Response object to parse\n * @private\n */\nexport function _checkStatusAndParseJson(response) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n if (response.status >= 200 && response.status < 300) {\n // don't try to parse the body if it's empty\n // if (response.body) { // the fetch polyfill for IE... does not expose a body property... :(\n return [2 /*return*/, response.json()];\n // }\n }\n else {\n // we're gonna throw, but we need to construct the error\n return [2 /*return*/, response.json().then(function (json) {\n if (json.error) {\n var error = new Error(json.error.title + \" :: \" + json.error.detail + \" :: \" + response.status);\n throw error;\n }\n else {\n throw new Error(\"Got \" + response.status + \" \" + response.statusText);\n }\n })];\n }\n return [2 /*return*/];\n });\n });\n}\n//# sourceMappingURL=_check-status-and-parse-json.js.map","import { getProp } from \"../../objects\";\n/**\n * Construct the auth header from a hub request options\n * @param {IHubRequestOptions} hubRequestOptions\n * @private\n */\nexport function _getAuthHeader(hubRequestOptions) {\n var result = {};\n var token = getProp(hubRequestOptions, \"authentication.token\");\n if (token) {\n result.Authorization = token;\n }\n return result;\n}\n//# sourceMappingURL=_get-auth-header.js.map","/**\n * Extract the domain service from the request options\n * @param {string} hubApiUrl\n * @private\n */\nexport function _getDomainServiceUrl(hubApiUrl) {\n var base = hubApiUrl || \"https://hub.arcgis.com\";\n return base + \"/api/v3/domains\";\n}\n//# sourceMappingURL=_get-domain-service-url.js.map","import { searchItems } from \"@esri/arcgis-rest-portal\";\nimport { includes } from \"../../utils\";\n/**\n * Lookup a domain in Portal\n * @param {string} hostname to locate the site for\n * @param {IRequestOptions} requestOptions\n * @private\n */\nexport function _lookupPortal(hostname, requestOptions) {\n // for portal we search for a site w/ `hubsubdomain|<domain>` type keyword\n var subdomain = hostname;\n // if this subdomain has a hash in it, knock that off\n if (hostname.indexOf(\"#/\") > -1) {\n subdomain = hostname.split(\"#/\")[1];\n }\n var queryTerm = \"hubsubdomain|\" + subdomain;\n var opts = Object.assign({\n q: \"typekeywords: \" + queryTerm,\n }, requestOptions);\n return searchItems(opts)\n .then(function (res) {\n // since the search api stems the terms, we need to verify\n // by looking at the results\n return res.results.filter(function (r) {\n return includes(r.typeKeywords, queryTerm);\n })[0];\n })\n .then(function (site) {\n if (!site)\n throw new Error(\"site not found\");\n return {\n hostname: site.url,\n siteId: site.id,\n };\n });\n}\n//# sourceMappingURL=_lookup-portal.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Create an entry in the domain system\n * @param {IHubDomain} domainEntry Domain hash to be stored\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function addDomain(domainEntry, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"addDomain is not available in ArcGIS Enterprise. Instead, edit the hubdomain typekeyword on the item\");\n }\n var headers = _getAuthHeader(hubRequestOptions);\n headers[\"Content-Type\"] = \"application/json\";\n var url = \"\" + _getDomainServiceUrl(hubRequestOptions.hubApiUrl);\n // handle case of siteTitle being numeric\n var title = domainEntry.siteTitle;\n if (typeof title === \"number\") {\n domainEntry.siteTitle = title.toString();\n }\n return fetch(url, {\n method: \"POST\",\n headers: headers,\n mode: \"cors\",\n body: JSON.stringify(domainEntry),\n }).then(_checkStatusAndParseJson);\n}\n//# sourceMappingURL=add-domain.js.map","import { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _getAuthHeader } from \"./_get-auth-header\";\nimport { stripProtocol } from \"../../urls\";\n/**\n * Check if a domain entry exists. Different from lookupDomain\n * in that this will return true/false, where as lookupDomain will\n * return the domain entry or throw. However, lookupDomain can work\n * with ArcGIS Enterprise.\n * Will throw if used in Portal.\n * @param {string} hostname Domain entry to check for\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function domainExists(hostname, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"domainExists is not available in ArcGIS Enterprise.\");\n }\n hostname = stripProtocol(hostname);\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + hostname;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" }).then(function (response) { return response.status !== 404; });\n}\n//# sourceMappingURL=domain-exists.js.map","import { _lookupPortal } from \"./_lookup-portal\";\n/**\n * Check if an item exists with the specified domain keyword\n * @param {String} hostname to check for\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function domainExistsPortal(hostname, hubRequestOptions) {\n return _lookupPortal(hostname, hubRequestOptions)\n .then(function (_) {\n return true;\n })\n .catch(function (_) {\n return false;\n });\n}\n//# sourceMappingURL=domain-exists-portal.js.map","import { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _getAuthHeader } from \"./_get-auth-header\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Get a list\n * @param {string} siteId Item id of the Site\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getDomainsForSite(siteId, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n return Promise.resolve([]);\n }\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"?siteId=\" + siteId;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" })\n .then(_checkStatusAndParseJson)\n .catch(function (err) {\n throw Error(\"Error in getDomainsForSite \" + err);\n });\n}\n//# sourceMappingURL=get-domains-for-site.js.map","import { domainExists } from \"./domain-exists\";\n/**\n * Ensure a unique domain name by checking for and incrementing\n * a subdomain\n * @param {String} subdomain Subdomain to ensure is unique\n * @param {String} baseHostname base hostname\n * @param hubRequestOptions\n * @param {Number} step Step number\n */\nexport function getUniqueDomainName(subdomain, baseHostname, hubRequestOptions, step) {\n if (step === void 0) { step = 0; }\n var combinedName = subdomain;\n if (step) {\n combinedName = subdomain + \"-\" + step;\n }\n var hostname = combinedName + \"-\" + baseHostname;\n return domainExists(hostname, hubRequestOptions).then(function (exists) {\n // if result === true, then we need to step the name...\n if (exists) {\n var nextStep = step + 1;\n return getUniqueDomainName(subdomain, baseHostname, hubRequestOptions, nextStep);\n }\n else {\n return combinedName;\n }\n });\n}\n//# sourceMappingURL=get-unique-domain-name.js.map","import { domainExistsPortal } from \"./domain-exists-portal\";\n/**\n * Ensure a unique domain name by checking for and incrementing\n * a subdomain\n * @param {String} subdomain Subdomain to ensure is unique\n * @param {IHubRequestOptions} hubRequestOptions\n * @param {*} step Step number\n */\nexport function getUniqueDomainNamePortal(subdomain, hubRequestOptions, step) {\n if (step === void 0) { step = 0; }\n var combinedName = subdomain;\n if (step) {\n combinedName = subdomain + \"-\" + step;\n }\n // now we search for existing items w/ this...\n return domainExistsPortal(combinedName, hubRequestOptions).then(function (exists) {\n if (exists) {\n var nextStep = step + 1;\n return getUniqueDomainNamePortal(subdomain, hubRequestOptions, nextStep);\n }\n else {\n return combinedName;\n }\n });\n}\n//# sourceMappingURL=get-unique-domain-name-portal.js.map","import { isGuid } from \"../../utils\";\n/**\n * Determine if a domain entry belongs to a legacy site.\n * This is used to allow customers to \"reclaim\" domains that\n * were associated with legacy sites which can no longer be\n * edited.\n * @param {IHubDomain} domainEntry Domain Info record\n */\nexport function isDomainForLegacySite(domainEntry) {\n return !isGuid(domainEntry.siteId);\n}\n//# sourceMappingURL=is-domain-for-legacy-site.js.map","import { _lookupPortal } from \"./_lookup-portal\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _getAuthHeader } from \"./_get-auth-header\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Fetch a the information about a domain.\n * Different implementation for Portal vs AGO\n * @param {string} hostname of domain record to locate\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function lookupDomain(hostname, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n return _lookupPortal(hostname, hubRequestOptions);\n }\n else {\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + hostname;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" }).then(_checkStatusAndParseJson);\n }\n}\n//# sourceMappingURL=lookup-domain.js.map","import { lookupDomain } from \"./lookup-domain\";\n/**\n * Check to see if a domain is in use by any site other than the\n * one passed in. This is used in various validators while the\n * user is editing properties of the site.\n * @param {string} hostname to check\n * @param {string} siteId Site Id we are checking for\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function isDomainUsedElsewhere(hostname, siteId, hubRequestOptions) {\n return lookupDomain(hostname, hubRequestOptions)\n .then(function (domainEntry) {\n return domainEntry.siteId !== siteId;\n })\n .catch(function () {\n // domain entry not found, ergo not used on another site\n return false;\n });\n}\n//# sourceMappingURL=is-domain-used-elsewhere.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \".\";\n/**\n * Validate a custom domain\n * @param {string} hostname to validate\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function isValidDomain(hostname, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"isValidDomain is not available in ArcGIS Enterprise.\");\n }\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/validate?hostname=\" + hostname;\n var headers = _getAuthHeader(hubRequestOptions);\n return fetch(url, { method: \"GET\", headers: headers, mode: \"cors\" })\n .then(function (response) {\n return response.json();\n })\n .catch(function (e) {\n return {\n success: false,\n input: hostname,\n error: {\n code: 400,\n detail: e,\n message: \"lookupFailed\",\n },\n };\n });\n}\n//# sourceMappingURL=is-valid-domain.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Remove a domain entry.\n * User must be a member of the org that owns the domain entry.\n * @param {int} domainId Id of the domain entry to remove\n * @param {IHubRequestOptions} hubRequestOptions`dom\n */\nexport function removeDomain(domainId, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"removeDomain is not available in ArcGIS Enterprise. Instead, edit the hubdomain typekeyword on the item\");\n }\n var headers = _getAuthHeader(hubRequestOptions);\n headers[\"Content-Type\"] = \"application/json\";\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + domainId;\n return fetch(url, { method: \"DELETE\", headers: headers, mode: \"cors\" }).then(_checkStatusAndParseJson);\n}\n//# sourceMappingURL=remove-domain.js.map","import { _getAuthHeader } from \"./_get-auth-header\";\nimport { _getDomainServiceUrl } from \"./_get-domain-service-url\";\nimport { _checkStatusAndParseJson } from \"./_check-status-and-parse-json\";\n/**\n * Update an entry in the domain system\n * @param {IHubDomain} domainEntry Doman object to be updated\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function updateDomain(domainEntry, hubRequestOptions) {\n if (hubRequestOptions.isPortal) {\n throw new Error(\"updateDomain is not available in ArcGIS Enterprise. Instead, edit the hubdomain typekeyword on the item\");\n }\n var headers = _getAuthHeader(hubRequestOptions);\n headers[\"Content-Type\"] = \"application/json\";\n var url = _getDomainServiceUrl(hubRequestOptions.hubApiUrl) + \"/\" + domainEntry.id;\n // handle case of siteTitle being numeric\n var title = domainEntry.siteTitle;\n if (typeof title === \"number\") {\n domainEntry.siteTitle = title.toString();\n }\n return fetch(url, {\n method: \"PUT\",\n headers: headers,\n mode: \"cors\",\n body: JSON.stringify(domainEntry),\n }).then(_checkStatusAndParseJson);\n}\n//# sourceMappingURL=update-domain.js.map","import { cloneObject } from \"../../util\";\nimport { generateRandomString } from \"../../utils\";\n/**\n * Ensure that a subdomain is not greater than 63 characters in length\n * Subdomains are prep-ended on the org's url key, and the combined\n * length can not exceed 63 chars as per rules of domains.\n * If the requested subdomain + the url key is > 63 chars, we\n * strip off the last 6 chars and replace that w/ random characeters\n * This was an actual reported bug.\n * @param {String} subdomain Proposed subdomain\n * @param {String} urlKey Org url key\n * @private\n */\nexport function _ensureSafeDomainLength(subdomain, urlKey) {\n var result = cloneObject(subdomain);\n var max = 63;\n if (urlKey)\n max = max - (urlKey.length + 1);\n if (result.length > max) {\n result = result.slice(0, max - 6) + \"-\" + generateRandomString(5);\n }\n return result;\n}\n//# sourceMappingURL=_ensure-safe-domain-length.js.map","import { getUniqueDomainNamePortal } from \"./get-unique-domain-name-portal\";\nimport { getUniqueDomainName } from \"./get-unique-domain-name\";\nimport { _ensureSafeDomainLength } from \"./_ensure-safe-domain-length\";\nimport { stripProtocol } from \"../../urls\";\nimport { getHubApiUrl } from \"../..\";\n/**\n * Given a subdomain, ensure that we have a unique hostname\n * incrementing if needed\n * @param {String} subdomain Subdomain to unique-ify\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function ensureUniqueDomainName(subdomain, hubRequestOptions) {\n var prms;\n if (hubRequestOptions.isPortal) {\n prms = getUniqueDomainNamePortal(subdomain, hubRequestOptions);\n }\n else {\n var baseDomain = hubRequestOptions.portalSelf.urlKey + \".\" + stripProtocol(getHubApiUrl(hubRequestOptions));\n prms = getUniqueDomainName(subdomain, baseDomain, hubRequestOptions);\n }\n return prms.then(function (uniqueDomain) {\n return _ensureSafeDomainLength(uniqueDomain, hubRequestOptions.portalSelf.urlKey);\n });\n}\n//# sourceMappingURL=ensure-unique-domain-name.js.map","import { upgradeSiteSchema } from \".\";\nimport { getModel } from \"..\";\n/**\n * Get a Site Model by it's Item Id, and apply schema upgrades\n * @param {String} id Site Item Id\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getSiteById(id, hubRequestOptions) {\n return getModel(id, hubRequestOptions).then(upgradeSiteSchema);\n}\n//# sourceMappingURL=get-site-by-id.js.map","import { mergeObjects } from \"../..\";\n/**\n * Builds a draft with a subset of the model properties\n * @param {*} model - item model\n * @param {*} includeList - list of property paths to include in draft object\n */\nexport function buildDraft(model, includeList) {\n return mergeObjects(model, {}, includeList);\n}\n//# sourceMappingURL=build-draft.js.map","import { getProp, cloneObject, deleteProp, setProp } from \"..\";\n/**\n * Add telemetry config object\n * @private\n * @param {object} model Site Model\n * @returns {object}\n */\nexport function _ensureTelemetry(model) {\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.4)\n return model;\n var clone = cloneObject(model);\n var gacode = getProp(clone, \"data.values.gacode\");\n clone.data.values.telemetry = {\n consentNotice: {\n isTheme: true,\n consentText: \"\",\n policyURL: \"\",\n },\n customAnalytics: {\n ga: {\n customerTracker: {\n enabled: Boolean(gacode),\n id: gacode,\n },\n },\n },\n };\n deleteProp(clone, \"data.values.gacode\");\n setProp(\"item.properties.schemaVersion\", 1.4, clone);\n return clone;\n}\n//# sourceMappingURL=_ensure-telemetry.js.map","export var SITE_SCHEMA_VERSION = 1.5;\n//# sourceMappingURL=site-schema-version.js.map","import { getProp } from \"../objects\";\nimport { cloneObject } from \"../util\";\n/**\n * Apply the first schema version to the item\n * @param {Object} model Site Model\n * @private\n */\nexport function _applySiteSchema(model) {\n // if this has already been thru this step... skip it...\n if (getProp(model, \"item.properties.schemaVersion\") >= 1)\n return model;\n var clone = cloneObject(model);\n // proactively purge old properties\n [\"groupId\", \"title\"].forEach(function (prop) {\n delete clone.data.values[prop];\n });\n // ensure item.properties\n if (!clone.item.properties) {\n clone.item.properties = {};\n }\n clone.item.properties.schemaVersion = 1;\n // Groups!\n if (clone.data.values.groups && Array.isArray(clone.data.values.groups)) {\n // we have some groups arrays in prod where the contents are a mix of strings and objects.\n // we need to ensure this is just an array of groupIds...\n var groupIds = clone.data.values.groups\n .map(function (entry) {\n if (typeof entry === \"object\") {\n return entry.id;\n }\n else {\n return entry;\n }\n })\n .filter(function (entry) { return !!entry; });\n // now assign this back to the groups\n clone.data.values.groups = groupIds;\n }\n return clone;\n}\n//# sourceMappingURL=_apply-site-schema.js.map","import { getProp, cloneObject } from \"..\";\n/**\n * Enforce lowercase domains\n * @param {Object} model Site Model\n * @private\n */\nexport function _enforceLowercaseDomains(model) {\n // exit if this has been applied...\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.1)\n return model;\n var clone = cloneObject(model);\n // all the possible domain properties must be lower case\n [\n \"subdomain\",\n \"defaultHostname\",\n \"internalUrl\",\n \"customHostname\",\n \"externalUrl\",\n ].forEach(function (prop) {\n if (clone.data.values[prop] &&\n typeof clone.data.values[prop] === \"string\") {\n clone.data.values[prop] = clone.data.values[prop].toLowerCase();\n }\n });\n // bump the schemaVersion\n clone.item.properties.schemaVersion = 1.1;\n return clone;\n}\n//# sourceMappingURL=_enforce-lowercase-domains.js.map","import { getProp, cloneObject } from \"..\";\n/**\n * Move the data.values.groups array into the\n * data.catalog object\n * @param {Object} model Site Model\n * @private\n */\nexport function _ensureCatalog(model) {\n // early exit\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.2)\n return model;\n var clone = cloneObject(model);\n var catalog = getProp(clone, \"data.catalog\") || {};\n if (getProp(clone, \"data.values.groups\")) {\n catalog.groups = cloneObject(clone.data.values.groups);\n delete clone.data.values.groups;\n }\n clone.data.catalog = catalog;\n // bump the schemaVersion\n clone.item.properties.schemaVersion = 1.2;\n return clone;\n}\n//# sourceMappingURL=_ensure-catalog.js.map","import { getProp, cloneObject, isGuid } from \"..\";\n/**\n * Remove any non-guid entries from the data catalog groups array\n * @param {object} model Site Model\n * @private\n */\nexport function _purgeNonGuidsFromCatalog(model) {\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.3)\n return model;\n var clone = cloneObject(model);\n var groups = getProp(clone, \"data.catalog.groups\") || [];\n clone.data.catalog.groups = groups.filter(isGuid);\n clone.item.properties.schemaVersion = 1.3;\n return clone;\n}\n//# sourceMappingURL=_purge-non-guids-from-catalog.js.map","import { cloneObject, getProp } from \"..\";\n/**\n * Migrates the site so it can store configurations for multiple feed formats\n * (dcat-us-1.1, dcat-ap-2.0.1, etc.). If the site has an existing custom\n * configuration for dcat-us 1.1, a copy of that configuration will be modified\n * to use values from the v3 api instead of values from the index.\n *\n * Structural Impacts:\n * - site.data.feeds will be added.\n * - site.data.feeds.dcatUS11 will be added if site.data.values.dcatConfig exists.\n *\n * @param {object} model Site Model\n * @private\n */\nexport function _migrateFeedConfig(model) {\n if (getProp(model, \"item.properties.schemaVersion\") >= 1.5)\n return model;\n var clone = cloneObject(model);\n var oldDcatUS11Config = clone.data.values.dcatConfig;\n clone.data.feeds = {};\n if (oldDcatUS11Config) {\n clone.data.feeds.dcatUS11 = _migrateToV3Values(oldDcatUS11Config);\n }\n clone.item.properties.schemaVersion = 1.5;\n return clone;\n}\nvar indexValueToV3Value = {\n // Defaults\n \"{{default.name}}\": \"{{name}}\",\n \"{{default.description}}\": \"{{description}}\",\n \"{{item.tags}}\": \"{{tags}}\",\n \"{{item.created:toISO}}\": \"{{created:toISO}}\",\n \"{{item.modified:toISO}}\": \"{{modified:toISO}}\",\n \"{{default.source.source}}\": \"{{source}}\",\n \"{{item.owner}}\": \"{{owner}}\",\n \"{{org.portalProperties.links.contactUs.url}}\": \"{{orgContactEmail}}\",\n // Custom Values\n \"{{org.name}}\": \"{{orgName}}\",\n \"{{item.categories}}\": \"{{categories}}\",\n \"{{item.licenseInfo}}\": \"{{licenseInfo}}\",\n \"{{item.modified}}\": \"{{modified}}\",\n \"{{enrichments.categories}}\": \"{{categories}}\",\n \"{{default.id}}\": \"{{id}}\",\n \"{{item.licenseInfo || No License}}\": \"{{licenseInfo || No License}}\",\n \"{{org.portalProperties.links.contactUs.url || mailto:data@tempe.gov}}\": \"{{orgContactEmail || mailto:data@tempe.gov}}\",\n \"{{default.description || No Description}}\": \"{{description || No Description}}\",\n \"{{item.id}}\": \"{{id}}\",\n};\nfunction _migrateToV3Values(originalConfig) {\n var migratedConfigString = JSON.stringify(originalConfig);\n var supportedIndexValues = Object.keys(indexValueToV3Value);\n supportedIndexValues.forEach(function (indexValue) {\n // Replace all occurrences of indexValue with the corresponding v3Value\n var v3Value = indexValueToV3Value[indexValue];\n migratedConfigString = migratedConfigString.split(indexValue).join(v3Value);\n });\n return JSON.parse(migratedConfigString);\n}\n//# sourceMappingURL=_migrate-feed-config.js.map","import { getProp } from \"../objects\";\nimport { SITE_SCHEMA_VERSION } from \"./site-schema-version\";\nimport { _applySiteSchema } from \"./_apply-site-schema\";\nimport { _enforceLowercaseDomains } from \"./_enforce-lowercase-domains\";\nimport { _ensureCatalog } from \"./_ensure-catalog\";\nimport { _purgeNonGuidsFromCatalog } from \"./_purge-non-guids-from-catalog\";\nimport { _ensureTelemetry } from \"./_ensure-telemetry\";\nimport { _migrateFeedConfig } from \"./_migrate-feed-config\";\n/**\n * Upgrades the schema upgrades\n * @param model IModel\n */\nexport function upgradeSiteSchema(model) {\n if (getProp(model, \"item.properties.schemaVersion\") === SITE_SCHEMA_VERSION) {\n return model;\n }\n else {\n // apply upgrade functions in order...\n model = _applySiteSchema(model);\n model = _enforceLowercaseDomains(model);\n model = _ensureCatalog(model);\n model = _purgeNonGuidsFromCatalog(model);\n model = _ensureTelemetry(model);\n model = _migrateFeedConfig(model);\n // WARNING - If you are writing a site schema migration,\n // you probably need to apply it to site drafts as well!\n // See https://github.com/Esri/hub.js/issues/498 for more details.\n return model;\n }\n}\n//# sourceMappingURL=upgrade-site-schema.js.map","import { stripProtocol } from \"../urls\";\nimport { isGuid } from \"../utils\";\nimport { lookupDomain } from \"./domains\";\nimport { getSiteById } from \"./get-site-by-id\";\n/**\n * Returns site model given various kinds of identifier\n *\n * @param identifier - a site item ID, site hostname, enterprise site slug, or full site URL\n * @param hubRequestOptions\n */\nexport function fetchSite(identifier, hubRequestOptions) {\n var prms;\n if (isGuid(identifier)) {\n prms = getSiteById(identifier, hubRequestOptions);\n }\n else {\n var hostnameOrSlug = identifier;\n // get down the the hostname\n hostnameOrSlug = stripProtocol(hostnameOrSlug);\n hostnameOrSlug = hostnameOrSlug.split(\"/\")[0];\n prms = lookupDomain(hostnameOrSlug, hubRequestOptions).then(function (_a) {\n var siteId = _a.siteId;\n return getSiteById(siteId, hubRequestOptions);\n });\n }\n return prms;\n}\nexport * from \"./domains\";\nexport * from \"./drafts\";\nexport * from \"./_ensure-telemetry\";\nexport * from \"./get-site-by-id\";\nexport * from \"./site-schema-version\";\nexport * from \"./upgrade-site-schema\";\n//# sourceMappingURL=index.js.map","/**\n * Locales supported by the hub\n */\nexport var HUB_LOCALES = [\n \"ar\",\n \"bs\",\n \"ca\",\n \"cs\",\n \"da\",\n \"de\",\n \"en\",\n \"es\",\n \"et\",\n \"el\",\n \"fi\",\n \"fr\",\n \"hr\",\n \"he\",\n \"hu\",\n \"it\",\n \"id\",\n \"ja\",\n \"ko\",\n \"lt\",\n \"lv\",\n \"nb\",\n \"nl\",\n \"pl\",\n \"pt\",\n \"pt-br\",\n \"pt-pt\",\n \"ro\",\n \"ru\",\n \"sl\",\n \"sr\",\n \"sv\",\n \"th\",\n \"tr\",\n \"uk\",\n \"vi\",\n \"zh\",\n \"zh-cn\",\n \"zh-tw\",\n \"zh-hk\"\n];\n//# sourceMappingURL=hub-locales.js.map","import { HUB_LOCALES } from \"./hub-locales\";\n/**\n * Convert a requested locale into a locale we support.\n * i.e. en-ca => en\n * If the requested locale is not available, en will be returned\n * @param {string} requestedLocale Locale we want\n */\nexport function convertToWellKnownLocale(requestedLocale) {\n if (requestedLocale === void 0) { requestedLocale = \"en\"; }\n var wellKnownKey = \"en\";\n // ensure downcase\n requestedLocale = requestedLocale.toLowerCase();\n // see if it's in the hub translations as-is\n if (HUB_LOCALES.indexOf(requestedLocale) > -1) {\n wellKnownKey = requestedLocale;\n }\n else {\n // if we split the requested locale, see if we have the root in the list\n var parts = requestedLocale.split(\"-\");\n if (parts.length > 1 && HUB_LOCALES.indexOf(parts[0]) > -1) {\n wellKnownKey = parts[0];\n }\n }\n return wellKnownKey;\n}\n//# sourceMappingURL=convert-to-well-known-locale.js.map","import { getHubLocaleAssetUrl } from \"../urls/get-hub-locale-asset-url\";\n/**\n * Fetch the Hub translation file for a given locale\n * These are all public urls and should never require auth/tokens etc\n * @param {String} locale Locale code - i.e. `es`\n * @param {Object} portal Portal Self\n */\nexport function fetchHubTranslation(locale, portal, mode) {\n if (mode === void 0) { mode = \"cors\"; }\n var assetBase = getHubLocaleAssetUrl(portal);\n var url = (assetBase + \"/locales/\" + locale + \".json\").toLocaleLowerCase();\n // to support web-tier auth, we must always send same-origin credentials\n var options = {\n method: \"GET\",\n credentials: \"same-origin\",\n mode: mode\n };\n return fetch(url, options)\n .then(function (response) { return response.json(); })\n .catch(function (err) {\n throw Error(\"Attempt to fetch locale \" + locale + \" from \" + url + \" failed: \" + JSON.stringify(err));\n });\n}\n//# sourceMappingURL=fetch-hub-translation.js.map","import { getProp } from \"../objects\";\n/**\n * Return the culture from the Hub Request Options\n * In priority order: user.culture, portal.culture, en-us\n * @param {IHubRequestOptions} hubRequestOptions\n */\nexport function getCulture(hubRequestOptions) {\n return (getProp(hubRequestOptions, \"portalSelf.user.culture\") ||\n getProp(hubRequestOptions, \"portalSelf.culture\") ||\n \"en-us\");\n}\n//# sourceMappingURL=get-culture.js.map","import { __assign, __extends } from \"tslib\";\nimport { getHubApiUrl } from \".\";\nimport { buildUrl } from \"./urls/build-url\";\n/**\n * remote server error\n */\nvar RemoteServerError = /** @class */ (function (_super) {\n __extends(RemoteServerError, _super);\n function RemoteServerError(message, url, status) {\n var _this = _super.call(this, message) || this;\n _this.status = status;\n _this.url = url;\n return _this;\n }\n return RemoteServerError;\n}(Error));\nexport { RemoteServerError };\n/**\n * ```js\n * import { hubApiRequest } from \"@esri/hub-common\";\n * //\n * hubApiRequest(\n * \"/datasets\",\n * requestOptions\n * })\n * .then(response);\n * ```\n * make a request to the Hub API\n * @param route API route\n * @param requestOptions request options\n */\nexport function hubApiRequest(route, requestOptions) {\n // merge in default request options\n var options = __assign({ \n // why do we default to GET w/ our API?\n httpMethod: \"GET\" }, requestOptions);\n // use fetch override if any\n var _fetch = options.fetch || fetch;\n // merge in default headers\n var headers = __assign({ \"Content-Type\": \"application/json\" }, options.headers);\n // build query params/body based on requestOptions.params\n var query;\n var body;\n if (options.httpMethod === \"GET\") {\n // pass params in query string\n query = options.params;\n }\n else {\n // pass params in request body\n body = JSON.stringify(options.params);\n }\n // build Hub API URL\n var url = buildUrl({\n host: getHubApiUrl(options),\n path: (\"/api/v3/\" + route).replace(/\\/\\//g, \"/\"),\n query: query,\n });\n return _fetch(url, {\n method: options.httpMethod,\n headers: headers,\n body: body,\n }).then(function (resp) {\n if (resp.ok) {\n return resp.json();\n }\n else {\n throw new RemoteServerError(resp.statusText, url, resp.status);\n }\n });\n}\n//# sourceMappingURL=request.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Gets the primary input Feature Service for the given\n * Form ID. This will be the Fieldworker view, if it exists,\n * otherwise the source Feature Service.\n * @param {string} formId The Form ID\n * @param requestOptions The request options\n * @returns {Promise<IModel>}\n */\nexport var getInputFeatureServiceModel = function (formId, requestOptions) {\n return getRelatedItems(__assign({ id: formId, relationshipType: \"Survey2Service\", direction: \"forward\" }, requestOptions)).then(function (_a) {\n var featureService = _a.relatedItems[0];\n var model;\n if (featureService) {\n model = { item: featureService };\n }\n return model;\n });\n};\n//# sourceMappingURL=get-input-feature-service-model.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Fetches a Survey's source Feature Service from a given\n * Fieldworker View ID\n * @param {string} fieldworkerId The Fieldworker View ID\n * @param {IRequestOptions} requestOptions The request options\n * @returns {Promise<IModel>}\n */\nexport var getSourceFeatureServiceModelFromFieldworker = function (fieldworkerId, requestOptions) {\n return getRelatedItems(__assign({ id: fieldworkerId, relationshipType: \"Service2Data\", direction: \"forward\" }, requestOptions)).then(function (_a) {\n var featureService = _a.relatedItems[0];\n var model;\n if (featureService) {\n model = { item: featureService };\n }\n return model;\n });\n};\n//# sourceMappingURL=get-source-feature-service-model-from-fieldworker.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __assign } from \"tslib\";\nimport { getRelatedItems } from \"@esri/arcgis-rest-portal\";\n/**\n * Fetches a Survey's Stakeholder View for a given\n * Form ID\n * @param {string} formId A Form ID\n * @param {IRequestOptions} requestOptions The request options\n * @returns {Promise<IModel>}\n */\nexport var getStakeholderModel = function (formId, requestOptions) {\n return getRelatedItems(__assign({ id: formId, relationshipType: \"Survey2Data\", direction: \"forward\" }, requestOptions)).then(function (_a) {\n var stakeholderView = _a.relatedItems[0];\n var model;\n if (stakeholderView) {\n model = { item: stakeholderView };\n }\n return model;\n });\n};\n//# sourceMappingURL=get-stakeholder-model.js.map","/**\n * Determines if the provided Feature Service item is a\n * Fieldworker View\n * @param {IItem} featureServiceItem\n * @returns {boolean}\n */\nexport function isFieldworkerView(featureServiceItem) {\n var hasTypekeyword = function (typeKeyword) {\n return featureServiceItem.typeKeywords.indexOf(typeKeyword) > -1;\n };\n // Survey123 only recently added the \"FieldworkerView\" typekeyword\n var isFieldworker = hasTypekeyword(\"FieldworkerView\");\n // we should support previously created fieldworkers too\n if (!isFieldworker) {\n var hasExpectedTypeKeywords = [\n \"Survey123\",\n \"Feature Service\",\n \"View Service\",\n ].every(hasTypekeyword);\n isFieldworker =\n hasExpectedTypeKeywords && !hasTypekeyword(\"StakeholderView\");\n }\n return isFieldworker;\n}\n//# sourceMappingURL=is-fieldworker-view.js.map","/* Copyright (c) 2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { getItem } from \"@esri/arcgis-rest-portal\";\nimport { getInputFeatureServiceModel } from \"./get-input-feature-service-model\";\nimport { getSourceFeatureServiceModelFromFieldworker } from \"./get-source-feature-service-model-from-fieldworker\";\nimport { getStakeholderModel } from \"./get-stakeholder-model\";\nimport { isFieldworkerView } from \"./is-fieldworker-view\";\n/**\n * Builds a dictionary of Survey items for the given Form model\n * @param {string} formId The Form ID of the survey\n * @param {IRequestOptions} requestOptions The request options\n * @returns {Promise<IGetSurveyModelsResponse>}\n */\nexport var getSurveyModels = function (formItemOrId, requestOptions) {\n var fieldworker;\n var stakeholder;\n var getForm = function () {\n return typeof formItemOrId === \"string\"\n ? getItem(formItemOrId, requestOptions)\n : Promise.resolve(formItemOrId);\n };\n return getForm().then(function (form) {\n var promises = [\n // the primary input will be the fieldworker (if it exists), otherwise\n // the source feature service.\n getInputFeatureServiceModel(form.id, requestOptions),\n getStakeholderModel(form.id, requestOptions),\n ];\n return Promise.all(promises)\n .then(function (_a) {\n var featureServiceOrFieldworkerModelResult = _a[0], stakeholderResult = _a[1];\n stakeholder = stakeholderResult;\n if (featureServiceOrFieldworkerModelResult &&\n isFieldworkerView(featureServiceOrFieldworkerModelResult.item)) {\n fieldworker = featureServiceOrFieldworkerModelResult;\n // if the primary input is the fieldworker, fetch\n // the source feature service\n return getSourceFeatureServiceModelFromFieldworker(fieldworker.item.id, requestOptions);\n }\n else {\n return featureServiceOrFieldworkerModelResult;\n }\n })\n .then(function (featureService) {\n return {\n form: { item: form },\n featureService: featureService,\n fieldworker: fieldworker,\n stakeholder: stakeholder,\n };\n });\n });\n};\n//# sourceMappingURL=get-survey-models.js.map","import { getProp, getWithDefault } from \".\";\n/**\n * Hash of Hub API end points so updates\n * are centralized\n */\nvar hubApiEndpoints = {\n domains: \"/api/v3/domains\",\n search: \"/api/v3/datasets\",\n discussions: \"/api/discussions/v1\",\n};\n/**\n * @internal\n * Thin class just used to enable getters\n *\n * This class should not be used by anything other than\n * the ArcGISContext class\n */\nvar ArcGISContextState = /** @class */ (function () {\n function ArcGISContextState(opts) {\n this._portalUrl = \"https://www.arcgis.com\";\n this.id = opts.id;\n this._portalUrl = opts.portalUrl;\n this._hubUrl = opts.hubUrl;\n if (opts.authentication) {\n this._authentication = opts.authentication;\n }\n if (opts.portalSelf) {\n this._portalSelf = opts.portalSelf;\n }\n if (opts.currentUser) {\n this._currentUser = opts.currentUser;\n }\n }\n Object.defineProperty(ArcGISContextState.prototype, \"session\", {\n /**\n * Return the UserSession if authenticated\n */\n get: function () {\n return this._authentication;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"isAuthenticated\", {\n /**\n * Return boolean indicating if authenticatio is present\n */\n get: function () {\n return !!this._authentication;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"userRequestOptions\", {\n /**\n * Return `IUserRequestOptions`, which is used for REST-JS\n * functions which require authentication information.\n *\n * If context is not authenticated, this function will throw\n */\n get: function () {\n if (this.isAuthenticated) {\n return {\n authentication: this._authentication,\n portal: this.sharingApiUrl,\n };\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"requestOptions\", {\n /**\n * Return `IRequestOptions`, which is used by REST-JS functions\n * which *may* use authentication information if provided.\n *\n * If context is not authenticated, this function just returns\n * the `portal` property, which informs REST-JS what Sharing API\n * instance to use (i.e. AGO, Enterprise etc)\n */\n get: function () {\n var ro = {\n portal: this.sharingApiUrl,\n };\n if (this.isAuthenticated) {\n ro = {\n authentication: this._authentication,\n portal: this.sharingApiUrl,\n };\n }\n return ro;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"hubRequestOptions\", {\n /**\n * Return a `IHubRequestOptions` object\n */\n get: function () {\n // We may add more logic around what is returned in some corner cases\n return {\n authentication: this.session,\n isPortal: this.isPortal,\n portalSelf: this.portal,\n hubApiUrl: this.hubUrl,\n };\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"portalUrl\", {\n // ==============================\n // Getters / Computed Properties\n // ==============================\n /**\n * Return the portal url.\n *\n * If authenticated @ ArcGIS Online, it will return\n * the https://org.env.arcgis.com\n *\n * If authenticated @ ArcGIS Enterprise, it will return\n * https://portalHostname, which includes the web adaptor\n */\n get: function () {\n if (this.isAuthenticated) {\n if (this.isPortal) {\n return \"https://\" + this._portalSelf.portalHostname;\n }\n else {\n return \"https://\" + this._portalSelf.urlKey + \".\" + this._portalSelf.customBaseUrl;\n }\n }\n else {\n return this._portalUrl;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"sharingApiUrl\", {\n /**\n * Returns the url to the sharing api\n * i.e. https://myorg.maps.arcgis.com/sharing/rest\n */\n get: function () {\n return this.portalUrl + \"/sharing/rest\";\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"hubUrl\", {\n get: function () {\n return this._hubUrl;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"isPortal\", {\n /**\n * Returns boolean indicating if the backing system\n * is ArcGIS Enterprise (formerly ArcGIS Portal) or not\n */\n get: function () {\n return this._portalSelf\n ? this._portalSelf.isPortal\n : this._portalUrl.indexOf(\"arcgis.com\") === -1;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"discussionsServiceUrl\", {\n // Hub APIs\n // ----------\n // Discussions\n get: function () {\n if (this._hubUrl) {\n return \"\" + this._hubUrl + hubApiEndpoints.discussions;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"hubSearchServiceUrl\", {\n // Hub Search\n get: function () {\n if (this._hubUrl) {\n return \"\" + this._hubUrl + hubApiEndpoints.search;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"domainServiceUrl\", {\n // Domain\n get: function () {\n if (this._hubUrl) {\n return \"\" + this._hubUrl + hubApiEndpoints.domains;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"eventsConfig\", {\n // Events\n // returns `{serviceId: '3ef..', publicViewId: 'bc3...'}\n get: function () {\n if (this._portalSelf) {\n return getProp(this._portalSelf, \"portalProperties.hub.settings.events\");\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"hubEnabled\", {\n /**\n * Returns boolean indicating if the current user\n * belongs to an organization that has licensed\n * ArcGIS Hub\n */\n get: function () {\n return getWithDefault(this._portalSelf, \"portalProperties.hub.enabled\", false);\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"communityOrgId\", {\n /**\n * Return Hub Community Org Id, if defined\n */\n get: function () {\n if (this._portalSelf) {\n return getProp(this._portalSelf, \"portalProperties.hub.settings.communityOrg.orgId\");\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"communityOrgHostname\", {\n get: function () {\n if (this._portalSelf) {\n return getProp(this._portalSelf, \"portalProperties.hub.settings.communityOrg.portalHostname\");\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"communityOrgUrl\", {\n get: function () {\n if (this.communityOrgHostname) {\n return \"https://\" + this.communityOrgHostname;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"helperServices\", {\n // Platform API service urls are all in helperServices\n // and not consistent to expose as urls\n get: function () {\n if (this._portalSelf) {\n return this._portalSelf.helperServices;\n }\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"currentUser\", {\n get: function () {\n return this._currentUser;\n },\n enumerable: false,\n configurable: true\n });\n Object.defineProperty(ArcGISContextState.prototype, \"portal\", {\n get: function () {\n return this._portalSelf;\n },\n enumerable: false,\n configurable: true\n });\n return ArcGISContextState;\n}());\nexport { ArcGISContextState };\n//# sourceMappingURL=ArcGISContextState.js.map","import { __awaiter, __generator } from \"tslib\";\nimport { getSelf, getUser } from \"@esri/arcgis-rest-portal\";\nimport { ArcGISContextState, } from \"./ArcGISContextState\";\nimport { cloneObject } from \".\";\n/**\n * Application Context Object\n *\n * Abstraction that combines a `UserSession` with\n * the `portal/self` and `user/self` responses to\n * provide a central lookup of platform information.\n *\n * This is a work-in-progress, and will likely expand over time.\n *\n * `ArcGISContext` is used in conjuction with the `arcgis-app-identity`\n * component to orchestrate oAuth.\n */\nvar ArcGISContext = /** @class */ (function () {\n /**\n * Private constructor. Use `ArcGISContext.create(...)` to\n * instantiate an instance\n * @param opts\n */\n function ArcGISContext(opts) {\n this._portalUrl = \"https://www.arcgis.com\";\n this._debug = false;\n // Having a unique id makes debugging easier\n this.id = new Date().getTime();\n if (opts.debug) {\n this._debug = opts.debug;\n }\n this.log(\"ArcGISContext:ctor: Creating \" + this.id);\n if (opts.authentication) {\n this._authentication = opts.authentication;\n this._portalUrl = this._authentication.portal.replace(\"/sharing/rest\", \"\");\n this._hubUrl = getHubApiFromPortalUrl(this._portalUrl);\n }\n else if (opts.portalUrl) {\n this._portalUrl = opts.portalUrl;\n this._hubUrl = getHubApiFromPortalUrl(this._portalUrl);\n }\n else {\n this._hubUrl = getHubApiFromPortalUrl(this._portalUrl);\n }\n if (opts.portal) {\n this._portalSelf = cloneObject(opts.portal);\n }\n if (opts.currentUser) {\n this._currentUser = cloneObject(opts.currentUser);\n }\n }\n /**\n * Static async Factory\n * @param opts\n * @returns\n */\n ArcGISContext.create = function (opts) {\n if (opts === void 0) { opts = {}; }\n return __awaiter(this, void 0, void 0, function () {\n var ctx;\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n ctx = new ArcGISContext(opts);\n return [4 /*yield*/, ctx.initialize()];\n case 1:\n _a.sent();\n return [2 /*return*/, ctx];\n }\n });\n });\n };\n /**\n * Set the Authentication (UserSession) for the context.\n * This should be called when a user signs into a running\n * application.\n * @param auth\n */\n ArcGISContext.prototype.setAuthentication = function (auth) {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n switch (_a.label) {\n case 0:\n this._authentication = auth;\n this._portalUrl = auth.portal.replace(\"/sharing/rest\", \"\");\n return [4 /*yield*/, this.initialize()];\n case 1:\n _a.sent();\n return [2 /*return*/];\n }\n });\n });\n };\n /**\n * Clear the Authentication (UserSession). This should be\n * called when a user signs out of an application, but\n * the application continues running\n */\n ArcGISContext.prototype.clearAuthentication = function () {\n // Reset the portalUrl from the org url to the base url\n // for ArcGIS Enterprise, we just leave the _portalUrl as-is\n if (!this._state.isPortal) {\n this._portalUrl = getPortalBaseFromOrgUrl(this._portalUrl);\n }\n // Clear the auth, portalSelf and currentUser props\n this._authentication = null;\n this._portalSelf = null;\n this._currentUser = null;\n this._state = new ArcGISContextState({\n id: this.id,\n portalUrl: this._portalUrl,\n hubUrl: this._hubUrl,\n });\n };\n Object.defineProperty(ArcGISContext.prototype, \"state\", {\n /**\n * Return a reference to the current state.\n * When `.setAuthentication()` or `.clearAuthenentication()` are\n * called, the state will be re-created. This is done so frameworks\n * like React or Ember can detect changes.\n */\n get: function () {\n return this._state;\n },\n enumerable: false,\n configurable: true\n });\n /**\n * @internal\n * Log debugging messages to the console\n * @param message\n */\n ArcGISContext.prototype.log = function (message) {\n if (this._debug) {\n // tslint:disable-next-line:no-console\n console.info(message);\n }\n };\n /**\n * If we have a UserSession, fetch portal/self and\n * store that along with current user\n */\n ArcGISContext.prototype.initialize = function () {\n return __awaiter(this, void 0, void 0, function () {\n var username, requests, _a, portal, user, ex_1, msg;\n return __generator(this, function (_b) {\n switch (_b.label) {\n case 0:\n if (!(this._authentication && (!this._portalSelf || !this._currentUser))) return [3 /*break*/, 4];\n this.log(\"ArcGISContext-\" + this.id + \": Initializing\");\n username = this._authentication.username;\n requests = [\n getSelf({ authentication: this._authentication }),\n getUser({ username: username, authentication: this._authentication }),\n ];\n _b.label = 1;\n case 1:\n _b.trys.push([1, 3, , 4]);\n return [4 /*yield*/, Promise.all(requests)];\n case 2:\n _a = _b.sent(), portal = _a[0], user = _a[1];\n this._portalSelf = portal;\n this._currentUser = user;\n return [3 /*break*/, 4];\n case 3:\n ex_1 = _b.sent();\n msg = \"ArcGISContext could not fetch portal & user for \\\"\" + this._authentication.username + \"\\\" using \" + this._authentication.portal + \".\";\n // tslint:disable-next-line:no-console\n console.error(msg);\n throw ex_1;\n case 4:\n // update the state\n this._state = new ArcGISContextState(this.stateOpts);\n return [2 /*return*/];\n }\n });\n });\n };\n Object.defineProperty(ArcGISContext.prototype, \"stateOpts\", {\n get: function () {\n var stateOpts = {\n id: this.id,\n portalUrl: this._portalUrl,\n hubUrl: this._hubUrl,\n };\n if (this._authentication) {\n stateOpts.authentication = this._authentication;\n }\n if (this._portalSelf) {\n stateOpts.portalSelf = this._portalSelf;\n }\n if (this._currentUser) {\n stateOpts.currentUser = this._currentUser;\n }\n return stateOpts;\n },\n enumerable: false,\n configurable: true\n });\n return ArcGISContext;\n}());\nexport { ArcGISContext };\n/**\n * Cross-walk from a portalUrl to the corresponding Hub.\n *\n * If the passed url is not recognized, then this will return `undefined`\n * @param portalUrl\n * @returns\n */\nfunction getHubApiFromPortalUrl(portalUrl) {\n var result;\n if (portalUrl.match(/(qaext|\\.mapsqa)\\.arcgis.com/)) {\n result = \"https://hubqa.arcgis.com\";\n }\n else if (portalUrl.match(/(devext|\\.mapsdevext)\\.arcgis.com/)) {\n result = \"https://hubdev.arcgis.com\";\n }\n else if (portalUrl.match(/(www|\\.maps)\\.arcgis.com/)) {\n result = \"https://hub.arcgis.com\";\n }\n return result;\n}\nfunction getPortalBaseFromOrgUrl(orgUrl) {\n var result;\n if (orgUrl.match(/(qaext|\\.mapsqa)\\.arcgis.com/)) {\n result = \"https://qaext.arcgis.com\";\n }\n else if (orgUrl.match(/(devext|\\.mapsdevext)\\.arcgis.com/)) {\n result = \"https://devext.arcgis.com\";\n }\n else {\n /* istanbul ignore else */\n if (orgUrl.match(/(www|\\.maps)\\.arcgis.com/)) {\n result = \"https://www.arcgis.com\";\n }\n }\n return result;\n}\n//# sourceMappingURL=ArcGISContext.js.map","/* Copyright (c) 2018-2020 Environmental Systems Research Institute, Inc.\n * Apache-2.0 */\nimport { __spreadArrays } from \"tslib\";\nimport { cloneObject, createId } from \"./util\";\nimport { getWithDefault } from \"./objects/get-with-default\";\n/**\n * Allows an application to track a series of operations, storing information\n * about the arguments passes in and the results returned\n *\n * ```js\n * import { OperationStack } from '@esri/solution-common';\n *\n * const stack = new OperationStack();\n *\n * // start an operation by type\n * const id = stack.start('getItem');\n * //.. work happens...\n * stack.finish(id);\n *\n * // start an operation with an Operation object\n * stack.start({\n * id: 'createItem_1',\n * type: 'createItem',\n * inputs: {\n * item: {...truncated...},\n * portal: 'https://www.arcgis.com',\n * username: 'jsmith'\n * },\n * });\n * // make the call\n * stack.finish('createItem_1', {newItemId: '00cf213'});\n *\n * // later you can get that information back out of the stack\n * const prevOp = stack.getOperation('createItem_1);\n *\n * // and if you need to roll back you can use the\n * // .cleanup and .output properties to help orchestrate\n *\n * ```\n *\n *\n * Can be used to implement \"atomic\" operations in an environment that does not\n * have this as a core feature\n */\nvar OperationStack = /** @class */ (function () {\n /**\n * Creates an instance of OperationStack.\n * @memberof OperationStack\n */\n function OperationStack() {\n this.operations = [];\n }\n /**\n * Start an Operation\n *\n * ```js\n * const stack = new OperationStack();\n * stack.startOperation({\n * id: 'get-bc3',\n * type: 'getItem',\n * cleanup: 'n/a',\n * inputs: {\n * id: 'bc3',\n * owner: 'vader'\n * }\n * });\n * // do work\n * stack.finish('get-bc3');\n * ```\n *\n *\n * @param {IOperation} operation\n * @memberof OperationStack\n */\n OperationStack.prototype.startOperation = function (operation) {\n var op = cloneObject(operation);\n op.startedAt = new Date().getTime();\n op.state = \"working\";\n this.operations.push(op);\n };\n /**\n * Start an operation without requiring a full operation\n *\n * ```js\n * const opId = stack.start('getItems');\n * //...work happens\n * stack.finish(opId);\n * ```\n *\n * @param {string} type Type of the operation. i.e. getItem\n * @param {Record<string, unknown>} [params] optionally pass in id, inputs, cleanup\n * @returns {string} Identifier of the new stack entry\n * @memberof OperationStack\n */\n OperationStack.prototype.start = function (type, params) {\n var op = {\n type: type,\n id: getWithDefault(params, \"id\", createId(type + \"_\")),\n inputs: getWithDefault(params, \"inputs\", {}),\n cleanup: getWithDefault(params, \"cleanup\", \"n/a\"),\n startedAt: new Date().getTime(),\n state: \"working\"\n };\n this.operations.push(op);\n return op.id;\n };\n /**\n * Returns a reference to an Operation\n *\n * @param {string} id Unique Identifier\n * @returns {Operation}\n * @memberof OperationStack\n */\n OperationStack.prototype.getOperation = function (id) {\n return this.operations.find(function (o) { return o.id === id; });\n };\n /**\n * Returns reference to the operations array\n *\n * @returns {Operation[]}\n * @memberof OperationStack\n */\n OperationStack.prototype.getOperations = function () {\n return this.operations;\n };\n /**\n * Inform the stack that an operation has finished.\n *\n * This will append in a duration property, and mark\n * the state as 'completed'.\n *\n * @param {string} id Unique identifier of the Operation\n * @param {Record<string, unknown>} [options] outputs\n * @memberof OperationStack\n */\n OperationStack.prototype.finish = function (id, options) {\n var op = this.getOperation(id);\n if (op) {\n op.duration = new Date().getTime() - op.startedAt;\n op.state = \"completed\";\n if (options) {\n op.output = cloneObject(options);\n }\n }\n else {\n throw new Error(\"No operation with id \" + id + \" present in stack\");\n }\n };\n /**\n * Merge a serialized operation stack into\n * a stack instance\n *\n * ```js\n * import { OperationStack } from '@esri/solution-common';\n * function someFunction() {\n * const stack = new OperationStack();\n * stack.start('getItem', {id: 'get-bc3'});\n * // do some work...\n * stack.finish('get-bc3');\n *\n * const itm = {title: 'Fake Item', type: 'Web Map'};\n * // create an entry for the function we are about to call...\n * stack.start('createItem', {id: 'createItem_01', inputs: {item: itm}});\n * // call a function that does work, and has it's own stack\n * // and returns a serialized version as part of it's results\n * return createItem(itm)\n * .then((result) => {\n * // tell the stack the last operation finished...\n * stack.finish('createItem_01');\n * // merge in the stack from the function we called\n * stack.merge(result.stack);\n * // > stack.getCompleted().length === 3\n * });\n * }\n *\n * function createItem (itm) {\n * const otherStack = new OperationStack();\n * const id = otherStack.start('createItem');\n * // make calls to create item etc\n * otherStack.finish(id, {itemId: newItem.id});\n * otherStack.start('protectItem', {id: 'protect-00c'});\n * // make call to protect item...\n * otherStack.finish('protect-00c');\n * // all done... return a result with a stack\n * return Promise.resolve({\n * success:true,\n * stack: otherStack.serialize()\n * });\n * }\n * ```\n *\n * Typically used to create a comprehensive list of operations\n * when a function returns a `SerializedOperationStack` as part of\n * it's response\n *\n *\n * @param {ISerializedOperationStack} stack\n * @memberof OperationStack\n */\n OperationStack.prototype.merge = function (stack) {\n this.operations = __spreadArrays(this.operations, stack.operations);\n };\n /**\n * Get a list of the completed operations\n *\n * @returns {IOperation[]}\n * @memberof OperationStack\n */\n OperationStack.prototype.getCompleted = function () {\n return cloneObject(this.operations.filter(function (e) { return e.state === \"completed\"; }));\n };\n /**\n * Return an array of working operations\n *\n * @returns {IOperation[]}\n * @memberof OperationStack\n */\n OperationStack.prototype.getWorking = function () {\n return cloneObject(this.operations.filter(function (e) { return e.state === \"working\"; }));\n };\n /**\n * Serialize the completed operations into a set of\n * human readable messages, sorted by the startedAt timestamp\n *\n *\n * @returns {string}\n * @memberof IOperationStack\n */\n OperationStack.prototype.toString = function () {\n // sort the operations by StartedAt\n var allOps = this.operations.sort(function (a, b) {\n if (a.startedAt < b.startedAt) {\n return -1;\n }\n if (b.startedAt < a.startedAt) {\n return 1;\n }\n return 0;\n });\n return allOps.map(getOperationMessage).join(\"\\n\");\n };\n /**\n * Serialize the stack into simple objects\n *\n * @returns {ISerializedOperationStack}\n * @memberof OperationStack\n */\n OperationStack.prototype.serialize = function () {\n return {\n operations: cloneObject(this.getOperations())\n };\n };\n return OperationStack;\n}());\nexport default OperationStack;\nfunction getOperationMessage(op) {\n var msg = op.startedAt + \" : Operation \" + op.id + \" started with inputs \" + JSON.stringify(op.inputs) + \" but was not completed\";\n if (op.state === \"completed\") {\n msg = op.startedAt + \" : Operation \" + op.id + \" took \" + op.duration + \" ms with inputs \" + JSON.stringify(op.inputs) + \" and output \" + (op.output ? JSON.stringify(op.output) : \"n/a\");\n }\n return msg;\n}\n//# sourceMappingURL=OperationStack.js.map"],"names":["cloneObject","getWithDefault","Level","getPortalUrl","_sendSafeRequest","_generateRequestOptions","_generateBatchRequests","_combineResults","getPortalApiUrl","app","dataset","document","event","feedback","initiative","map","other","site","allCategories","keystr","atob","btoa","portalGroupSearch","portalUserSearch"],"mappings":";;;;;;;;;;;;IAAA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,UAAU,CAAC,GAAG,EAAE,EAAE,EAAE;IACpC,IAAI,IAAI,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IAChC,IAAI,IAAI,SAAS,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU,GAAG,EAAE,UAAU,EAAE;IAC3D,QAAQ,GAAG,CAAC,UAAU,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,UAAU,EAAE,GAAG,CAAC,CAAC;IAC/D,QAAQ,OAAO,GAAG,CAAC;IACnB,KAAK,EAAE,EAAE,CAAC,CAAC;IACX,IAAI,OAAO,SAAS,CAAC;IACrB;;ICZA;IACA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,cAAc,CAAC,MAAM,EAAE,QAAQ,EAAE,YAAY,EAAE;IAC/D,IAAI,YAAY,GAAG,YAAY,IAAI,EAAE,CAAC;IACtC,IAAI,IAAI,KAAK,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE;IAC/B,QAAQ,OAAO,MAAM,CAAC,GAAG,CAAC,qBAAqB,CAAC,CAAC;IACjD,KAAK;IACL,SAAS,IAAI,MAAM;IACnB,QAAQ,SAAS,CAAC,MAAM,CAAC;IACzB,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC;IACxB,QAAQ,CAAC,SAAS,CAAC,MAAM,CAAC;IAC1B,QAAQ,CAAC,WAAW,CAAC,MAAM,CAAC,EAAE;IAC9B,QAAQ,OAAO,MAAM,CAAC,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,UAAU,CAAC,MAAM,EAAE,qBAAqB,CAAC,CAAC,CAAC;IACpF,KAAK;IACL,SAAS;IACT,QAAQ,OAAO,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;IAC9C,KAAK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ACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,QAAQ,CAAC,GAAG,EAAE,GAAG,EAAE,MAAM,EAAE;IAC3C;IACA,IAAI,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,KAAK,SAAS,EAAE;IAC3C,QAAQ,MAAM,GAAGA,aAAW,CAAC,MAAM,CAAC,CAAC;IACrC;IACA,QAAQ,MAAM,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC;IAC1B,KAAK;IACL,IAAI,OAAO,MAAM,CAAC;IAClB,CAAC;IACD;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,SAAS,CAAC,GAAG,EAAE,MAAM,EAAE;IACvC,IAAI,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,KAAK,SAAS,EAAE;IAC3C;IACA,QAAQ,MAAM,GAAGA,aAAW,CAAC,MAAM,CAAC,CAAC;IACrC,QAAQ,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;IACzB,KAAK;IACL,IAAI,OAAO,MAAM,CAAC;IAClB,CAAC;IACD;IACA;IACA;IACA;IACA;IACA;IACA;IACO,SAAS,QAAQ,CAAC,KAAK,EAAE;IAChC;IACA,IAAI,KAAK,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC;IAChC;IACA,IAAI,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,6CAA6C,EAAE,GAAG,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