File size: 4,492 Bytes
76a7a50
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
.jqplot-target {
    color: @theme-color-text;
}

.jqplot-loading {
    background-color: @theme-color-background-contrast;
}

a.rowevolution-startmulti {
    color: @theme-color-link !important;
}

.rowevolution table.metrics td.text {
    color: @theme-color-text-light;
}

.rowevolution table.metrics td.text span.details,
.rowevolution .metric-selectbox select {
    color: @theme-color-text;
}

.piwik-graph {
    height: 250px;
}

.jqplot-legend-footer {
    display: none;
}

.jqplot-legend-footer.has-legend,
.jqplot-legend-footer.has-picker {
    // Used by jqplot.js to match the exported image legend layout.
    --jqplot-legend-footer-height: 38px;
    --jqplot-legend-swatch-size: 12px;
    --jqplot-legend-item-gap: 8px;
    --jqplot-legend-row-gap: 24px;
    --jqplot-legend-line-gap: 6px;
    --jqplot-legend-horizontal-padding: 12px;

    height: var(--jqplot-legend-footer-height);
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 10px;
}

// Pie graphs already label their slices via the in-chart pieLegend, so the footer
// legend (a single-metric row) is redundant. Hide just the legend items and keep the
// footer (and its "Choose metrics" picker, which is how the displayed metric is switched).
.dataTableVizPie .jqplot-legend-footer .jqplot-legend-items {
    display: none;
}

// When evolution annotations are shown they sit above the legend footer and add
// their own spacing, so drop the default margin to avoid doubling the gap.
.evolution-annotations ~ .jqplot-legend-footer {
    margin-top: 0;
}

.jqplot-legend-picker {
    display: flex;
    align-items: center;
    flex: none;
}

.jqplot-legend-items {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    align-content: safe center;
    gap: var(--jqplot-legend-line-gap) var(--jqplot-legend-row-gap);
    height: var(--jqplot-legend-footer-height);
    overflow: hidden;
    flex: auto;
}

// One row stays centered (rule above); once the legend wraps to two rows, left-align it —
// but only in the wide layout. The narrow/stacked layout (.is-narrow) keeps it centered.
// Left-aligned, the legend butts up against the "Choose metrics" picker, so add a gap between them.
.jqplot-legend-footer.is-multi-row:not(.is-narrow) .jqplot-legend-items {
    justify-content: flex-start;
    margin-left: 18px;
}

.jqplot-legend-item {
    display: inline-flex;
    align-items: center;
    gap: var(--jqplot-legend-item-gap);
    max-width: 100%;
    min-width: 0;
}

.jqplot-legend-item.jqplot-legend-item-hidden {
    display: none;
}

.jqplot-legend-swatch {
    width: var(--jqplot-legend-swatch-size);
    height: var(--jqplot-legend-swatch-size);
    min-width: var(--jqplot-legend-swatch-size);
    border-radius: 50%;
    flex: none;
}

.jqplot-legend-label {
    color: @theme-color-text-lighter;
    font-size: 12px;
    line-height: 16px;
    min-width: 0;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

// When the report itself is narrow — its own width, not the viewport, so this also applies
// to reports shown as narrow dashboard widgets — the "Choose metrics" button and the legend
// can't sit side by side, so stack them: the legend keeps its row(s) on top and the picker
// drops onto its own full-width line below. jqplot.js measures the footer width and toggles
// `is-narrow` (a stand-in for a CSS container query, which less.php can't compile).
.jqplot-legend-footer.is-narrow {
    height: auto;
    flex-direction: column;
    align-items: stretch;
    gap: var(--jqplot-legend-line-gap);
}

.jqplot-legend-footer.is-narrow .jqplot-legend-items {
    order: 1;
}

.jqplot-legend-footer.is-narrow .jqplot-legend-picker {
    order: 2;
    display: block;
    width: 100%;
}

.dataTableVizEvolution {
    > .dataTableWrapper {
        width: 100%;
    }

    .piwik-graph {
        height: 170px;
    }
}

// With the redesigned legend, widgetized evolution charts match the 20px left/right
// padding of the reports page.
.widget .dataTableVizEvolution {
    padding-left: 20px;
    padding-right: 20px;
}

.widget .tagCloud {
    padding: 10px;
}
.widget .dataTableVizBar .jqplot-graph {
    padding: 0 10px 10px 10px;
}

.tooltip-series-color {
    display: inline-block;
    width: 11px;
    height: 11px;
    border-radius: 6px;
    margin-right: 3px;
    position: relative;
    top: 1px;
}

.ui-tooltip h3.evolution-tooltip-header {
    margin-top: 4px;
}