@learnpack/learnpack 5.0.328 → 5.0.329
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/lib/commands/publish.js +2 -0
- package/lib/utils/api.d.ts +1 -0
- package/lib/utils/api.js +1 -1
- package/package.json +1 -1
- package/src/commands/publish.ts +2 -0
- package/src/utils/api.ts +2 -1
package/lib/commands/publish.js
CHANGED
|
@@ -33,6 +33,7 @@ const handleAssetCreation = async (sessionPayload, learnJson, selectedLang, lear
|
|
|
33
33
|
slug: slug,
|
|
34
34
|
title: learnJson.title[selectedLang],
|
|
35
35
|
lang: selectedLang,
|
|
36
|
+
graded: true,
|
|
36
37
|
description: learnJson.description[selectedLang],
|
|
37
38
|
learnpack_deploy_url: learnpackDeployUrl,
|
|
38
39
|
technologies: learnJson.technologies.map((tech) => tech.toLowerCase().replace(/\s+/g, "-")),
|
|
@@ -57,6 +58,7 @@ const handleAssetCreation = async (sessionPayload, learnJson, selectedLang, lear
|
|
|
57
58
|
}
|
|
58
59
|
console_1.default.info("Asset exists, updating it");
|
|
59
60
|
const asset = await api_1.default.updateAsset(sessionPayload.token, slug, {
|
|
61
|
+
graded: true,
|
|
60
62
|
learnpack_deploy_url: learnpackDeployUrl,
|
|
61
63
|
title: learnJson.title[selectedLang],
|
|
62
64
|
category: category,
|
package/lib/utils/api.d.ts
CHANGED
package/lib/utils/api.js
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@learnpack/learnpack",
|
|
3
3
|
"description": "Seamlessly build, sell and/or take interactive & auto-graded tutorials, start learning now or build a new tutorial to your audience.",
|
|
4
|
-
"version": "5.0.
|
|
4
|
+
"version": "5.0.329",
|
|
5
5
|
"author": "Alejandro Sanchez @alesanchezr",
|
|
6
6
|
"contributors": [
|
|
7
7
|
{
|
package/src/commands/publish.ts
CHANGED
|
@@ -47,6 +47,7 @@ export const handleAssetCreation = async (
|
|
|
47
47
|
slug: slug,
|
|
48
48
|
title: learnJson.title[selectedLang],
|
|
49
49
|
lang: selectedLang,
|
|
50
|
+
graded: true,
|
|
50
51
|
description: learnJson.description[selectedLang],
|
|
51
52
|
learnpack_deploy_url: learnpackDeployUrl,
|
|
52
53
|
technologies: learnJson.technologies.map((tech: string) =>
|
|
@@ -78,6 +79,7 @@ export const handleAssetCreation = async (
|
|
|
78
79
|
|
|
79
80
|
Console.info("Asset exists, updating it")
|
|
80
81
|
const asset = await api.updateAsset(sessionPayload.token, slug, {
|
|
82
|
+
graded: true,
|
|
81
83
|
learnpack_deploy_url: learnpackDeployUrl,
|
|
82
84
|
title: learnJson.title[selectedLang],
|
|
83
85
|
category: category,
|
package/src/utils/api.ts
CHANGED
|
@@ -420,6 +420,7 @@ type TAssetMissing = {
|
|
|
420
420
|
slug: string;
|
|
421
421
|
title: string;
|
|
422
422
|
lang: string;
|
|
423
|
+
graded: boolean;
|
|
423
424
|
url: string;
|
|
424
425
|
description: string;
|
|
425
426
|
learnpack_deploy_url: string;
|
|
@@ -444,7 +445,7 @@ export const createAsset = async (token: string, asset: TAssetMissing) => {
|
|
|
444
445
|
readme_url: null,
|
|
445
446
|
difficulty: null,
|
|
446
447
|
duration: null,
|
|
447
|
-
graded:
|
|
448
|
+
graded: asset.graded,
|
|
448
449
|
gitpod: true,
|
|
449
450
|
category: asset.category,
|
|
450
451
|
owner: asset.owner,
|