Fix all TypeScript errors and remove Storybook
All checks were successful
Build Docker Image / build (push) Successful in 5m8s
All checks were successful
Build Docker Image / build (push) Successful in 5m8s
- Remove all Storybook files and configuration - Add type declarations for @vueuse/core, @formkit/core, vue3-apexcharts - Fix TypeScript configuration (typeRoots, include paths) - Fix Sentry config - move settings to plugin - Fix nullable prop assignments with ?? operator - Fix type narrowing issues with explicit type assertions - Fix Card component linkable computed properties - Update codegen with operationResultSuffix - Fix GraphQL operation type definitions
This commit is contained in:
@@ -228,15 +228,16 @@ const onMapCreated = (map: MapboxMap) => {
|
||||
// Click on cluster to zoom in
|
||||
map.on('click', 'clusters', (e) => {
|
||||
const features = map.queryRenderedFeatures(e.point, { layers: ['clusters'] })
|
||||
if (!features.length) return
|
||||
const feature = features[0]
|
||||
if (!feature) return
|
||||
|
||||
const clusterId = features[0].properties?.cluster_id
|
||||
const clusterId = feature.properties?.cluster_id
|
||||
const source = map.getSource('locations') as mapboxgl.GeoJSONSource
|
||||
|
||||
source.getClusterExpansionZoom(clusterId, (err, zoom) => {
|
||||
if (err) return
|
||||
|
||||
const geometry = features[0].geometry as GeoJSON.Point
|
||||
const geometry = feature.geometry as GeoJSON.Point
|
||||
map.easeTo({
|
||||
center: geometry.coordinates as [number, number],
|
||||
zoom: zoom || 4
|
||||
@@ -247,10 +248,11 @@ const onMapCreated = (map: MapboxMap) => {
|
||||
// Click on individual point
|
||||
map.on('click', 'unclustered-point', (e) => {
|
||||
const features = map.queryRenderedFeatures(e.point, { layers: ['unclustered-point'] })
|
||||
if (!features.length) return
|
||||
const feature = features[0]
|
||||
if (!feature) return
|
||||
|
||||
const featureProps = features[0].properties
|
||||
const geometry = features[0].geometry as GeoJSON.Point
|
||||
const featureProps = feature.properties
|
||||
const geometry = feature.geometry as GeoJSON.Point
|
||||
|
||||
const location: Location = {
|
||||
uuid: featureProps?.uuid,
|
||||
|
||||
Reference in New Issue
Block a user