|
|
|
@ -1,12 +1,13 @@
|
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" viewbox="0 0 <?php echo $width ?> <?php echo $height ?>" width="<?php echo $width ?>" height="<?php echo $height ?>"> |
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" |
|
|
|
|
viewbox="0 0 [(#SVG{margin_left}|width)] [(#SVG{header_height}|height)]" |
|
|
|
|
width="[(#SVG{margin_left}|width)]" |
|
|
|
|
height="[(#SVG{header_height}|height)]" |
|
|
|
|
> |
|
|
|
|
<style type="text/css"> |
|
|
|
|
<![CDATA[ |
|
|
|
|
@import url(/fonts/Fira/fira.css); |
|
|
|
|
|
|
|
|
|
text { |
|
|
|
|
fill: #333; |
|
|
|
|
font-family: "Fira Sans", "Source Sans Pro", Helvetica, Arial, sans-serif; |
|
|
|
|
font-size: <?php echo (2 / 3) * $header_height; ?>px; |
|
|
|
|
[font-size: (#SVG{header_height}|mult{2}|div{3})px;] |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
g.eol rect, |
|
|
|
@ -28,6 +29,11 @@
|
|
|
|
|
fill: #9c9; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
g.future rect, |
|
|
|
|
.branches rect.future { |
|
|
|
|
fill: #c15e92; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.branch-labels text { |
|
|
|
|
dominant-baseline: central; |
|
|
|
|
text-anchor: middle; |
|
|
|
@ -54,50 +60,24 @@
|
|
|
|
|
]]> |
|
|
|
|
</style> |
|
|
|
|
|
|
|
|
|
<!-- Branch labels --> |
|
|
|
|
<g class="branch-labels"> |
|
|
|
|
<?php foreach ($branches as $branch => $version): ?> |
|
|
|
|
<g class="<?php echo get_branch_support_state($branch) ?>"> |
|
|
|
|
<rect x="0" y="<?php echo $version['top'] ?>" width="<?php echo 0.5 * $margin_left ?>" height="<?php echo $branch_height ?>" /> |
|
|
|
|
<text x="<?php echo 0.25 * $margin_left ?>" y="<?php echo $version['top'] + (0.5 * $branch_height) ?>"> |
|
|
|
|
<?php echo htmlspecialchars($branch) ?> |
|
|
|
|
</text> |
|
|
|
|
</g> |
|
|
|
|
<?php endforeach ?> |
|
|
|
|
</g> |
|
|
|
|
<!-- Branch labels --> |
|
|
|
|
<g class="branch-labels"> |
|
|
|
|
<BOUCLE_active_branches(DATA){source json, #CHEMIN{data/releases.json}}>[(#EOL|>={#DATE}|ou{#EOL|intval|non}) |
|
|
|
|
<g[ class="(#VALEUR|state)"]"> |
|
|
|
|
<rect x="0" y="[(#BRANCH|top)]" width="[(#SVG{margin_left}|mult{0.5})]" height="#SVG{branch_height}" /> |
|
|
|
|
<text x="[(#SVG{margin_left}|mult{0.25})]" y="[(#BRANCH|top|top_for_text)]"> |
|
|
|
|
#BRANCH |
|
|
|
|
</text> |
|
|
|
|
</g>] |
|
|
|
|
</BOUCLE_active_branches> |
|
|
|
|
</g> |
|
|
|
|
|
|
|
|
|
<!-- Branch blocks --> |
|
|
|
|
<g class="branches"> |
|
|
|
|
<?php foreach ($branches as $branch => $version): ?> |
|
|
|
|
<?php |
|
|
|
|
$x_release = date_horiz_coord(get_branch_release_date($branch)); |
|
|
|
|
$x_bug = date_horiz_coord(get_branch_bug_eol_date($branch)); |
|
|
|
|
$x_eol = date_horiz_coord(get_branch_security_eol_date($branch)); |
|
|
|
|
?> |
|
|
|
|
<rect class="stable" x="<?php echo $x_release ?>" y="<?php echo $version['top'] ?>" width="<?php echo $x_bug - $x_release ?>" height="<?php echo $branch_height ?>" /> |
|
|
|
|
<rect class="security" x="<?php echo $x_bug ?>" y="<?php echo $version['top'] ?>" width="<?php echo $x_eol - $x_bug ?>" height="<?php echo $branch_height ?>" /> |
|
|
|
|
<?php endforeach ?> |
|
|
|
|
<BOUCLE_active_branches_2(DATA){source json, #CHEMIN{data/releases.json}}>[(#EOL|>={#DATE}|ou{#EOL|intval|non}) |
|
|
|
|
<rect class="stable" x="[(#INITIAL_RELEASE|horiz_coord)]" y="[(#BRANCH|top)]" width="[(#ACTIVE_SUPPORT|horiz_coord|moins{#INITIAL_RELEASE|horiz_coord})]" height="#SVG{branch_height}" /> |
|
|
|
|
<rect class="security" x="[(#ACTIVE_SUPPORT|horiz_coord)]" y="[(#BRANCH|top)]" width="[(#EOL|horiz_coord|moins{#ACTIVE_SUPPORT|horiz_coord})]" height="#SVG{branch_height}" />] |
|
|
|
|
</BOUCLE_active_branches_2> |
|
|
|
|
</g> |
|
|
|
|
|
|
|
|
|
<!-- Year lines --> |
|
|
|
|
<g class="years"> |
|
|
|
|
<?php foreach ($years as $date): ?> |
|
|
|
|
<line x1="<?php echo date_horiz_coord($date) ?>" y1="<?php echo $header_height ?>" x2="<?php echo date_horiz_coord($date) ?>" y2="<?php echo $header_height + (count($branches) * $branch_height) ?>" /> |
|
|
|
|
<text x="<?php echo date_horiz_coord($date) ?>" y="<?php echo 0.8 * $header_height; ?>"> |
|
|
|
|
<?php echo $date->format('j M Y') ?> |
|
|
|
|
</text> |
|
|
|
|
<?php endforeach ?> |
|
|
|
|
</g> |
|
|
|
|
|
|
|
|
|
<!-- Today --> |
|
|
|
|
<g class="today"> |
|
|
|
|
<?php |
|
|
|
|
$now = new DateTime; |
|
|
|
|
$x = date_horiz_coord($now); |
|
|
|
|
?> |
|
|
|
|
<line x1="<?php echo $x ?>" y1="<?php echo $header_height ?>" x2="<?php echo $x ?>" y2="<?php echo $header_height + (count($branches) * $branch_height) ?>" /> |
|
|
|
|
<text x="<?php echo $x ?>" y="<?php echo $header_height + (count($branches) * $branch_height) + (0.8 * $footer_height) ?>"> |
|
|
|
|
<?php echo 'Today: '.$now->format('j M Y') ?> |
|
|
|
|
</text> |
|
|
|
|
</g> |
|
|
|
|
</svg> |
|
|
|
|