@tryghost/kg-parser-plugins
Advanced tools
Comparing version 4.0.1 to 4.0.2
'use strict'; | ||
Object.defineProperty(exports, '__esModule', { value: true }); | ||
var cleanBasicHtml = require('@tryghost/kg-clean-basic-html'); | ||
@@ -842,4 +840,12 @@ | ||
/* global DOMParser, window */ | ||
/** | ||
* Copied from: | ||
* https://github.com/TryGhost/Ghost-Admin/blob/1f3d77d7230dd47a7eb5f38b90dfa510b2a16801/lib/koenig-editor/addon/options/parser-plugins.js | ||
* Which makes use of: | ||
* https://github.com/TryGhost/Ghost-Admin/blob/1f3d77d7230dd47a7eb5f38b90dfa510b2a16801/lib/koenig-editor/addon/helpers/clean-basic-html.js | ||
* | ||
* These functions are used to proces nodes during parsing from DOM -> mobiledoc | ||
*/ | ||
function createParserPlugins(_options = {}) { | ||
@@ -853,2 +859,3 @@ const defaults = {}; | ||
if (!Parser) { | ||
// eslint-disable-next-line ghost/ghost-custom/no-native-error | ||
throw new Error('createParserPlugins() must be passed a `createDocument` function as an option when used in a non-browser environment'); | ||
@@ -1146,1 +1153,2 @@ } | ||
exports.createParserPlugins = createParserPlugins; | ||
//# sourceMappingURL=parser-plugins.js.map |
@@ -797,3 +797,11 @@ import cleanBasicHtml from '@tryghost/kg-clean-basic-html'; | ||
/* global DOMParser, window */ | ||
/** | ||
* Copied from: | ||
* https://github.com/TryGhost/Ghost-Admin/blob/1f3d77d7230dd47a7eb5f38b90dfa510b2a16801/lib/koenig-editor/addon/options/parser-plugins.js | ||
* Which makes use of: | ||
* https://github.com/TryGhost/Ghost-Admin/blob/1f3d77d7230dd47a7eb5f38b90dfa510b2a16801/lib/koenig-editor/addon/helpers/clean-basic-html.js | ||
* | ||
* These functions are used to proces nodes during parsing from DOM -> mobiledoc | ||
*/ | ||
function createParserPlugins(_options = {}) { | ||
@@ -805,2 +813,3 @@ const defaults = {}; | ||
if (!Parser) { | ||
// eslint-disable-next-line ghost/ghost-custom/no-native-error | ||
throw new Error('createParserPlugins() must be passed a `createDocument` function as an option when used in a non-browser environment'); | ||
@@ -807,0 +816,0 @@ } |
@@ -1,3 +0,1 @@ | ||
/* global DOMParser, window */ | ||
/** | ||
@@ -22,3 +20,3 @@ * Copied from: | ||
import * as productCard from './cards/product'; | ||
import * as softReturn from './cards/softReturn'; | ||
import * as softReturn from './cards/soft-return'; | ||
import * as videoCard from './cards/video'; | ||
@@ -35,2 +33,3 @@ import * as galleryCard from './cards/gallery'; | ||
if (!Parser) { | ||
// eslint-disable-next-line ghost/ghost-custom/no-native-error | ||
throw new Error('createParserPlugins() must be passed a `createDocument` function as an option when used in a non-browser environment'); | ||
@@ -37,0 +36,0 @@ } |
{ | ||
"name": "@tryghost/kg-parser-plugins", | ||
"version": "4.0.1", | ||
"version": "4.0.2", | ||
"repository": "https://github.com/TryGhost/Koenig/tree/master/packages/kg-parser-plugins", | ||
@@ -33,4 +33,4 @@ "author": "Ghost Foundation", | ||
"devDependencies": { | ||
"@babel/core": "7.23.6", | ||
"@babel/preset-env": "7.23.6", | ||
"@babel/core": "7.23.7", | ||
"@babel/preset-env": "7.23.7", | ||
"@rollup/plugin-babel": "6.0.4", | ||
@@ -41,3 +41,3 @@ "@tryghost/mobiledoc-kit": "0.11.2-ghost.4", | ||
"mocha": "10.2.0", | ||
"rollup": "2.79.1", | ||
"rollup": "4.9.2", | ||
"should": "13.2.3", | ||
@@ -47,5 +47,5 @@ "sinon": "17.0.1" | ||
"dependencies": { | ||
"@tryghost/kg-clean-basic-html": "^4.0.1" | ||
"@tryghost/kg-clean-basic-html": "^4.0.2" | ||
}, | ||
"gitHead": "e115cc9c15eded078e81799e7b9a88e56e9cc130" | ||
"gitHead": "1f8ced86f538ecbd1394b52135d30ecd71a4ad96" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
269182
20
2879