Commit 3981e134 authored by Akikonata's avatar Akikonata

Merge branch 'dev' of https://github.com/fex-team/kityminder into dev

parents 4221a600 3cd04eb6
......@@ -179,7 +179,7 @@ $( function () {
// 检查 URL 是否分享连接,是则加载分享内容
function loadShare() {
var pattern = /shareId=(\w+)([&#]|$)/;
var pattern = /(?:shareId|share_id)=(\w+)([&#]|$)/;
var match = pattern.exec( window.location ) || pattern.exec( document.referrer );
if ( !match ) return;
......
......@@ -31,8 +31,6 @@ KityMinder.registerProtocal( "png", function () {
renderContainer.translate( -renderBox.x, -renderBox.y );
svgXml = km.getPaper().container.innerHTML;
// svg 含有   符号导出报错 Entity 'nbsp' not defined
svgXml = svgXml.replace(/ /g, ' ').replace(/\s+/g, ' ');
renderContainer.translate( renderBox.x, renderBox.y );
......@@ -46,6 +44,9 @@ KityMinder.registerProtocal( "png", function () {
// need a xml with width and height
svgXml = $( '<div></div' ).append( $svg ).html();
// svg 含有 &nbsp; 符号导出报错 Entity 'nbsp' not defined
svgXml = svgXml.replace(/&nbsp;/g, '&#xa0;');
blob = new Blob( [ svgXml ], {
type: "image/svg+xml;charset=utf-8"
} );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment