From 2882b9e8159b17f57ee5a225f4710ee30e152b6a Mon Sep 17 00:00:00 2001 From: Jan Philip Schellenberg Date: Mon, 1 Feb 2021 10:35:07 +0100 Subject: [PATCH] fix(deps): update h5p-server to v7.0.0-alpha.1 (#1208) --- client/package-lock.json | 92 +++++----------------------------- client/package.json | 2 +- package-lock.json | 33 ++++++------ package.json | 4 +- server/src/routes/h5pRoutes.ts | 2 +- server/src/routes/index.ts | 8 +-- 6 files changed, 38 insertions(+), 103 deletions(-) diff --git a/client/package-lock.json b/client/package-lock.json index 35dc66be9..ce2606b69 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -2018,11 +2018,11 @@ } }, "@lumieducation/h5p-server": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/@lumieducation/h5p-server/-/h5p-server-6.2.0.tgz", - "integrity": "sha512-PiIdxsC5rjVwBe2AfAGZOWGRcj2/kd4xXmfn0iX4xRNEp2CmpdnR10Rr849hjHIxM/EIi5vP773woksUojqvLw==", + "version": "7.0.0-alpha.1", + "resolved": "https://registry.npmjs.org/@lumieducation/h5p-server/-/h5p-server-7.0.0-alpha.1.tgz", + "integrity": "sha512-1C/PoMmgCD1tRRjT6ZVvr71t8EyyzMCFBnZw8AudQdQOo4Nm6FjMyZ+GH31mP55Vry5lI6NIh1RGoHnfu9P5sg==", "requires": { - "@types/react": "^16.9.35", + "@types/react": "17.0.0", "@types/tmp": "^0.2.0", "ajv": "^7.0.0", "ajv-keywords": "^4.0.0", @@ -2032,16 +2032,11 @@ "debug": "^4.1.1", "fs-extra": "^9.0.0", "glob-promise": "^3.4.0", - "html-escaper": "^3.0.0", "image-size": "^0.9.0", "jsonpath": "^1.0.2", "merge": "^2.0.0", "mime-types": "^2.1.26", "nanoid": "^3.1.10", - "postcss": "^8.1.10", - "postcss-clean": "^1.1.0", - "postcss-safe-parser": "^5.0.2", - "postcss-url": "^10.1.1", "promisepipe": "^3.0.0", "qs": "^6.9.3", "sanitize-html": "^2.3.0", @@ -2051,17 +2046,6 @@ "upath": "^2.0.0", "yauzl-promise": "^2.1.3", "yazl": "^2.5.1" - }, - "dependencies": { - "@types/react": { - "version": "16.14.2", - "resolved": "https://registry.npmjs.org/@types/react/-/react-16.14.2.tgz", - "integrity": "sha512-BzzcAlyDxXl2nANlabtT4thtvbbnhee8hMmH/CcJrISDBVcJS1iOsP1f0OAgSdGE0MsY9tqcrb9YoZcOFv9dbQ==", - "requires": { - "@types/prop-types": "*", - "csstype": "^3.0.2" - } - } } }, "@lumieducation/h5p-webcomponents": { @@ -5677,11 +5661,6 @@ "resolved": "https://registry.npmjs.org/csstype/-/csstype-3.0.6.tgz", "integrity": "sha512-+ZAmfyWMT7TiIlzdqJgjMb7S4f1beorDbWbsocyK4RaiqA5RTX3K14bnBWmmA9QEM0gRdsjyyrEmcyga8Zsxmw==" }, - "cuint": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/cuint/-/cuint-0.2.2.tgz", - "integrity": "sha1-QICG1AlVDCYxFVYZ6fp7ytw7mRs=" - }, "cyclist": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/cyclist/-/cyclist-1.0.1.tgz", @@ -8489,11 +8468,6 @@ "resolved": "https://registry.npmjs.org/html-entities/-/html-entities-1.4.0.tgz", "integrity": "sha512-8nxjcBcd8wovbeKx7h3wTji4e6+rhaVuPNpMqwWgnHh+N9ToqsCs6XztWRBPQ+UtzsoMAdKZtUENoVzU/EMtZA==" }, - "html-escaper": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-3.0.0.tgz", - "integrity": "sha512-69CofXDozHqdHDl1BZ3YiFp5rYN1qTwSXIVcBhVcZNkzj1vzx6Sko1nT58mzKip19DbKo8lHR9hf6/XeZ9+s3w==" - }, "html-minifier-terser": { "version": "5.1.1", "resolved": "https://registry.yarnpkg.com/html-minifier-terser/-/html-minifier-terser-5.1.1.tgz", @@ -10933,9 +10907,9 @@ } }, "jsonpath": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/jsonpath/-/jsonpath-1.0.2.tgz", - "integrity": "sha512-rmzlgFZiQPc6q4HDyK8s9Qb4oxBnI5sF61y/Co5PV0lc3q2bIuRsNdueVbhoSHdKM4fxeimphOAtfz47yjCfeA==", + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/jsonpath/-/jsonpath-1.1.0.tgz", + "integrity": "sha512-CZHwa1sZOf42qkIyK7evwToFXeTB4iplbl6Z9CVwU0wmBQPffL6gtYJXCoeciJoZENMuzaidPjhp2iOLRei4wQ==", "requires": { "esprima": "1.2.2", "static-eval": "2.0.2", @@ -12691,27 +12665,6 @@ } } }, - "postcss-clean": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/postcss-clean/-/postcss-clean-1.1.0.tgz", - "integrity": "sha512-83g3GqMbCM5NL6MlbbPLJ/m2NrUepBF44MoDk4Gt04QGXeXKh9+ilQa0DzLnYnvqYHQCw83nckuEzBFr2muwbg==", - "requires": { - "clean-css": "^4.x", - "postcss": "^6.x" - }, - "dependencies": { - "postcss": { - "version": "6.0.23", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-6.0.23.tgz", - "integrity": "sha512-soOk1h6J3VMTZtVeVpv15/Hpdl2cBLX3CAw4TAbkpTJiNPk9YP/zWcD1ND+xEtvyuuvKzbxliTOIyvkSeSJ6ag==", - "requires": { - "chalk": "^2.4.1", - "source-map": "^0.6.1", - "supports-color": "^5.4.0" - } - } - } - }, "postcss-color-functional-notation": { "version": "2.0.1", "resolved": "https://registry.yarnpkg.com/postcss-color-functional-notation/-/postcss-color-functional-notation-2.0.1.tgz", @@ -14840,17 +14793,6 @@ } } }, - "postcss-url": { - "version": "10.1.1", - "resolved": "https://registry.npmjs.org/postcss-url/-/postcss-url-10.1.1.tgz", - "integrity": "sha512-cYeRNcXUMiM1sr3UgHkY+zMuqhSmJaLeP3VOZWWqShBDMB10DlrK5KfciLK0LGr7xKDPP5nH7Q2odvDHQSrP9A==", - "requires": { - "make-dir": "3.1.0", - "mime": "2.4.6", - "minimatch": "3.0.4", - "xxhashjs": "0.2.2" - } - }, "postcss-value-parser": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.1.0.tgz", @@ -16355,9 +16297,9 @@ } }, "sanitize-html": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/sanitize-html/-/sanitize-html-2.3.0.tgz", - "integrity": "sha512-JAsbaKskfxR+ZhEnqO/T3c2dKalVDA6sXIgy/27TatIUzOPO/zWr1r8Ykzp1cwJx1j+DPMQF5ifvhniixRWYDA==", + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/sanitize-html/-/sanitize-html-2.3.2.tgz", + "integrity": "sha512-p7neuskvC8pSurUjdVmbWPXmc9A4+QpOXIL+4gwFC+av5h+lYCXFT8uEneqsFQg/wEA1IH+cKQA60AaQI6p3cg==", "requires": { "deepmerge": "^4.2.2", "escape-string-regexp": "^4.0.0", @@ -18137,9 +18079,9 @@ "integrity": "sha512-B3ZIOf1IKeH2ixgHhj6la6xdwR9QrLC5d1VKeCSY4tvkqhF2eqd9O7txNlS0PO3GrBAFIdr3L1ndNwteUbZLYg==" }, "uglify-js": { - "version": "3.12.4", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.12.4.tgz", - "integrity": "sha512-L5i5jg/SHkEqzN18gQMTWsZk3KelRsfD1wUVNqtq0kzqWQqcJjyL8yc1o8hJgRrWqrAl2mUFbhfznEIoi7zi2A==" + "version": "3.12.6", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.12.6.tgz", + "integrity": "sha512-aqWHe3DfQmZUDGWBbabZ2eQnJlQd1fKlMUu7gV+MiTuDzdgDw31bI3wA2jLLsV/hNcDP26IfyEgSVoft5+0SVw==" }, "underscore": { "version": "1.7.0", @@ -19994,14 +19936,6 @@ "resolved": "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz", "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==" }, - "xxhashjs": { - "version": "0.2.2", - "resolved": "https://registry.npmjs.org/xxhashjs/-/xxhashjs-0.2.2.tgz", - "integrity": "sha512-AkTuIuVTET12tpsVIQo+ZU6f/qDmKuRUcjaqR+OIvm+aCBsZ95i7UVY5WJ9TMsSaZ0DA2WxoZ4acu0sPH+OKAw==", - "requires": { - "cuint": "^0.2.2" - } - }, "y18n": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.1.tgz", diff --git a/client/package.json b/client/package.json index ff4b429af..7eff08ce6 100644 --- a/client/package.json +++ b/client/package.json @@ -4,7 +4,7 @@ "private": true, "dependencies": { "@lumieducation/h5p-react": "0.1.2", - "@lumieducation/h5p-server": "6.2.0", + "@lumieducation/h5p-server": "7.0.0-alpha.1", "@lumieducation/xapi-viewer": "1.0.1-alpha.3", "@material-ui/core": "4.11.3", "@material-ui/icons": "4.11.2", diff --git a/package-lock.json b/package-lock.json index 25cae6446..4ec2f92a2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1367,6 +1367,15 @@ } } }, + "@lumieducation/h5p-express": { + "version": "7.0.0-alpha.1", + "resolved": "https://registry.npmjs.org/@lumieducation/h5p-express/-/h5p-express-7.0.0-alpha.1.tgz", + "integrity": "sha512-UWMshn7aUmnq54/etQGqnzeaBY6OJly4C7GyOtiJArMaSqxDkeQTRx48SgkVi9xcoJu8sT+emOgO/Vq9btI7LQ==", + "requires": { + "@lumieducation/h5p-server": "^7.0.0-alpha.1", + "express": "4.17.1" + } + }, "@lumieducation/h5p-html-exporter": { "version": "7.0.0-alpha.1", "resolved": "https://registry.npmjs.org/@lumieducation/h5p-html-exporter/-/h5p-html-exporter-7.0.0-alpha.1.tgz", @@ -1424,11 +1433,11 @@ } }, "@lumieducation/h5p-server": { - "version": "6.2.0", - "resolved": "https://registry.npmjs.org/@lumieducation/h5p-server/-/h5p-server-6.2.0.tgz", - "integrity": "sha512-PiIdxsC5rjVwBe2AfAGZOWGRcj2/kd4xXmfn0iX4xRNEp2CmpdnR10Rr849hjHIxM/EIi5vP773woksUojqvLw==", + "version": "7.0.0-alpha.1", + "resolved": "https://registry.npmjs.org/@lumieducation/h5p-server/-/h5p-server-7.0.0-alpha.1.tgz", + "integrity": "sha512-1C/PoMmgCD1tRRjT6ZVvr71t8EyyzMCFBnZw8AudQdQOo4Nm6FjMyZ+GH31mP55Vry5lI6NIh1RGoHnfu9P5sg==", "requires": { - "@types/react": "^16.9.35", + "@types/react": "17.0.0", "@types/tmp": "^0.2.0", "ajv": "^7.0.0", "ajv-keywords": "^4.0.0", @@ -1438,16 +1447,11 @@ "debug": "^4.1.1", "fs-extra": "^9.0.0", "glob-promise": "^3.4.0", - "html-escaper": "^3.0.0", "image-size": "^0.9.0", "jsonpath": "^1.0.2", "merge": "^2.0.0", "mime-types": "^2.1.26", "nanoid": "^3.1.10", - "postcss": "^8.1.10", - "postcss-clean": "^1.1.0", - "postcss-safe-parser": "^5.0.2", - "postcss-url": "^10.1.1", "promisepipe": "^3.0.0", "qs": "^6.9.3", "sanitize-html": "^2.3.0", @@ -2290,9 +2294,9 @@ "dev": true }, "@types/react": { - "version": "16.14.2", - "resolved": "https://registry.npmjs.org/@types/react/-/react-16.14.2.tgz", - "integrity": "sha512-BzzcAlyDxXl2nANlabtT4thtvbbnhee8hMmH/CcJrISDBVcJS1iOsP1f0OAgSdGE0MsY9tqcrb9YoZcOFv9dbQ==", + "version": "17.0.0", + "resolved": "https://registry.npmjs.org/@types/react/-/react-17.0.0.tgz", + "integrity": "sha512-aj/L7RIMsRlWML3YB6KZiXB3fV2t41+5RBGYF8z+tAKU43Px8C3cYUZsDvf1/+Bm4FK21QWBrDutu8ZJ/70qOw==", "requires": { "@types/prop-types": "*", "csstype": "^3.0.2" @@ -6150,11 +6154,6 @@ "whatwg-encoding": "^1.0.5" } }, - "html-escaper": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/html-escaper/-/html-escaper-3.0.0.tgz", - "integrity": "sha512-69CofXDozHqdHDl1BZ3YiFp5rYN1qTwSXIVcBhVcZNkzj1vzx6Sko1nT58mzKip19DbKo8lHR9hf6/XeZ9+s3w==" - }, "htmlparser2": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-6.0.0.tgz", diff --git a/package.json b/package.json index 502c2b9c3..a0341ce4d 100644 --- a/package.json +++ b/package.json @@ -5,8 +5,9 @@ "author": "Lumi Education Jan Philip Schellenberg & Sebastian Rettig GbR ", "main": "build/server/main.js", "dependencies": { + "@lumieducation/h5p-express": "7.0.0-alpha.1", "@lumieducation/h5p-html-exporter": "7.0.0-alpha.1", - "@lumieducation/h5p-server": "6.2.0", + "@lumieducation/h5p-server": "7.0.0-alpha.1", "@lumieducation/xapi-aggregator": "1.0.1-alpha.2", "@sentry/electron": "2.2.0", "@sentry/node": "5.30.0", @@ -17,7 +18,6 @@ "express": "4.17.1", "express-fileupload": "1.2.1", "fs-extra": "9.1.0", - "@lumieducation/h5p-server": "6.2.0", "i18next": "19.8.4", "i18next-fs-backend": "1.0.7", "i18next-http-middleware": "3.0.6", diff --git a/server/src/routes/h5pRoutes.ts b/server/src/routes/h5pRoutes.ts index 2a738c487..4e5b7b15a 100644 --- a/server/src/routes/h5pRoutes.ts +++ b/server/src/routes/h5pRoutes.ts @@ -10,7 +10,7 @@ import * as H5P from '@lumieducation/h5p-server'; import { IRequestWithUser, IRequestWithLanguage -} from '@lumieducation/h5p-server/build/src/adapters/expressTypes'; +} from '@lumieducation/h5p-express'; import HtmlExporter from '@lumieducation/h5p-html-exporter'; diff --git a/server/src/routes/index.ts b/server/src/routes/index.ts index cde66d62c..d9bf1169a 100644 --- a/server/src/routes/index.ts +++ b/server/src/routes/index.ts @@ -1,8 +1,10 @@ import express from 'express'; import { H5PEditor, H5PPlayer } from '@lumieducation/h5p-server'; -import h5pAjaxExpressRouter from '@lumieducation/h5p-server/build/src/adapters/H5PAjaxRouter/H5PAjaxExpressRouter'; -import libraryAdministrationExpressRouter from '@lumieducation/h5p-server/build/src/adapters/LibraryAdministrationRouter/LibraryAdministrationExpressRouter'; -import contentTypeCacheExpressRouter from '@lumieducation/h5p-server/build/src/adapters/ContentTypeCacheRouter/ContentTypeCacheExpressRouter'; +import { + h5pAjaxExpressRouter, + libraryAdministrationExpressRouter, + contentTypeCacheExpressRouter +} from '@lumieducation/h5p-express'; // import h5pConfig from '../../config/h5pConfig'; import lumiRoutes from './lumiRoutes';