<html>
<head>
    <title>Unit coverage summary</title>
    <style lang="css">
        html, body {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
            line-height: 1.6;
            font-size: 16px;
            font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
            -ms-text-size-adjust: 100%;
            -webkit-text-size-adjust: 100%;
            color: #333
        }

        #content {
            margin: 0 auto;
            padding: 30px 0
        }

        h1, h2, h3, h4, h5, h6 {
            margin-top: 50px;
            margin-bottom: 15px;
            line-height: 1.1
        }

        h1, h2 {
            font-size: 30px
        }

        h3 {
            font-size: 21px
        }

        table {
            display: block;
            width: 100%;
            overflow: auto;
            word-break: normal;
            word-break: keep-all
        }

        table th {
            font-weight: bold;
            text-align: left
        }

        table th, table td {
            padding: 6px 26px 6px 13px;
            border: 1px solid #ddd
        }

        table tr {
            background-color: #fff;
            border-top: 1px solid #ccc
        }

        table tr:nth-child(2n) {
            background-color: #f8f8f8
        }
    </style>
</head>
<body>
<div id='content'>

    {%- for phpModule, phpCoverage in data.php -%}
        <h2>{{ phpModule }} PHP Coverage per area</h2>
            <table borders="0">
            <tr>
                <th>Area</th>
                <th>Covered lines</th>
                <th>Valid lines</th>
                <th>%</th>
            </tr>
            {%- for c in phpCoverage -%}
                <tr>
                    <td>{{ c.area }}</td>
                    <td>{{ c.coveredLines }}</td>
                    <td>{{ c.validLines }}</td>
                    <td>{{ c.percentage }}</td>
                </tr>
            {%- endfor -%}
        </table>
    {%- endfor -%}

    {%- for jsModule, jsCoverage in data.js -%}
        <h2>{{ jsModule }} javascript coverage per area</h2>
        <table borders="0">
            <tr>
                <th>Area</th>
                <th>Covered lines</th>
                <th>Valid lines</th>
                <th>%</th>
            </tr>
            {%- for c in jsCoverage -%}
                <tr>
                    <td>{{ c.area }}</td>
                    <td>{{ c.coveredLines }}</td>
                    <td>{{ c.validLines }}</td>
                    <td>{{ c.percentage }}</td>
                </tr>
            {%- endfor -%}
        </table>
    {%- endfor -%}
</div>
</body>
</html>
