@esri/solution-viewer 5.2.1 → 5.2.3

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.
package/README.md CHANGED
@@ -1,16 +1,13 @@
1
1
  [![npm status][npm-img]][npm-url]
2
2
  [![Build status][travis-img]][travis-url]
3
3
  [![gzip bundle size][gzip-img]][npm-url]
4
- [![Coverage status][coverage-img]][coverage-url]
5
4
  [![Apache 2.0 licensed][license-img]][license-url]
6
5
 
7
6
  [npm-img]: https://img.shields.io/npm/v/@esri/solution-viewer.svg?style=round-square&color=blue
8
7
  [npm-url]: https://www.npmjs.com/package/@esri/solution-viewer
9
- [travis-img]: https://img.shields.io/travis/Esri/solution.js/develop.svg
8
+ [travis-img]: https://img.shields.io/travis/com/Esri/solution.js/develop.svg
10
9
  [travis-url]: https://travis-ci.org/Esri/solution.js
11
- [gzip-img]: https://img.badgesize.io/https://unpkg.com/@esri/solution-viewer/dist/umd/viewer.umd.min.js?compression=gzip
12
- [coverage-img]: https://coveralls.io/repos/github/Esri/solution.js/badge.svg
13
- [coverage-url]: https://coveralls.io/github/Esri/solution.js
10
+ [gzip-img]: https://img.badgesize.io/https://unpkg.com/@esri/solution-viewer/dist/esm/index.js?compression=gzip
14
11
  [license-img]: https://img.shields.io/badge/license-Apache%202.0-blue.svg
15
12
  [license-url]: #license
16
13
 
@@ -18,7 +15,7 @@
18
15
 
19
16
  > Simplifies access to [`@esri/solution-*`](https://github.com/Esri/solution.js).
20
17
 
21
- ### [API Reference](https://esri.github.io/solution.js/api/viewer/)
18
+ ### [API Reference](https://esri.github.io/solution.js/modules/viewer_src.html)
22
19
 
23
20
  ### Issues
24
21
 
@@ -36,7 +33,7 @@ Esri welcomes contributions from anyone and everyone. Please see our [guidelines
36
33
 
37
34
  ### License
38
35
 
39
- Copyright © 2018-2020 Esri
36
+ Copyright © 2018 Esri
40
37
 
41
38
  Licensed under the Apache License, Version 2.0 (the "License");
42
39
  you may not use this file except in compliance with the License.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@esri/solution-viewer",
3
- "version": "5.2.1",
3
+ "version": "5.2.3",
4
4
  "description": "Simplifies access to @esri/solution.js.",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -23,11 +23,11 @@
23
23
  "@esri/arcgis-rest-portal": "^3.7.0",
24
24
  "@esri/arcgis-rest-request": "^3.7.0",
25
25
  "@esri/arcgis-rest-service-admin": "^3.7.0",
26
- "@esri/hub-common": "^14.74.1",
26
+ "@esri/hub-common": "^14.97.0",
27
27
  "@esri/hub-initiatives": "^14.0.0",
28
28
  "@esri/hub-sites": "^14.2.2",
29
29
  "@esri/hub-teams": "^14.1.0",
30
- "@esri/solution-common": "^5.2.1",
30
+ "@esri/solution-common": "^5.2.3",
31
31
  "@types/jasmine": "^5.1.4",
32
32
  "fetch-mock": "^7.7.3",
33
33
  "jasmine": "^5.1.0",
@@ -88,5 +88,5 @@
88
88
  "esri",
89
89
  "ES6"
90
90
  ],
91
- "gitHead": "0f2bb444de46482baa42621310bc4e8d94bcd11a"
91
+ "gitHead": "bcf0907f47cf8a2970f8da38f8e1e2a4ac7beccb"
92
92
  }
