Skip to content

Commit

Permalink
7/9
Browse files Browse the repository at this point in the history
  • Loading branch information
1ec5 committed Mar 24, 2024
1 parent ec2f971 commit eb69695
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions src/layer/highway_shield.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,22 @@ export function getImageNameExpression(routeIndex) {
}

function routeConcurrency(routeIndex) {
return [
let today = new Date();
let fool = today.getMonth() === 3 && today.getDate() === 1;
let concurrency = [
"case",
["!=", ["get", "route_" + routeIndex], null],
["image", getImageNameExpression(routeIndex)],
["literal", ""],
];
if (fool && routeIndex === 3) {
concurrency.push(["==", ["get", "route_1"], "US:CA=99"]);
concurrency.push(["image", "shield\nUS:I:Future=7"]);
} else if (fool && routeIndex === 4) {
concurrency.push(["==", ["get", "route_1"], "US:CA=99"]);
concurrency.push(["image", "shield\nUS:I:Future=9"]);
}
concurrency.push(["literal", ""]);
return concurrency;
}

/**
Expand Down

0 comments on commit eb69695

Please sign in to comment.