Skip to content

Commit

Permalink
Added missing @peripleo deps + changed from interface to type
Browse files Browse the repository at this point in the history
  • Loading branch information
rsimon committed Jan 30, 2024
1 parent 720e7d3 commit 75fdb3a
Show file tree
Hide file tree
Showing 3 changed files with 3,691 additions and 4,551 deletions.
2 changes: 2 additions & 0 deletions packages/geospatial/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
},
"devDependencies": {
"@performant-software/webpack-config": "^1.0.0",
"@peripleo/maplibre": "^0.3.1",
"@peripleo/peripleo": "^0.3.1",
"react": "^18.2.0",
"react-dom": "^18.2.0"
}
Expand Down
29 changes: 8 additions & 21 deletions packages/geospatial/src/components/CoreDataPlace.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,15 @@ import { Feature, FeatureCollection, Peripleo, Controls } from '@peripleo/peripl
import { Map, MixedGeoJSONLayer, PulsingMarkerLayer, Zoom } from '@peripleo/maplibre';
import { DEFAULT_FILL_STYLE, DEFAULT_POINT_STYLE, DEFAULT_STROKE_STYLE } from './CoreDataPlaceStyles';

interface CoreDataPlaceProps {

type CoreDataPlaceProps = {
mapStyle: string | object;

placeURI: string;

fillStyle?: object;

pointStyle?: object;

strokeStyle?: object;
};

}

const CoreDataPlace = (props: CoreDataPlaceProps) => {
export const CoreDataPlace = (props: CoreDataPlaceProps) => {

return (
<Peripleo>
Expand All @@ -35,19 +29,14 @@ const CoreDataPlace = (props: CoreDataPlaceProps) => {
</Peripleo>
)

}

interface CoreDataPlaceLayerProps {
};

type CoreDataPlaceLayerProps = {
uri: string;

fillStyle?: object;

pointStyle?: object;

strokeStyle?: object;

}
};

export const CoreDataPlaceLayer = (props: CoreDataPlaceLayerProps) => {

Expand All @@ -63,7 +52,7 @@ export const CoreDataPlaceLayer = (props: CoreDataPlaceLayerProps) => {
...data.properties,
record_id: data.record_id
}
} as Feature;
};

setPlace({
type: 'FeatureCollection',
Expand All @@ -87,6 +76,4 @@ export const CoreDataPlaceLayer = (props: CoreDataPlaceLayerProps) => {
</>
)

}

export default CoreDataPlace;
};
Loading

0 comments on commit 75fdb3a

Please sign in to comment.