How to save conditional comments in the <html> element in the Diazo theme?

I have a Diazo theme file based on html5boilerplate . A theme uses conditional comments on an element <html>to identify certain versions of Internet Explorer, for example.

<!doctype html>
<!--[if lt IE 7]> <html class="no-js ie6 oldie" lang="en"> <![endif]-->
<!--[if IE 7]>    <html class="no-js ie7 oldie" lang="en"> <![endif]-->
<!--[if IE 8]>    <html class="no-js ie8 oldie" lang="en"> <![endif]-->
<!-- Consider adding an manifest.appcache: h5bp.com/d/Offline -->
<!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->

However, when the theme is applied, Diazo seems to drop these conditional comments and only the last

<!--<![endif]-->

stays in the final markup, producing something like

<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" class="no-js" lang="en" xml:lang="en"><!--<![endif]-->

with unrivaled endif. Using conditional comments in a tag <html>(for example, inside <head>or below in a document) works fine.

Examples of theme files and rules that have this problem are available at

https://github.com/hexagonit/hexagonit.themeskel/blob/master/hexagonit/themeskel/templates/less_theme/+namespace_package+/+package+/theme_resources

plone.app.theming 1.0b8 KGS good-py.

+5
2

, , Plone Diazo.

+2

<body>, Diazo body Plone, <= IE8.

<merge attributes="class" css:theme="body" css:content="body" />

, div, .

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <link rel="stylesheet" href="css/style.css">
  <title>Title</title>

</head>
<body>
  <!--[if lt IE 7]> <div class="no-js ie6 oldie"> <![endif]-->
  <!--[if IE 7]> <div class="no-jsie7 oldie"> <![endif]-->
  <!--[if IE 8]> <div class="no-js ie8 oldie"> <![endif]-->
  <!--[if gt IE 8]><!--> <div class="no-js"> <!--<![endif]-->

    <div id="content"></div>

  </div><!-- Browser Detection -->
</body>
</html>

Plone html, .

0

All Articles