Skip to content

Commit

Permalink
dev to include type fix
Browse files Browse the repository at this point in the history
  • Loading branch information
conbrad committed Nov 21, 2023
1 parent 2331068 commit a7ff258
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"lodash": "^4.17.21",
"luxon": "^3.0.2",
"match-sorter": "^6.3.1",
"ol": "^8.0.0",
"ol": "^9.0.0-dev.1700506701744",
"ol-pmtiles": "^0.3.0",
"prettier": "^2.4.1",
"react": "^17.0.2",
Expand Down
5 changes: 3 additions & 2 deletions web/src/features/map/VectorLayer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@ import { StyleLike } from 'ol/style/Style'

import { MapContext } from 'features/map/Map'
import Geometry from 'ol/geom/Geometry'
import Feature from 'ol/Feature'

interface Props {
source: VectorSource<Geometry>
source: VectorSource<Feature<Geometry>>
style: StyleLike
opacity?: number
zIndex?: number
Expand All @@ -16,7 +17,7 @@ interface Props {
const VectorLayer = ({ source, style, opacity, zIndex = 0 }: Props) => {
const map = useContext(MapContext)

const [layer, setLayer] = useState<OLVectorLayer<VectorSource<Geometry>> | null>(null)
const [layer, setLayer] = useState<OLVectorLayer<VectorSource<Feature<Geometry>>> | null>(null)

Check warning on line 20 in web/src/features/map/VectorLayer.tsx

View check run for this annotation

Codecov / codecov/patch

web/src/features/map/VectorLayer.tsx#L20

Added line #L20 was not covered by tests

useEffect(() => {
if (!map) return
Expand Down
8 changes: 4 additions & 4 deletions web/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8570,10 +8570,10 @@ ol-pmtiles@^0.3.0:
dependencies:
pmtiles "2.11.0"

ol@^8.0.0:
version "8.2.0"
resolved "https://registry.yarnpkg.com/ol/-/ol-8.2.0.tgz#145153eab0ea3b5d04f51f46d6c69c224cccd5c3"
integrity sha512-/m1ddd7Jsp4Kbg+l7+ozR5aKHAZNQOBAoNZ5pM9Jvh4Etkf0WGkXr9qXd7PnhmwiC1Hnc2Toz9XjCzBBvexfXw==
ol@^9.0.0-dev.1700506701744:
version "9.0.0-dev.1700506701744"
resolved "https://registry.yarnpkg.com/ol/-/ol-9.0.0-dev.1700506701744.tgz#57e1fb7108518f3d9aaef85805cde4c609e4e3ba"
integrity sha512-37miA82P0MSmi8uCz7K7gQRx5WP5sMfSRsqu9hBhS8n9FKP7FC4vJbpCIACcjd7XbH3P7rc9IfmoBIrm6Sb5Lw==
dependencies:
color-rgba "^3.0.0"
color-space "^2.0.1"
Expand Down

0 comments on commit a7ff258

Please sign in to comment.