remy / inliner

Node utility to inline images, CSS and JavaScript for a web page - useful for mobile sites
MIT License
1.1k stars 165 forks source link

"zoom: ;" added to the body element #32

Closed jamesplease closed 9 years ago

jamesplease commented 11 years ago

Inlining my HTML documents adds a property I did not specify to the body element of my page: zoom: ;

Here's my set up:

index.html

<html>
<head>
  <link rel="stylesheet" href="style.css">
</head>
<body>
  <p>Test</p>
</body>
</html>

style.css

p {
  margin: 2px;
}

output.html

<!DOCTYPE html><html> <head> <style>p{ margin:2px;}</style> </head> <body style="zoom: ;"> <p>Test</p> </body> </html>

I'm using the CLI to generate my file. Specifically, the command inliner index.html > output.html. The console outputs path.existsSync is now called 'fs.existsSync'. when I run the command.

I perused the source here on Github, but nothing struck me as a potential cause for this behavior.

If it's a feature, and not a bug, it seems like strange behavior for an inliner tool. I'd expect it to to simply inline the css and not add anything itself.

Consequences of the issue is that the resultant HTML might break further processes done to the HTML. One such example is juice, which won't allow you to modify the body once it has the zoom property set by inliner.

remy commented 9 years ago

This should be fixed @ 1.0.0.

jamesplease commented 9 years ago

:open_mouth: :+1: