feat: better notification storage and image caching + blobs
C++ / fmt (pull_request) Failing after 5s
C++ / build (pull_request) Failing after 11s
C++ / clang-tidy (pull_request) Failing after 10s
JS/TS / fmt (pull_request) Successful in 12s
JS/TS / lint (pull_request) Successful in 10s
Python / static (pull_request) Failing after 27s
Rust / build (pull_request) Successful in 54s
Python / verify (pull_request) Failing after 1m26s
Rust / fmt (pull_request) Successful in 46s
Rust / clippy (pull_request) Successful in 1m6s
C++ / fmt (pull_request) Failing after 5s
C++ / build (pull_request) Failing after 11s
C++ / clang-tidy (pull_request) Failing after 10s
JS/TS / fmt (pull_request) Successful in 12s
JS/TS / lint (pull_request) Successful in 10s
Python / static (pull_request) Failing after 27s
Rust / build (pull_request) Successful in 54s
Python / verify (pull_request) Failing after 1m26s
Rust / fmt (pull_request) Successful in 46s
Rust / clippy (pull_request) Successful in 1m6s
This commit is contained in:
@@ -55,6 +55,21 @@ Item {
|
||||
return ZUtils.snap(v, canvas);
|
||||
}
|
||||
|
||||
// A value is plottable only if it is a real number. Everything else -
|
||||
// null, undefined, NaN, an unparsable string from the API - is a hole, so
|
||||
// the series splits there. Non-finite coordinates must never reach the
|
||||
// path: one NaN lineTo makes the canvas ignore the rest of the curve, and
|
||||
// the fill then runs from whatever y it last had straight down.
|
||||
function numeric(v) {
|
||||
if (typeof v === "number")
|
||||
return Number.isFinite(v) ? v : null;
|
||||
if (typeof v === "string") {
|
||||
const n = Number(v);
|
||||
return Number.isFinite(n) ? n : null;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function strokeCurve(ctx, pts) {
|
||||
ctx.beginPath();
|
||||
ctx.moveTo(pts[0].x, pts[0].y);
|
||||
@@ -230,7 +245,8 @@ Item {
|
||||
if (loAuto || hiAuto) {
|
||||
let dmin = Infinity;
|
||||
let dmax = -Infinity;
|
||||
for (const v of root.values) {
|
||||
for (const value of root.values) {
|
||||
const v = numeric(value);
|
||||
if (v == null)
|
||||
continue;
|
||||
if (v < dmin)
|
||||
@@ -272,7 +288,7 @@ Item {
|
||||
if (range <= 0 || root.xSteps < 1)
|
||||
return;
|
||||
|
||||
let series = root.values;
|
||||
let series = root.values.map(v => numeric(v));
|
||||
if (root.smoothing > 0 && series.length > 0) {
|
||||
const radius = Math.round(root.smoothing);
|
||||
const raw = series;
|
||||
|
||||
Reference in New Issue
Block a user