Init
This commit is contained in:
33
src/app/map/geojson.ts
Normal file
33
src/app/map/geojson.ts
Normal file
@@ -0,0 +1,33 @@
|
||||
import * as G from 'geojson';
|
||||
|
||||
// Custom GeoJSON style for the building
|
||||
export const buildingSytle = {
|
||||
color: '#d62305', // Red border
|
||||
weight: 2, // Border width
|
||||
fillColor: '#d62305', // Red fill
|
||||
fillOpacity: 0.1, // Semi-transparent fill
|
||||
};
|
||||
|
||||
// Example GeoJSON data
|
||||
export const examplePolygon: G.Polygon = {
|
||||
type: 'Polygon',
|
||||
coordinates: [
|
||||
[
|
||||
[8.3897067, 49.0149349], // Southwest corner
|
||||
[8.3904111, 49.0149078], // Southeast corner
|
||||
[8.3904345, 49.0151542], // Northeast corner
|
||||
[8.3897302, 49.0151832], // Northwest corner
|
||||
[8.3897067, 49.0149349], // Closing the polygon by repeating the first point
|
||||
],
|
||||
],
|
||||
};
|
||||
|
||||
export const buildingE: G.Feature = {
|
||||
type: 'Feature',
|
||||
properties: {
|
||||
name: 'Gebäude E',
|
||||
building: 'university',
|
||||
center: [8.39007, 49.015],
|
||||
},
|
||||
geometry: examplePolygon,
|
||||
};
|
||||
Reference in New Issue
Block a user