|
33 | 33 | stroke-width: 0.8px; |
34 | 34 | opacity: 75%; |
35 | 35 | } |
36 | | - .release-cycle-year-text { |
37 | | - fill: var(--svg-color-foreground-primary); |
38 | | - } |
39 | 36 | .release-cycle-today-line { |
40 | 37 | stroke: var(--svg-color-brand-primary); |
41 | 38 | stroke-width: var(--blob-border-width); |
|
44 | 41 | fill: var(--svg-color-background-item); |
45 | 42 | opacity: 50%; |
46 | 43 | } |
47 | | - .release-cycle-version-label { |
48 | | - fill: var(--svg-color-foreground-primary); |
49 | | - } |
50 | 44 | .release-cycle-blob { |
51 | 45 | stroke-width: var(--blob-border-width); |
52 | 46 | } |
53 | | - text { |
| 47 | + .text-main { |
54 | 48 | fill: var(--svg-color-foreground-primary); |
55 | 49 |
|
| 50 | + /* use specific colours on known backgrounds */ |
| 51 | + &.release-cycle-status-security, |
| 52 | + &.release-cycle-status-bugfix { |
| 53 | + fill: black; |
| 54 | + } |
| 55 | + } |
| 56 | + .text-outline { |
56 | 57 | /* an outline of the background color, in case it's not set |
57 | | - correctly */ |
| 58 | + correctly */ |
| 59 | + fill: transparent; |
58 | 60 | stroke: var(--svg-color-background-primary); |
59 | 61 | stroke-width: var(--blob-border-width); |
60 | | - /* draw stroke first (half of it will be visible as outline) */ |
61 | | - paint-order: stroke; |
62 | 62 |
|
63 | 63 | /* use specific colours on known backgrounds */ |
64 | | - &.release-cycle-status-security , |
| 64 | + &.release-cycle-status-security, |
65 | 65 | &.release-cycle-status-bugfix { |
66 | | - fill: black; |
67 | 66 | stroke: var(--status-bg-color); |
68 | 67 | } |
69 | | - /* For year labels, keep outline below the row shading |
70 | | - (it's a separate element) */ |
71 | | - &.release-cycle-version-label-outline { |
72 | | - fill: transparent; |
73 | | - } |
74 | | - &.release-cycle-version-label { |
75 | | - stroke: none; |
76 | | - } |
77 | 68 | } |
78 | 69 | .release-cycle-status-end-of-life { |
79 | 70 | --status-bg-color: #DD2200; |
|
120 | 111 | {% set y = version.y * line_height %} |
121 | 112 | <!-- Outline for legend on the left --> |
122 | 113 | <text |
123 | | - class="release-cycle-version-label-outline" |
| 114 | + class="release-cycle-version-label text-outline" |
124 | 115 | x="{{ 0.5 * SCALE }}" |
125 | 116 | y="{{ version.y * line_height }}" |
126 | 117 | font-size="{{ SCALE }}" |
|
141 | 132 | {% endfor %} |
142 | 133 |
|
143 | 134 | {% for year in years %} |
144 | | - <text |
145 | | - class="release-cycle-year-text" |
146 | | - x="{{ (year_to_x(year) + year_to_x(year + 1)) / 2 }}" |
147 | | - y="{{ diagram_height - line_height }}" |
148 | | - font-size="{{ SCALE * 0.75 }}" |
149 | | - text-anchor="middle" |
150 | | - > |
151 | | - {{ format_year(year) }} |
152 | | - </text> |
| 135 | + {% for cls in ('text-outline', 'text-main') %} |
| 136 | + <text |
| 137 | + class="release-cycle-year-text {{cls}}" |
| 138 | + x="{{ (year_to_x(year) + year_to_x(year + 1)) / 2 }}" |
| 139 | + y="{{ diagram_height - line_height }}" |
| 140 | + font-size="{{ SCALE * 0.75 }}" |
| 141 | + text-anchor="middle" |
| 142 | + > |
| 143 | + {{ format_year(year) }} |
| 144 | + </text> |
| 145 | + {% endfor %} |
153 | 146 | {% if not loop.last %} |
154 | 147 | <line |
155 | 148 | class="release-cycle-year-line" |
|
284 | 277 | {% set small_text_y = version.y * line_height - 0.1 * SCALE %} |
285 | 278 |
|
286 | 279 | <!-- Add text before/after/inside the blob --> |
287 | | - <text |
288 | | - class="release-cycle-blob-label release-cycle-status-{{ version.status }}" |
289 | | - font-size="{{ SCALE * 0.75 }}" |
290 | | - y="{{ small_text_y }}" |
291 | | - {% if version.status == "bugfix" %} |
292 | | - x="{{ (start_x + middle_x) / 2 }}" |
293 | | - text-anchor="middle" |
294 | | - {% elif version.status == "security" %} |
295 | | - x="{{ (middle_x + end_x) / 2 }}" |
296 | | - text-anchor="middle" |
297 | | - {% elif version.status == "end-of-life" %} |
298 | | - x="{{ end_x + (0.25 * SCALE) }}" |
299 | | - text-anchor="start" |
300 | | - {% else %} |
301 | | - x="{{ start_x - (0.25 * SCALE) }}" |
302 | | - text-anchor="end" |
303 | | - {% endif %} |
304 | | - > |
305 | | - {{ version.status }} |
306 | | - </text> |
| 280 | + {% for cls in ('text-outline', 'text-main') %} |
| 281 | + <text |
| 282 | + class="release-cycle-blob-label {{cls}} release-cycle-status-{{ version.status }}" |
| 283 | + font-size="{{ SCALE * 0.75 }}" |
| 284 | + y="{{ small_text_y }}" |
| 285 | + {% if version.status == "bugfix" %} |
| 286 | + x="{{ (start_x + middle_x) / 2 }}" |
| 287 | + text-anchor="middle" |
| 288 | + {% elif version.status == "security" %} |
| 289 | + x="{{ (middle_x + end_x) / 2 }}" |
| 290 | + text-anchor="middle" |
| 291 | + {% elif version.status == "end-of-life" %} |
| 292 | + x="{{ end_x + (0.25 * SCALE) }}" |
| 293 | + text-anchor="start" |
| 294 | + {% else %} |
| 295 | + x="{{ start_x - (0.25 * SCALE) }}" |
| 296 | + text-anchor="end" |
| 297 | + {% endif %} |
| 298 | + > |
| 299 | + {{ version.status }} |
| 300 | + </text> |
| 301 | + {% endfor %} |
307 | 302 |
|
308 | 303 | <!-- Legend on the left --> |
309 | 304 | <text |
310 | | - class="release-cycle-version-label" |
| 305 | + class="release-cycle-version-label text-main" |
311 | 306 | x="{{ 0.5 * SCALE }}" |
312 | 307 | y="{{ version.y * line_height }}" |
313 | 308 | font-size="{{ SCALE }}" |
|
0 commit comments