Update dependency versions
This commit is contained in:
parent
7f622103a1
commit
787f4c5299
|
@ -11006,7 +11006,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const fs = require('fs');
|
|
||||||
const opentype = require('opentype.js');
|
const opentype = require('opentype.js');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
|
|
||||||
|
@ -11016,9 +11015,8 @@
|
||||||
function loadFont(relativePath) {
|
function loadFont(relativePath) {
|
||||||
// Must be synchronous so that measurements are ready once startup completes
|
// Must be synchronous so that measurements are ready once startup completes
|
||||||
/* eslint-disable no-sync */
|
/* eslint-disable no-sync */
|
||||||
const data = fs.readFileSync(path.join(FONTDIR, relativePath));
|
return opentype.loadSync(path.join(FONTDIR, relativePath));
|
||||||
/* eslint-enable no-sync */
|
/* eslint-enable no-sync */
|
||||||
return opentype.parse(data.buffer);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function addFont(name, variants) {
|
function addFont(name, variants) {
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
17
package.json
17
package.json
|
@ -29,7 +29,6 @@
|
||||||
"ephemeral",
|
"ephemeral",
|
||||||
"*FontData.mjs"
|
"*FontData.mjs"
|
||||||
],
|
],
|
||||||
|
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"copy-third-party": "cat node_modules/codemirror/lib/codemirror.css node_modules/codemirror/addon/hint/show-hint.css > web/lib/codemirror.css && uglifyjs --compress --mangle --output web/lib/codemirror.js -- node_modules/codemirror/lib/codemirror.js && uglifyjs --compress --mangle --output web/lib/show-hint.js -- node_modules/codemirror/addon/hint/show-hint.js && uglifyjs --compress --mangle --output web/lib/trailingspace.js -- node_modules/codemirror/addon/edit/trailingspace.js && uglifyjs --compress --mangle --output web/lib/comment.js -- node_modules/codemirror/addon/comment/comment.js && cat node_modules/codemirror/mode/xml/xml.js node_modules/codemirror/mode/javascript/javascript.js node_modules/codemirror/addon/runmode/runmode.js node_modules/codemirror/addon/runmode/colorize.js | uglifyjs --compress --mangle --output web/lib/cm-addons-library.js && uglifyjs --compress --mangle --warn --output web/lib/require.js -- node_modules/requirejs/require.js",
|
"copy-third-party": "cat node_modules/codemirror/lib/codemirror.css node_modules/codemirror/addon/hint/show-hint.css > web/lib/codemirror.css && uglifyjs --compress --mangle --output web/lib/codemirror.js -- node_modules/codemirror/lib/codemirror.js && uglifyjs --compress --mangle --output web/lib/show-hint.js -- node_modules/codemirror/addon/hint/show-hint.js && uglifyjs --compress --mangle --output web/lib/trailingspace.js -- node_modules/codemirror/addon/edit/trailingspace.js && uglifyjs --compress --mangle --output web/lib/comment.js -- node_modules/codemirror/addon/comment/comment.js && cat node_modules/codemirror/mode/xml/xml.js node_modules/codemirror/mode/javascript/javascript.js node_modules/codemirror/addon/runmode/runmode.js node_modules/codemirror/addon/runmode/colorize.js | uglifyjs --compress --mangle --output web/lib/cm-addons-library.js && uglifyjs --compress --mangle --warn --output web/lib/require.js -- node_modules/requirejs/require.js",
|
||||||
"lint": "eslint . --config eslintrc.js --ext .js --ext .mjs",
|
"lint": "eslint . --config eslintrc.js --ext .js --ext .mjs",
|
||||||
|
@ -46,26 +45,26 @@
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"buffer-to-stream": "^1.0.0",
|
"buffer-to-stream": "^1.0.0",
|
||||||
"codemirror": "^5.42.2",
|
"codemirror": "^5.47.0",
|
||||||
"eslint": "^5.11.0",
|
"eslint": "^5.16.0",
|
||||||
"eslint-plugin-jasmine": "^2.10.1",
|
"eslint-plugin-jasmine": "^2.10.1",
|
||||||
"jasmine": "^3.3.1",
|
"jasmine": "^3.4.0",
|
||||||
"karma": "^3.1.4",
|
"karma": "^4.1.0",
|
||||||
"karma-chrome-launcher": "^2.2.0",
|
"karma-chrome-launcher": "^2.2.0",
|
||||||
"karma-detect-browsers": "^2.3.3",
|
"karma-detect-browsers": "^2.3.3",
|
||||||
"karma-firefox-launcher": "^1.1.0",
|
"karma-firefox-launcher": "^1.1.0",
|
||||||
"karma-jasmine": "^2.0.1",
|
"karma-jasmine": "^2.0.1",
|
||||||
"karma-safari-launcher": "^1.0.0",
|
"karma-safari-launcher": "^1.0.0",
|
||||||
"pngcrush": "^2.0.0",
|
"pngcrush": "^2.0.1",
|
||||||
"requirejs": "^2.3.6",
|
"requirejs": "^2.3.6",
|
||||||
"rollup": "^0.68.2",
|
"rollup": "^1.15.5",
|
||||||
"rollup-plugin-hypothetical": "^2.1.0",
|
"rollup-plugin-hypothetical": "^2.1.0",
|
||||||
"rollup-plugin-multi-entry": "^2.1.0",
|
"rollup-plugin-multi-entry": "^2.1.0",
|
||||||
"source-map-support": "^0.5.9",
|
"source-map-support": "^0.5.12",
|
||||||
"svg2png": "^4.1.1",
|
"svg2png": "^4.1.1",
|
||||||
"uglify-es": "3.2.2"
|
"uglify-es": "3.2.2"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"opentype.js": "^0.11.0"
|
"opentype.js": "0.12.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@ describe('Browser-backed SequenceDiagram', () => {
|
||||||
expect(sd.getSize().width).toEqual(widthImmediate);
|
expect(sd.getSize().width).toEqual(widthImmediate);
|
||||||
|
|
||||||
done();
|
done();
|
||||||
}, 500);
|
}, 400);
|
||||||
});
|
});
|
||||||
|
|
||||||
it('measures embedded fonts correctly on the first render', (done) => {
|
it('measures embedded fonts correctly on the first render', (done) => {
|
||||||
|
@ -38,6 +38,6 @@ describe('Browser-backed SequenceDiagram', () => {
|
||||||
expect(sd.getSize().width).toEqual(widthImmediate);
|
expect(sd.getSize().width).toEqual(widthImmediate);
|
||||||
|
|
||||||
done();
|
done();
|
||||||
}, 500);
|
}, 400);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
const fs = require('fs');
|
|
||||||
const opentype = require('opentype.js');
|
const opentype = require('opentype.js');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
|
|
||||||
|
@ -8,9 +7,8 @@ const FONTS = new Map();
|
||||||
function loadFont(relativePath) {
|
function loadFont(relativePath) {
|
||||||
// Must be synchronous so that measurements are ready once startup completes
|
// Must be synchronous so that measurements are ready once startup completes
|
||||||
/* eslint-disable no-sync */
|
/* eslint-disable no-sync */
|
||||||
const data = fs.readFileSync(path.join(FONTDIR, relativePath));
|
return opentype.loadSync(path.join(FONTDIR, relativePath));
|
||||||
/* eslint-enable no-sync */
|
/* eslint-enable no-sync */
|
||||||
return opentype.parse(data.buffer);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function addFont(name, variants) {
|
function addFont(name, variants) {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
<svg width="132.474609375" height="150" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="-66.2373046875 -145 132.474609375 150"><metadata>title "
|
<?xml version="1.0" encoding="UTF-8" ?><svg width="132.4654312133789" height="150" xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="-66.23271560668945 -145 132.4654312133789 150"><metadata>title "
|
||||||
Re **Bo** _It_ `Mo` I<sup>2</sup>
|
Re **Bo** _It_ `Mo` I<sup>2</sup>
|
||||||
**_`Comb`_** <u><o>~Strike~</o></u> I<sub>2</sub>
|
**_`Comb`_** <u><o>~Strike~</o></u> I<sub>2</sub>
|
||||||
<highlight>Back</highlight> <red>Text</red> [link](http://www.example.com)
|
<highlight>Back</highlight> <red>Text</red> [link](http://www.example.com)
|
||||||
\<b>esc</b>
|
\<b>esc</b>
|
||||||
\\<b>no-esc</b> 😎
|
\\<b>no-esc</b> 😎
|
||||||
"
|
"
|
||||||
</metadata><defs><filter id="R0highlight"><feMorphology in="SourceAlpha" operator="dilate" radius="4"></feMorphology><feGaussianBlur edgeMode="none" stdDeviation="3, 1.5"></feGaussianBlur><feComponentTransfer><feFuncA intercept="-70" slope="100" type="linear"></feFuncA></feComponentTransfer><feComponentTransfer><feFuncR intercept="1" slope="0" type="linear"></feFuncR><feFuncG intercept="0.875" slope="0" type="linear"></feFuncG><feFuncB intercept="0" slope="0" type="linear"></feFuncB><feFuncA slope="0.8" type="linear"></feFuncA></feComponentTransfer><feMerge><feMergeNode></feMergeNode><feMergeNode in="SourceGraphic"></feMergeNode></feMerge></filter></defs><defs><mask id="R0FullMask" maskUnits="userSpaceOnUse"><rect fill="#FFFFFF" height="150" width="132.474609375" x="-66.2373046875" y="-145"></rect></mask><mask id="R0LineMask" maskUnits="userSpaceOnUse"><rect fill="#FFFFFF" height="150" width="132.474609375" x="-66.2373046875" y="-145"></rect></mask></defs><g></g><g><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-120">Re <tspan font-weight="bolder">Bo</tspan> <tspan font-style="italic">It</tspan> <tspan font-family="Courier New,Liberation Mono,monospace">Mo</tspan> I<tspan baseline-shift="70%" font-size="0.6em">2</tspan></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-94"><tspan font-style="italic" font-weight="bolder" font-family="Courier New,Liberation Mono,monospace">Comb</tspan> <tspan text-decoration="line-through overline underline">Strike</tspan> I<tspan baseline-shift="-20%" font-size="0.6em">2</tspan></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-68"><tspan filter="url(#R0highlight)">Back</tspan> <tspan fill="#DD0000">Text</tspan> <a cursor="pointer" rel="nofollow" target="_blank" href="http://www.example.com" text-decoration="underline">link</a></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-42"><b>esc</b></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-16">\<tspan font-weight="bolder">no-esc</tspan> 😎</text></g><g></g><g mask="url(#R0FullMask)"><g mask="url(#R0LineMask)"></g><g></g><g></g></g></svg>
|
</metadata><defs><filter id="R0highlight"><feMorphology in="SourceAlpha" operator="dilate" radius="4"></feMorphology><feGaussianBlur edgeMode="none" stdDeviation="3, 1.5"></feGaussianBlur><feComponentTransfer><feFuncA intercept="-70" slope="100" type="linear"></feFuncA></feComponentTransfer><feComponentTransfer><feFuncR intercept="1" slope="0" type="linear"></feFuncR><feFuncG intercept="0.875" slope="0" type="linear"></feFuncG><feFuncB intercept="0" slope="0" type="linear"></feFuncB><feFuncA slope="0.8" type="linear"></feFuncA></feComponentTransfer><feMerge><feMergeNode></feMergeNode><feMergeNode in="SourceGraphic"></feMergeNode></feMerge></filter></defs><defs><mask id="R0FullMask" maskUnits="userSpaceOnUse"><rect fill="#FFFFFF" height="150" width="132.4654312133789" x="-66.23271560668945" y="-145"></rect></mask><mask id="R0LineMask" maskUnits="userSpaceOnUse"><rect fill="#FFFFFF" height="150" width="132.4654312133789" x="-66.23271560668945" y="-145"></rect></mask></defs><g></g><g><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-120">Re <tspan font-weight="bolder">Bo</tspan> <tspan font-style="italic">It</tspan> <tspan font-family="Courier New,Liberation Mono,monospace">Mo</tspan> I<tspan baseline-shift="70%" font-size="0.6em">2</tspan></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-94"><tspan font-style="italic" font-weight="bolder" font-family="Courier New,Liberation Mono,monospace">Comb</tspan> <tspan text-decoration="line-through overline underline">Strike</tspan> I<tspan baseline-shift="-20%" font-size="0.6em">2</tspan></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-68"><tspan filter="url(#R0highlight)">Back</tspan> <tspan fill="#DD0000">Text</tspan> <a cursor="pointer" rel="nofollow" target="_blank" href="http://www.example.com" text-decoration="underline">link</a></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-42"><b>esc</b></text><text x="0" class="title" font-family="Helvetica,Arial,Liberation Sans,sans-serif" font-size="20" line-height="1.3" text-anchor="middle" y="-16">\<tspan font-weight="bolder">no-esc</tspan> 😎</text></g><g></g><g mask="url(#R0FullMask)"><g mask="url(#R0LineMask)"></g><g></g><g></g></g></svg>
|
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 3.0 KiB |
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue