diff --git a/packages/core/dev-test/config.yml b/packages/core/dev-test/config.yml index 7a04fe64..e980fe69 100644 --- a/packages/core/dev-test/config.yml +++ b/packages/core/dev-test/config.yml @@ -565,6 +565,16 @@ collections: widget: map pattern: ['\[-([7-9][0-9]|1[0-2][0-9])\.', 'Must be between latitude -70 and -129'] required: false + - name: line_string + label: Line String + type: LineString + widget: map + required: false + - name: polygon + label: Polygon + type: Polygon + widget: map + required: false - name: markdown label: Markdown file: _widgets/markdown.json diff --git a/packages/core/src/widgets/map/withMapControl.tsx b/packages/core/src/widgets/map/withMapControl.tsx index 186b2286..057beae9 100644 --- a/packages/core/src/widgets/map/withMapControl.tsx +++ b/packages/core/src/widgets/map/withMapControl.tsx @@ -38,7 +38,6 @@ interface WithMapControlProps { const withMapControl = ({ getFormat, getMap }: WithMapControlProps = {}) => { const MapControl: FC> = ({ - path, value, field, onChange, @@ -84,7 +83,8 @@ const withMapControl = ({ getFormat, getMap }: WithMapControlProps = {}) => { onChange(format.writeGeometry(geometry, writeOptions)); } }); - }, [disabled, field, mapContainer, onChange, path, value]); + // eslint-disable-next-line react-hooks/exhaustive-deps + }, []); return (