mirror of
https://github.com/protomaps/PMTiles.git
synced 2026-02-04 10:51:07 +00:00
* clean up comments and console
This commit is contained in:
@@ -347,7 +347,6 @@ function DirectoryTable(props: {
|
|||||||
|
|
||||||
function ArchiveView(props: { genericTileset: Accessor<Tileset> }) {
|
function ArchiveView(props: { genericTileset: Accessor<Tileset> }) {
|
||||||
const tileset = createMemo(() => {
|
const tileset = createMemo(() => {
|
||||||
console.log("memo!");
|
|
||||||
const g = props.genericTileset();
|
const g = props.genericTileset();
|
||||||
if (g instanceof PMTilesTileset) {
|
if (g instanceof PMTilesTileset) {
|
||||||
return g as PMTilesTileset;
|
return g as PMTilesTileset;
|
||||||
|
|||||||
@@ -128,9 +128,6 @@ function ZoomableTile(props: {
|
|||||||
const height = containerRef.clientHeight;
|
const height = containerRef.clientHeight;
|
||||||
const width = containerRef.clientWidth;
|
const width = containerRef.clientWidth;
|
||||||
|
|
||||||
// const width = 800;
|
|
||||||
// const height = 300;
|
|
||||||
|
|
||||||
const x = scaleLinear()
|
const x = scaleLinear()
|
||||||
.domain([-1000, 4096 + 1000])
|
.domain([-1000, 4096 + 1000])
|
||||||
.range([-1000, 4096 + 1000]);
|
.range([-1000, 4096 + 1000]);
|
||||||
@@ -158,15 +155,6 @@ function ZoomableTile(props: {
|
|||||||
undefined
|
undefined
|
||||||
>;
|
>;
|
||||||
view = svg.append("g");
|
view = svg.append("g");
|
||||||
view
|
|
||||||
.append("rect")
|
|
||||||
.attr("width", 4096)
|
|
||||||
.attr("height", 4096)
|
|
||||||
.attr("x", 0)
|
|
||||||
.attr("y", 0)
|
|
||||||
.attr("fill", "none")
|
|
||||||
.attr("strokeWidth", "1")
|
|
||||||
.attr("stroke", "blue");
|
|
||||||
const gX = svg.append("g").attr("class", "axis axis--x").call(xAxis);
|
const gX = svg.append("g").attr("class", "axis axis--x").call(xAxis);
|
||||||
const gY = svg.append("g").attr("class", "axis axis--y").call(yAxis);
|
const gY = svg.append("g").attr("class", "axis axis--y").call(yAxis);
|
||||||
|
|
||||||
@@ -239,6 +227,16 @@ function ZoomableTile(props: {
|
|||||||
|
|
||||||
createEffect(async () => {
|
createEffect(async () => {
|
||||||
view.selectAll("*").remove();
|
view.selectAll("*").remove();
|
||||||
|
view
|
||||||
|
.append("rect")
|
||||||
|
.attr("width", 4096)
|
||||||
|
.attr("height", 4096)
|
||||||
|
.attr("x", 0)
|
||||||
|
.attr("y", 0)
|
||||||
|
.attr("fill", "none")
|
||||||
|
.attr("class", "tile-border")
|
||||||
|
.attr("strokeWidth", "1");
|
||||||
|
|
||||||
const tile = parsedTile();
|
const tile = parsedTile();
|
||||||
if (!tile) return;
|
if (!tile) return;
|
||||||
|
|
||||||
|
|||||||
@@ -9,6 +9,10 @@ json-viewer {
|
|||||||
padding: 4px;
|
padding: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.tile-border {
|
||||||
|
stroke: black;
|
||||||
|
}
|
||||||
|
|
||||||
@theme {
|
@theme {
|
||||||
--color-purple: #3131dc;
|
--color-purple: #3131dc;
|
||||||
--color-slate: #e7e7f9;
|
--color-slate: #e7e7f9;
|
||||||
@@ -81,6 +85,10 @@ json-viewer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
|
.tile-border {
|
||||||
|
stroke: white;
|
||||||
|
}
|
||||||
|
|
||||||
.maplibregl-ctrl.maplibregl-ctrl-group {
|
.maplibregl-ctrl.maplibregl-ctrl-group {
|
||||||
filter: invert(1);
|
filter: invert(1);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user