braft-convert
Advanced tools
Comparing version 2.1.4 to 2.1.5
@@ -489,8 +489,12 @@ "use strict"; | ||
newStyle = newStyle.add('FONTSIZE-' + unitImportFn(node.style.fontSize, 'font-size', source)); | ||
} else if (nodeName === 'span' && style === 'line-height') { | ||
} else if (nodeName === 'span' && style === 'line-height' && !isNaN(parseFloat(node.style.lineHeight, 10))) { | ||
newStyle = newStyle.add('LINEHEIGHT-' + unitImportFn(node.style.lineHeight, 'line-height', source)); | ||
} else if (nodeName === 'span' && style === 'letter-spacing' && !isNaN(node.style.letterSpacing.replace('px', ''))) { | ||
} else if (nodeName === 'span' && style === 'letter-spacing' && !isNaN(parseFloat(node.style.letterSpacing, 10))) { | ||
newStyle = newStyle.add('LETTERSPACING-' + unitImportFn(node.style.letterSpacing, 'letter-spacing', source)); | ||
} else if (nodeName === 'span' && style === 'text-decoration' && node.style.textDecoration === 'line-through') { | ||
newStyle = newStyle.add('STRIKETHROUGH'); | ||
} else if (nodeName === 'span' && style === 'text-decoration') { | ||
if (node.style.textDecoration === 'line-through') { | ||
newStyle = newStyle.add('STRIKETHROUGH'); | ||
} else if (node.style.textDecoration === 'underline') { | ||
newStyle = newStyle.add('UNDERLINE'); | ||
} | ||
} else if (nodeName === 'span' && style === 'font-family') { | ||
@@ -526,2 +530,4 @@ var fontFamily = options.fontFamilies.find(function (item) { | ||
nodeName = nodeName.toLowerCase(); | ||
var alt = node.alt, | ||
@@ -528,0 +534,0 @@ title = node.title, |
{ | ||
"name": "braft-convert", | ||
"version": "2.1.4", | ||
"version": "2.1.5", | ||
"description": "A convert helper for Braft Editor.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
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
66329
638
2549