adapt-authoring-contentplugin 1.8.0 → 1.8.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.
- package/.github/workflows/addtoproject.yml +18 -0
- package/README.md +9 -0
- package/lib/ContentPluginModule.js +0 -14
- package/package.json +2 -2
- package/.github/workflows/new.yml +0 -15
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
name: Add to project
|
|
2
|
+
on:
|
|
3
|
+
issues:
|
|
4
|
+
types:
|
|
5
|
+
- opened
|
|
6
|
+
- reopened
|
|
7
|
+
pull_request:
|
|
8
|
+
types:
|
|
9
|
+
- opened
|
|
10
|
+
- reopened
|
|
11
|
+
workflow_dispatch:
|
|
12
|
+
jobs:
|
|
13
|
+
add-to-project:
|
|
14
|
+
uses: adapt-security/.github/.github/workflows/addtoproject.yml@main
|
|
15
|
+
with:
|
|
16
|
+
project-url: https://github.com/orgs/adapt-security/projects/5
|
|
17
|
+
secrets:
|
|
18
|
+
ADDTOPROJECT_TOKEN: ${{ secrets.ADDTOPROJECT_TOKEN }}
|
package/README.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# adapt-authoring-contentplugin
|
|
2
|
+
|
|
3
|
+
Manages Adapt framework plugins — the components, extensions, menus and themes that course content is built from. Handles installing, updating and querying the plugins available to the authoring tool.
|
|
4
|
+
|
|
5
|
+
Extends `AbstractApiModule` from [adapt-authoring-core](../adapt-authoring-core) and exposes plugins under the `contentplugins` collection.
|
|
6
|
+
|
|
7
|
+
## Documentation
|
|
8
|
+
|
|
9
|
+
- [Content plugins](docs/content-plugins.md) — how framework plugins are managed
|
|
@@ -443,20 +443,6 @@ class ContentPluginModule extends AbstractApiModule {
|
|
|
443
443
|
return p
|
|
444
444
|
}
|
|
445
445
|
|
|
446
|
-
/** @override */
|
|
447
|
-
async serveSchema (req, res, next) {
|
|
448
|
-
try {
|
|
449
|
-
const plugin = await this.get({ name: req.apiData.query.type }) || {}
|
|
450
|
-
const schema = await this.getSchema(plugin.schemaName)
|
|
451
|
-
if (!schema) {
|
|
452
|
-
return next(this.app.errors.NO_SCHEMA_DEF)
|
|
453
|
-
}
|
|
454
|
-
res.type('application/schema+json').json(schema.built)
|
|
455
|
-
} catch (e) {
|
|
456
|
-
return next(e)
|
|
457
|
-
}
|
|
458
|
-
}
|
|
459
|
-
|
|
460
446
|
/**
|
|
461
447
|
* Express request handler for installing a plugin (also used for updating via zip upload).
|
|
462
448
|
* @param {external:ExpressRequest} req
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "adapt-authoring-contentplugin",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.2",
|
|
4
4
|
"description": "Module for managing framework plugins",
|
|
5
5
|
"homepage": "https://github.com/adapt-security/adapt-authoring-contentplugin",
|
|
6
6
|
"repository": "github:adapt-security/adapt-authoring-contentplugin",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"main": "index.js",
|
|
11
11
|
"type": "module",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"adapt-authoring-api": "^
|
|
13
|
+
"adapt-authoring-api": "^4.0.1",
|
|
14
14
|
"adapt-authoring-core": "^3.0.0",
|
|
15
15
|
"adapt-cli": "^3.3.3",
|
|
16
16
|
"semver": "^7.6.0"
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# Calls the org-level reusable workflow to add PRs to the TODO Board
|
|
2
|
-
|
|
3
|
-
name: Add PR to Project
|
|
4
|
-
|
|
5
|
-
on:
|
|
6
|
-
pull_request:
|
|
7
|
-
types:
|
|
8
|
-
- opened
|
|
9
|
-
- reopened
|
|
10
|
-
|
|
11
|
-
jobs:
|
|
12
|
-
add-to-project:
|
|
13
|
-
uses: adapt-security/.github/.github/workflows/new.yml@main
|
|
14
|
-
secrets:
|
|
15
|
-
PROJECTS_SECRET: ${{ secrets.PROJECTS_SECRET }}
|