@stoplight/elements-dev-portal 1.6.3 → 1.6.7
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/index.esm.js +27 -13
- package/index.js +27 -13
- package/index.mjs +27 -13
- package/package.json +3 -3
- package/version.d.ts +1 -1
- package/web-components.min.js +1 -1
package/index.esm.js
CHANGED
|
@@ -72,7 +72,7 @@ const LinkComponent = ({ children, href }) => {
|
|
|
72
72
|
const decodedResolvedUriWithoutAnchor = decodeURIComponent(resolvedUriWithoutAnchor);
|
|
73
73
|
const edge = node.outbound_edges.find(edge => edge.uri === decodedUrl || edge.uri === decodedResolvedUriWithoutAnchor);
|
|
74
74
|
if (edge) {
|
|
75
|
-
return React.createElement(Link, { to: `${edge.slug}${hash
|
|
75
|
+
return React.createElement(Link, { to: `${edge.slug}${hash ? `#${hash}` : ''}` }, children);
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
return React.createElement("a", { href: href }, children);
|
|
@@ -179,7 +179,7 @@ const UpgradeToStarter = () => (React__default.createElement(Flex, { as: "a", hr
|
|
|
179
179
|
React__default.createElement(Icon, { icon: faExclamationTriangle, size: "4x" }),
|
|
180
180
|
React__default.createElement(Box, { pt: 3 }, "Please upgrade your Stoplight Workspace to the Starter Plan to use Elements Dev Portal in production.")));
|
|
181
181
|
|
|
182
|
-
const appVersion = '1.6.
|
|
182
|
+
const appVersion = '1.6.7';
|
|
183
183
|
|
|
184
184
|
class ResponseError extends Error {
|
|
185
185
|
constructor(message, responseCode) {
|
|
@@ -190,8 +190,11 @@ class ResponseError extends Error {
|
|
|
190
190
|
}
|
|
191
191
|
const getNodeContent = ({ nodeSlug, projectId, branchSlug, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
192
192
|
const nodeId = getNodeIdFromSlug(nodeSlug);
|
|
193
|
-
const
|
|
194
|
-
const
|
|
193
|
+
const encodedNodeId = encodeURIComponent(nodeId);
|
|
194
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
195
|
+
const encodedBranchSlug = branchSlug ? encodeURIComponent(branchSlug) : '';
|
|
196
|
+
const branchQuery = encodedBranchSlug ? `?branch=${encodedBranchSlug}` : '';
|
|
197
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/nodes/${encodedNodeId}${branchQuery}`, {
|
|
195
198
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
196
199
|
});
|
|
197
200
|
const data = yield response.json();
|
|
@@ -213,7 +216,8 @@ function getNodeIdFromSlug(nodeSlug) {
|
|
|
213
216
|
}
|
|
214
217
|
|
|
215
218
|
const getBranches = ({ projectId, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
216
|
-
const
|
|
219
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
220
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/branches`, {
|
|
217
221
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
218
222
|
});
|
|
219
223
|
const data = yield response.json();
|
|
@@ -236,8 +240,10 @@ function useGetNodeContent({ nodeSlug, projectId, branchSlug, }) {
|
|
|
236
240
|
}
|
|
237
241
|
|
|
238
242
|
const getTableOfContents = ({ projectId, branchSlug, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
239
|
-
const
|
|
240
|
-
const
|
|
243
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
244
|
+
const encodedBranchSlug = branchSlug ? encodeURIComponent(branchSlug) : '';
|
|
245
|
+
const branchQuery = encodedBranchSlug ? `?branch=${encodedBranchSlug}` : '';
|
|
246
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/table-of-contents${branchQuery}`, {
|
|
241
247
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
242
248
|
});
|
|
243
249
|
const data = yield response.json();
|
|
@@ -322,23 +328,30 @@ const getNodes = ({ workspaceId, branchSlug, projectIds, search, platformUrl = '
|
|
|
322
328
|
const queryParams = [];
|
|
323
329
|
let fetchedWorkspaceId = workspaceId || '';
|
|
324
330
|
if (!workspaceId && (projectIds === null || projectIds === void 0 ? void 0 : projectIds.length)) {
|
|
325
|
-
const
|
|
331
|
+
const encodedProjectId = encodeURIComponent(projectIds[0]);
|
|
332
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}`, {
|
|
326
333
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
327
334
|
});
|
|
328
335
|
const data = yield response.json();
|
|
329
336
|
fetchedWorkspaceId = data.workspace.id;
|
|
330
337
|
}
|
|
331
338
|
if (projectIds && projectIds.length) {
|
|
332
|
-
queryParams.push(...projectIds.map((projectId, index) =>
|
|
339
|
+
queryParams.push(...projectIds.map((projectId, index) => {
|
|
340
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
341
|
+
return `project_ids[${index}]=${encodedProjectId}`;
|
|
342
|
+
}));
|
|
333
343
|
}
|
|
334
344
|
if (search) {
|
|
335
|
-
|
|
345
|
+
const encodedSearch = encodeURIComponent(search);
|
|
346
|
+
queryParams.push(`search=${encodedSearch}`);
|
|
336
347
|
}
|
|
337
348
|
if (branchSlug) {
|
|
338
|
-
|
|
349
|
+
const encodedBranchSlug = encodeURIComponent(branchSlug);
|
|
350
|
+
queryParams.push(`branchSlug=${encodedBranchSlug}`);
|
|
339
351
|
}
|
|
340
352
|
const query = queryParams.length ? `?${queryParams.join('&')}` : '';
|
|
341
|
-
const
|
|
353
|
+
const encodedWorkspaceId = encodeURIComponent(fetchedWorkspaceId);
|
|
354
|
+
const response = yield fetch(`${platformUrl}/api/v1/workspaces/${encodedWorkspaceId}/nodes${query}`, {
|
|
342
355
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
343
356
|
});
|
|
344
357
|
const data = yield response.json();
|
|
@@ -349,7 +362,8 @@ const getNodes = ({ workspaceId, branchSlug, projectIds, search, platformUrl = '
|
|
|
349
362
|
});
|
|
350
363
|
|
|
351
364
|
const getWorkspace = ({ projectIds, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
352
|
-
const
|
|
365
|
+
const encodedProjectId = encodeURIComponent(projectIds[0]);
|
|
366
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}`, {
|
|
353
367
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
354
368
|
});
|
|
355
369
|
const data = yield response.json();
|
package/index.js
CHANGED
|
@@ -99,7 +99,7 @@ const LinkComponent = ({ children, href }) => {
|
|
|
99
99
|
const decodedResolvedUriWithoutAnchor = decodeURIComponent(resolvedUriWithoutAnchor);
|
|
100
100
|
const edge = node.outbound_edges.find(edge => edge.uri === decodedUrl || edge.uri === decodedResolvedUriWithoutAnchor);
|
|
101
101
|
if (edge) {
|
|
102
|
-
return React__namespace.createElement(Link, { to: `${edge.slug}${hash
|
|
102
|
+
return React__namespace.createElement(Link, { to: `${edge.slug}${hash ? `#${hash}` : ''}` }, children);
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
105
|
return React__namespace.createElement("a", { href: href }, children);
|
|
@@ -206,7 +206,7 @@ const UpgradeToStarter = () => (React__default["default"].createElement(mosaic.F
|
|
|
206
206
|
React__default["default"].createElement(mosaic.Icon, { icon: freeSolidSvgIcons.faExclamationTriangle, size: "4x" }),
|
|
207
207
|
React__default["default"].createElement(mosaic.Box, { pt: 3 }, "Please upgrade your Stoplight Workspace to the Starter Plan to use Elements Dev Portal in production.")));
|
|
208
208
|
|
|
209
|
-
const appVersion = '1.6.
|
|
209
|
+
const appVersion = '1.6.7';
|
|
210
210
|
|
|
211
211
|
class ResponseError extends Error {
|
|
212
212
|
constructor(message, responseCode) {
|
|
@@ -217,8 +217,11 @@ class ResponseError extends Error {
|
|
|
217
217
|
}
|
|
218
218
|
const getNodeContent = ({ nodeSlug, projectId, branchSlug, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
219
219
|
const nodeId = getNodeIdFromSlug(nodeSlug);
|
|
220
|
-
const
|
|
221
|
-
const
|
|
220
|
+
const encodedNodeId = encodeURIComponent(nodeId);
|
|
221
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
222
|
+
const encodedBranchSlug = branchSlug ? encodeURIComponent(branchSlug) : '';
|
|
223
|
+
const branchQuery = encodedBranchSlug ? `?branch=${encodedBranchSlug}` : '';
|
|
224
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/nodes/${encodedNodeId}${branchQuery}`, {
|
|
222
225
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
223
226
|
});
|
|
224
227
|
const data = yield response.json();
|
|
@@ -240,7 +243,8 @@ function getNodeIdFromSlug(nodeSlug) {
|
|
|
240
243
|
}
|
|
241
244
|
|
|
242
245
|
const getBranches = ({ projectId, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
243
|
-
const
|
|
246
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
247
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/branches`, {
|
|
244
248
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
245
249
|
});
|
|
246
250
|
const data = yield response.json();
|
|
@@ -263,8 +267,10 @@ function useGetNodeContent({ nodeSlug, projectId, branchSlug, }) {
|
|
|
263
267
|
}
|
|
264
268
|
|
|
265
269
|
const getTableOfContents = ({ projectId, branchSlug, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
266
|
-
const
|
|
267
|
-
const
|
|
270
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
271
|
+
const encodedBranchSlug = branchSlug ? encodeURIComponent(branchSlug) : '';
|
|
272
|
+
const branchQuery = encodedBranchSlug ? `?branch=${encodedBranchSlug}` : '';
|
|
273
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/table-of-contents${branchQuery}`, {
|
|
268
274
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
269
275
|
});
|
|
270
276
|
const data = yield response.json();
|
|
@@ -349,23 +355,30 @@ const getNodes = ({ workspaceId, branchSlug, projectIds, search, platformUrl = '
|
|
|
349
355
|
const queryParams = [];
|
|
350
356
|
let fetchedWorkspaceId = workspaceId || '';
|
|
351
357
|
if (!workspaceId && (projectIds === null || projectIds === void 0 ? void 0 : projectIds.length)) {
|
|
352
|
-
const
|
|
358
|
+
const encodedProjectId = encodeURIComponent(projectIds[0]);
|
|
359
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}`, {
|
|
353
360
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
354
361
|
});
|
|
355
362
|
const data = yield response.json();
|
|
356
363
|
fetchedWorkspaceId = data.workspace.id;
|
|
357
364
|
}
|
|
358
365
|
if (projectIds && projectIds.length) {
|
|
359
|
-
queryParams.push(...projectIds.map((projectId, index) =>
|
|
366
|
+
queryParams.push(...projectIds.map((projectId, index) => {
|
|
367
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
368
|
+
return `project_ids[${index}]=${encodedProjectId}`;
|
|
369
|
+
}));
|
|
360
370
|
}
|
|
361
371
|
if (search) {
|
|
362
|
-
|
|
372
|
+
const encodedSearch = encodeURIComponent(search);
|
|
373
|
+
queryParams.push(`search=${encodedSearch}`);
|
|
363
374
|
}
|
|
364
375
|
if (branchSlug) {
|
|
365
|
-
|
|
376
|
+
const encodedBranchSlug = encodeURIComponent(branchSlug);
|
|
377
|
+
queryParams.push(`branchSlug=${encodedBranchSlug}`);
|
|
366
378
|
}
|
|
367
379
|
const query = queryParams.length ? `?${queryParams.join('&')}` : '';
|
|
368
|
-
const
|
|
380
|
+
const encodedWorkspaceId = encodeURIComponent(fetchedWorkspaceId);
|
|
381
|
+
const response = yield fetch(`${platformUrl}/api/v1/workspaces/${encodedWorkspaceId}/nodes${query}`, {
|
|
369
382
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
370
383
|
});
|
|
371
384
|
const data = yield response.json();
|
|
@@ -376,7 +389,8 @@ const getNodes = ({ workspaceId, branchSlug, projectIds, search, platformUrl = '
|
|
|
376
389
|
});
|
|
377
390
|
|
|
378
391
|
const getWorkspace = ({ projectIds, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
379
|
-
const
|
|
392
|
+
const encodedProjectId = encodeURIComponent(projectIds[0]);
|
|
393
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}`, {
|
|
380
394
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
381
395
|
});
|
|
382
396
|
const data = yield response.json();
|
package/index.mjs
CHANGED
|
@@ -72,7 +72,7 @@ const LinkComponent = ({ children, href }) => {
|
|
|
72
72
|
const decodedResolvedUriWithoutAnchor = decodeURIComponent(resolvedUriWithoutAnchor);
|
|
73
73
|
const edge = node.outbound_edges.find(edge => edge.uri === decodedUrl || edge.uri === decodedResolvedUriWithoutAnchor);
|
|
74
74
|
if (edge) {
|
|
75
|
-
return React.createElement(Link, { to: `${edge.slug}${hash
|
|
75
|
+
return React.createElement(Link, { to: `${edge.slug}${hash ? `#${hash}` : ''}` }, children);
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
return React.createElement("a", { href: href }, children);
|
|
@@ -179,7 +179,7 @@ const UpgradeToStarter = () => (React__default.createElement(Flex, { as: "a", hr
|
|
|
179
179
|
React__default.createElement(Icon, { icon: faExclamationTriangle, size: "4x" }),
|
|
180
180
|
React__default.createElement(Box, { pt: 3 }, "Please upgrade your Stoplight Workspace to the Starter Plan to use Elements Dev Portal in production.")));
|
|
181
181
|
|
|
182
|
-
const appVersion = '1.6.
|
|
182
|
+
const appVersion = '1.6.7';
|
|
183
183
|
|
|
184
184
|
class ResponseError extends Error {
|
|
185
185
|
constructor(message, responseCode) {
|
|
@@ -190,8 +190,11 @@ class ResponseError extends Error {
|
|
|
190
190
|
}
|
|
191
191
|
const getNodeContent = ({ nodeSlug, projectId, branchSlug, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
192
192
|
const nodeId = getNodeIdFromSlug(nodeSlug);
|
|
193
|
-
const
|
|
194
|
-
const
|
|
193
|
+
const encodedNodeId = encodeURIComponent(nodeId);
|
|
194
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
195
|
+
const encodedBranchSlug = branchSlug ? encodeURIComponent(branchSlug) : '';
|
|
196
|
+
const branchQuery = encodedBranchSlug ? `?branch=${encodedBranchSlug}` : '';
|
|
197
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/nodes/${encodedNodeId}${branchQuery}`, {
|
|
195
198
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
196
199
|
});
|
|
197
200
|
const data = yield response.json();
|
|
@@ -213,7 +216,8 @@ function getNodeIdFromSlug(nodeSlug) {
|
|
|
213
216
|
}
|
|
214
217
|
|
|
215
218
|
const getBranches = ({ projectId, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
216
|
-
const
|
|
219
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
220
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/branches`, {
|
|
217
221
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
218
222
|
});
|
|
219
223
|
const data = yield response.json();
|
|
@@ -236,8 +240,10 @@ function useGetNodeContent({ nodeSlug, projectId, branchSlug, }) {
|
|
|
236
240
|
}
|
|
237
241
|
|
|
238
242
|
const getTableOfContents = ({ projectId, branchSlug, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
239
|
-
const
|
|
240
|
-
const
|
|
243
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
244
|
+
const encodedBranchSlug = branchSlug ? encodeURIComponent(branchSlug) : '';
|
|
245
|
+
const branchQuery = encodedBranchSlug ? `?branch=${encodedBranchSlug}` : '';
|
|
246
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}/table-of-contents${branchQuery}`, {
|
|
241
247
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
242
248
|
});
|
|
243
249
|
const data = yield response.json();
|
|
@@ -322,23 +328,30 @@ const getNodes = ({ workspaceId, branchSlug, projectIds, search, platformUrl = '
|
|
|
322
328
|
const queryParams = [];
|
|
323
329
|
let fetchedWorkspaceId = workspaceId || '';
|
|
324
330
|
if (!workspaceId && (projectIds === null || projectIds === void 0 ? void 0 : projectIds.length)) {
|
|
325
|
-
const
|
|
331
|
+
const encodedProjectId = encodeURIComponent(projectIds[0]);
|
|
332
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}`, {
|
|
326
333
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
327
334
|
});
|
|
328
335
|
const data = yield response.json();
|
|
329
336
|
fetchedWorkspaceId = data.workspace.id;
|
|
330
337
|
}
|
|
331
338
|
if (projectIds && projectIds.length) {
|
|
332
|
-
queryParams.push(...projectIds.map((projectId, index) =>
|
|
339
|
+
queryParams.push(...projectIds.map((projectId, index) => {
|
|
340
|
+
const encodedProjectId = encodeURIComponent(projectId);
|
|
341
|
+
return `project_ids[${index}]=${encodedProjectId}`;
|
|
342
|
+
}));
|
|
333
343
|
}
|
|
334
344
|
if (search) {
|
|
335
|
-
|
|
345
|
+
const encodedSearch = encodeURIComponent(search);
|
|
346
|
+
queryParams.push(`search=${encodedSearch}`);
|
|
336
347
|
}
|
|
337
348
|
if (branchSlug) {
|
|
338
|
-
|
|
349
|
+
const encodedBranchSlug = encodeURIComponent(branchSlug);
|
|
350
|
+
queryParams.push(`branchSlug=${encodedBranchSlug}`);
|
|
339
351
|
}
|
|
340
352
|
const query = queryParams.length ? `?${queryParams.join('&')}` : '';
|
|
341
|
-
const
|
|
353
|
+
const encodedWorkspaceId = encodeURIComponent(fetchedWorkspaceId);
|
|
354
|
+
const response = yield fetch(`${platformUrl}/api/v1/workspaces/${encodedWorkspaceId}/nodes${query}`, {
|
|
342
355
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
343
356
|
});
|
|
344
357
|
const data = yield response.json();
|
|
@@ -349,7 +362,8 @@ const getNodes = ({ workspaceId, branchSlug, projectIds, search, platformUrl = '
|
|
|
349
362
|
});
|
|
350
363
|
|
|
351
364
|
const getWorkspace = ({ projectIds, platformUrl = 'https://stoplight.io', platformAuthToken, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
352
|
-
const
|
|
365
|
+
const encodedProjectId = encodeURIComponent(projectIds[0]);
|
|
366
|
+
const response = yield fetch(`${platformUrl}/api/v1/projects/${encodedProjectId}`, {
|
|
353
367
|
headers: Object.assign({ 'Stoplight-Elements-Version': appVersion }, (platformAuthToken && { Authorization: `Bearer ${platformAuthToken}` })),
|
|
354
368
|
});
|
|
355
369
|
const data = yield response.json();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stoplight/elements-dev-portal",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.7",
|
|
4
4
|
"description": "UI components for composing beautiful developer documentation.",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"main": "./index.js",
|
|
@@ -27,9 +27,9 @@
|
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@fortawesome/free-solid-svg-icons": "^5.10.2",
|
|
30
|
-
"@stoplight/elements-core": "~7.5.
|
|
30
|
+
"@stoplight/elements-core": "~7.5.7",
|
|
31
31
|
"@stoplight/markdown-viewer": "^5.3.2",
|
|
32
|
-
"@stoplight/mosaic": "^1.
|
|
32
|
+
"@stoplight/mosaic": "^1.15.2",
|
|
33
33
|
"@stoplight/path": "^1.3.2",
|
|
34
34
|
"@stoplight/types": "^12.0.0",
|
|
35
35
|
"classnames": "^2.2.6",
|
package/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const appVersion = "1.6.
|
|
1
|
+
export declare const appVersion = "1.6.7";
|