Plot.plot({
fx: { padding: 0.1, axis: null },
fy: { padding: 0.2, axis: null },
facet: {
data: views,
x: (_d, i) => i % noColumns,
y: (_d, i) => Math.floor(i / noColumns),
label: null
},
projection: {
type: "identity",
inset: 2,
domain: {
type: "MultiPoint",
coordinates: [
[0, 0],
[1000, 1000]
]
}
},
marks: [
Plot.frame({
fill: "steelblue",
fillOpacity: 0.1,
stroke: "#222"
}),
Plot.text(views, {
text: "name",
frameAnchor: "top",
dy: -20,
label: null,
fontSize: 16
}),
Plot.geo(views, {
geometry: (d) => d.projection(worldTopo),
fill: "#fff",
stroke: "#222",
strokeWidth: 0.5
}),
Plot.geo(views, {
geometry: (d) => d.projection(d.disputed),
stroke: "red",
fill: "red",
strokeWidth: 2,
strokeOpacity: 0.5,
fillOpacity: 1
})
]
})