@@ -1,21 +0,0 @@
1
- /** @license
2
- * Copyright 2018 Esri
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- /**
17
- * Provides the access to the solution's contents.
18
- *
19
- * @module viewer
20
- */
21
- export * from "./viewer";
package/dist/cjs/index.js DELETED
@@ -1,25 +0,0 @@
1
- "use strict";
2
- /** @license
3
- * Copyright 2018 Esri
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- const tslib_1 = require("tslib");
19
- /**
20
- * Provides the access to the solution's contents.
21
- *
22
- * @module viewer
23
- */
24
- tslib_1.__exportStar(require("./viewer"), exports);
25
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAEH;;;;GAIG;AAEH,mDAAyB"}
@@ -1,54 +0,0 @@
1
- /** @license
2
- * Copyright 2018 Esri
3
- *
4
- * Licensed under the Apache License, Version 2.0 (the "License");
5
- * you may not use this file except in compliance with the License.
6
- * You may obtain a copy of the License at
7
- *
8
- * http://www.apache.org/licenses/LICENSE-2.0
9
- *
10
- * Unless required by applicable law or agreed to in writing, software
11
- * distributed under the License is distributed on an "AS IS" BASIS,
12
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
- * See the License for the specific language governing permissions and
14
- * limitations under the License.
15
- */
16
- /**
17
- * Provides the access to the solution's contents.
18
- *
19
- * @module viewer
20
- */
21
- import * as common from "@esri/solution-common";
22
- /**
23
- * Checks a Solution.
24
- *
25
- * @param item Solution id
26
- * @param authentication Credentials for the request to AGO
27
- * @returns List of results of checks of Solution
28
- */
29
- export declare function checkSolution(itemId: string, authentication?: common.UserSession): Promise<string[]>;
30
- /**
31
- * Compares two AGO items, fetching them if only their id is supplied.
32
- *
33
- * @param item1 First item or its AGO id
34
- * @param item2 Second item or its AGO id
35
- * @param authentication Credentials for the request to AGO
36
- * @returns True if objects are the same
37
- * @see Only comparable properties are compared; see deleteItemProps() in the `common` package
38
- */
39
- export declare function compareItems(item1: any, item2: any, authentication?: common.UserSession): Promise<boolean>;
40
- /**
41
- * Creates a hierarchy of the items in a Solution template.
42
- *
43
- * @param templates Array of templates from a Solution
44
- * @returns List of top-level items, each containing a recursive list of its dependencies
45
- */
46
- export declare function getItemHierarchy(templates: common.IItemTemplate[]): common.IHierarchyElement[];
47
- /**
48
- * Finds the top-level items in a Solution template--the items that are not dependencies of any other item.
49
- *
50
- * @param templates Array of templates from a Solution
51
- * @returns List of top-level item ids
52
- * @private
53
- */
54
- export declare function _getTopLevelItemIds(templates: common.IItemTemplate[]): string[];
@@ -1,262 +0,0 @@
1
- "use strict";
2
- /** @license
3
- * Copyright 2018 Esri
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- Object.defineProperty(exports, "__esModule", { value: true });
18
- exports._getTopLevelItemIds = exports.getItemHierarchy = exports.compareItems = exports.checkSolution = void 0;
19
- const tslib_1 = require("tslib");
20
- /**
21
- * Provides the access to the solution's contents.
22
- *
23
- * @module viewer
24
- */
25
- const common = tslib_1.__importStar(require("@esri/solution-common"));
26
- // ------------------------------------------------------------------------------------------------------------------ //
27
- /**
28
- * Checks a Solution.
29
- *
30
- * @param item Solution id
31
- * @param authentication Credentials for the request to AGO
32
- * @returns List of results of checks of Solution
33
- */
34
- function checkSolution(itemId, authentication = null) {
35
- const resultsHtml = [`Item ${itemId}`];
36
- let item;
37
- let isTemplate = true;
38
- let templateItems;
39
- let templateItemIds;
40
- let currentAction = " while getting complete item";
41
- return (common
42
- .getCompleteItem(itemId, authentication)
43
- // ---------- Is it a Template or Deployed Solution? -----------------------------------------------------------//
44
- .then((results) => {
45
- currentAction = "";
46
- item = results;
47
- if (!item) {
48
- throw new Error(`item is not found`);
49
- }
50
- else if (item.base.type !== "Solution") {
51
- throw new Error(`item is not a Solution`);
52
- }
53
- else if (item.base.typeKeywords.includes("Template")) {
54
- resultsHtml.push(`&#x2714; item is a Template Solution`);
55
- }
56
- else if (item.base.typeKeywords.includes("Deployed")) {
57
- isTemplate = false;
58
- resultsHtml.push(`&#x2714; item is a Deployed Solution`);
59
- }
60
- else {
61
- throw new Error(`item is neither a Template Solution nor a Deployed Solution`);
62
- }
63
- // base: IItem; text/plain JSON
64
- // data: File; */*
65
- // thumbnail: File; image/*
66
- // metadata: File; application/xml
67
- // resources: File[]; list of */*
68
- // fwdRelatedItems: IRelatedItems[]; list of forward relationshipType/relatedItems[] pairs
69
- // revRelatedItems: IRelatedItems[]; list of reverse relationshipType/relatedItems[] pairs
70
- return common.blobToJson(item.data);
71
- })
72
- // ---------- Check the Solution2Item relationship from a Deployed Solution to each deployed item --------------//
73
- .then(itemDataJson => {
74
- templateItems = itemDataJson?.templates;
75
- /* istanbul ignore else */
76
- if (!templateItems || templateItems.length === 0) {
77
- throw new Error(`Solution's data are not valid JSON or the Solution contains no items`);
78
- }
79
- templateItemIds = templateItems
80
- .map((template) => template.itemId)
81
- .sort();
82
- if (!isTemplate) {
83
- // Make sure that there's a Solution2Item relationship to each deployed item
84
- const fwdRelatedItemIds = item.fwdRelatedItems
85
- .filter(relationshipSet => relationshipSet.relationshipType === "Solution2Item")
86
- .reduce((flatSet, relationshipSet) => flatSet.concat(relationshipSet.relatedItemIds), [])
87
- .sort();
88
- if (templateItemIds.length < fwdRelatedItemIds.length) {
89
- resultsHtml.push("&#x2716; there are forward Solution2Item relationship(s) to unknown item(s)");
90
- }
91
- else if (templateItemIds.length > fwdRelatedItemIds.length) {
92
- resultsHtml.push("&#x2716; missing forward Solution2Item relationship(s)");
93
- }
94
- else if (JSON.stringify(templateItemIds) !==
95
- JSON.stringify(fwdRelatedItemIds)) {
96
- resultsHtml.push("&#x2716; mismatching forward Solution2Item relationship(s)");
97
- }
98
- else {
99
- resultsHtml.push("&#x2714; matching forward Solution2Item relationship(s)");
100
- }
101
- }
102
- return resultsHtml;
103
- })
104
- // ---------- Check that all dependency references are items in Solution ---------------------------------------//
105
- .then(() => {
106
- const dependencyIds = templateItems
107
- .reduce((flatSet, template) => flatSet.concat(template.dependencies), [])
108
- .reduce((noDupSet, dependency) => {
109
- /* istanbul ignore else */
110
- if (!noDupSet.includes(dependency))
111
- noDupSet.push(dependency);
112
- return noDupSet;
113
- }, [])
114
- .sort();
115
- const missingItems = dependencyIds.filter((dependencyId) => !templateItemIds.includes(dependencyId));
116
- if (missingItems.length === 0) {
117
- resultsHtml.push("&#x2714; all dependencies are in Solution");
118
- }
119
- else {
120
- resultsHtml.push("&#x2716; dependencies that aren't in Solution: " +
121
- JSON.stringify(missingItems));
122
- }
123
- return resultsHtml;
124
- })
125
- // ---------- Done ---------------------------------------------------------------------------------------------//
126
- .then(() => {
127
- return resultsHtml;
128
- })
129
- // ---------- Fatal error --------------------------------------------------------------------------------------//
130
- .catch(error => {
131
- resultsHtml.push(`&#x2716; error${currentAction}: ${error.message}`);
132
- return resultsHtml;
133
- }));
134
- }
135
- exports.checkSolution = checkSolution;
136
- /**
137
- * Compares two AGO items, fetching them if only their id is supplied.
138
- *
139
- * @param item1 First item or its AGO id
140
- * @param item2 Second item or its AGO id
141
- * @param authentication Credentials for the request to AGO
142
- * @returns True if objects are the same
143
- * @see Only comparable properties are compared; see deleteItemProps() in the `common` package
144
- */
145
- function compareItems(item1, item2, authentication = null) {
146
- return new Promise((resolve, reject) => {
147
- // If an input is a string, fetch the item; otherwise, clone the input because we will modify the
148
- // item base to remove incomparable properties
149
- let itemBaseDef1;
150
- if (typeof item1 === "string") {
151
- itemBaseDef1 = common.getItemBase(item1, authentication);
152
- }
153
- else {
154
- itemBaseDef1 = Promise.resolve(common.cloneObject(item1));
155
- }
156
- let itemBaseDef2;
157
- if (typeof item2 === "string") {
158
- itemBaseDef2 = common.getItemBase(item2, authentication);
159
- }
160
- else {
161
- itemBaseDef2 = Promise.resolve(common.cloneObject(item2));
162
- }
163
- Promise.all([itemBaseDef1, itemBaseDef2]).then(responses => {
164
- const [itemBase1, itemBase2] = responses;
165
- common.deleteItemProps(itemBase1);
166
- common.deleteItemProps(itemBase2);
167
- if (itemBase1.type === "Solution") {
168
- delete itemBase1.typeKeywords;
169
- delete itemBase1.size;
170
- delete itemBase2.typeKeywords;
171
- delete itemBase2.size;
172
- }
173
- /*console.log("----------------------------------------------------------------");
174
- console.log("item 1 " + item1 + ": ", JSON.stringify(itemBase1, null, 2));
175
- console.log("item 2 " + item2 + ": ", JSON.stringify(itemBase2, null, 2));
176
- console.log("----------------------------------------------------------------");*/
177
- resolve(common.compareJSONNoEmptyStrings(itemBase1, itemBase2));
178
- }, e => reject(e));
179
- });
180
- }
181
- exports.compareItems = compareItems;
182
- /**
183
- * Creates a hierarchy of the items in a Solution template.
184
- *
185
- * @param templates Array of templates from a Solution
186
- * @returns List of top-level items, each containing a recursive list of its dependencies
187
- */
188
- function getItemHierarchy(templates) {
189
- const hierarchy = [];
190
- // Get the template specified by id out of a list of templates
191
- function getTemplateInSolution(templates, id) {
192
- const iTemplate = templates.findIndex((template) => id === template.itemId);
193
- return iTemplate >= 0 ? templates[iTemplate] : null;
194
- }
195
- // Hierarchically list the dependencies of specified node
196
- function traceItemId(id, accumulatedHierarchy, alreadyVisitedIds = []) {
197
- // Get the dependencies of the node
198
- const template = getTemplateInSolution(templates, id);
199
- /* istanbul ignore else */
200
- if (template) {
201
- const templateEntry = {
202
- id,
203
- dependencies: []
204
- };
205
- // Visit each dependency, but only if this template is not in the alreadyVisitedIds list to avoid infinite loops
206
- if (alreadyVisitedIds.indexOf(id) < 0) {
207
- // Add dependency to alreadyVisitedIds list
208
- alreadyVisitedIds.push(id);
209
- template.dependencies.forEach(dependencyId => {
210
- // Remove dependency from list of templates to visit in the top-level loop
211
- const iDependencyTemplate = templateItemIds.indexOf(dependencyId);
212
- if (iDependencyTemplate >= 0) {
213
- templateItemIds.splice(iDependencyTemplate, 1);
214
- }
215
- traceItemId(dependencyId, templateEntry.dependencies, alreadyVisitedIds);
216
- });
217
- }
218
- accumulatedHierarchy.push(templateEntry);
219
- }
220
- }
221
- // Start with top-level nodes and add in the rest of the nodes to catch cycles without top-level nodes
222
- let templateItemIds = _getTopLevelItemIds(templates);
223
- const otherItems = templates
224
- .filter(template => templateItemIds.indexOf(template.itemId) < 0) // only keep non-top-level nodes
225
- .sort((a, b) => b.dependencies.length - a.dependencies.length); // sort so that nodes with more dependencies come first--reduces stubs
226
- templateItemIds = templateItemIds.concat(otherItems.map(template => template.itemId));
227
- // Step through the list of nodes; we'll also remove nodes as we visit them
228
- let itemId = templateItemIds.shift();
229
- while (typeof itemId !== "undefined") {
230
- traceItemId(itemId, hierarchy);
231
- itemId = templateItemIds.shift();
232
- }
233
- return hierarchy;
234
- }
235
- exports.getItemHierarchy = getItemHierarchy;
236
- // ------------------------------------------------------------------------------------------------------------------ //
237
- /**
238
- * Finds the top-level items in a Solution template--the items that are not dependencies of any other item.
239
- *
240
- * @param templates Array of templates from a Solution
241
- * @returns List of top-level item ids
242
- * @private
243
- */
244
- function _getTopLevelItemIds(templates) {
245
- // Find the top-level nodes. Start with all nodes, then remove those that other nodes depend on
246
- const topLevelItemCandidateIds = templates.map(function (template) { return template.itemId; });
247
- templates.forEach(function (template) {
248
- (template.dependencies || []).forEach(function (dependencyId) {
249
- const iNode = topLevelItemCandidateIds.indexOf(dependencyId);
250
- /* istanbul ignore else */
251
- if (iNode >= 0) {
252
- // Node is somebody's dependency, so remove the node from the list of top-level nodes
253
- // If iNode == -1, then it's a shared dependency and it has already been removed
254
- topLevelItemCandidateIds.splice(iNode, 1);
255
- }
256
- });
257
- });
258
- return topLevelItemCandidateIds;
259
- }
260
- exports._getTopLevelItemIds = _getTopLevelItemIds;
261
- ;
262
- //# sourceMappingURL=viewer.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"viewer.js","sourceRoot":"","sources":["../../src/viewer.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;;AAEH;;;;GAIG;AAEH,sEAAgD;AAEhD,wHAAwH;AAExH;;;;;;GAMG;AACH,SAAgB,aAAa,CAC3B,MAAc,EACd,iBAAqC,IAAI;IAEzC,MAAM,WAAW,GAAa,CAAC,QAAQ,MAAM,EAAE,CAAC,CAAC;IACjD,IAAI,IAA0B,CAAC;IAC/B,IAAI,UAAU,GAAG,IAAI,CAAC;IACtB,IAAI,aAAqC,CAAC;IAC1C,IAAI,eAAyB,CAAC;IAE9B,IAAI,aAAa,GAAW,8BAA8B,CAAC;IAC3D,OAAO,CACL,MAAM;SACH,eAAe,CAAC,MAAM,EAAE,cAAc,CAAC;QAExC,kHAAkH;SACjH,IAAI,CAAC,CAAC,OAA6B,EAAE,EAAE;QACtC,aAAa,GAAG,EAAE,CAAC;QACnB,IAAI,GAAG,OAAO,CAAC;QAEf,IAAI,CAAC,IAAI,EAAE;YACT,MAAM,IAAI,KAAK,CAAC,mBAAmB,CAAC,CAAC;SACtC;aAAM,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,KAAK,UAAU,EAAE;YACxC,MAAM,IAAI,KAAK,CAAC,wBAAwB,CAAC,CAAC;SAC3C;aAAM,IAAI,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;YACtD,WAAW,CAAC,IAAI,CAAC,sCAAsC,CAAC,CAAC;SAC1D;aAAM,IAAI,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;YACtD,UAAU,GAAG,KAAK,CAAC;YACnB,WAAW,CAAC,IAAI,CAAC,sCAAsC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