Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,12 @@ An alternative provider with specific advantages:

Documentation and installation instructions will be published when the project reaches stable release.

## Beta vs Stable Features

Plugins and providers are organized into two categories:
- **Non-beta**: Stable, well-tested features ready for production use
- **Beta** (`beta/` directories): Preview features available for testing; not recommended for production

## Status

This project is in active development and not yet ready for production use. APIs may change without notice.
14 changes: 7 additions & 7 deletions demo/js/farming.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ import { searchCustomDatasets } from './searchCustomDatasets.js'
import { transformGeocodeRequest, transformTileRequest, transformDataRequest } from './auth.js'
// Providers
import maplibreProvider from '/providers/maplibre/src/index.js'
import openNamesProvider from '/providers/open-names/src/index.js'
import openNamesProvider from '/providers/beta/open-names/src/index.js'
// Plugins
import useLocationPlugin from '/plugins/use-location/src/index.js'
import mapStylesPlugin from '/plugins/map-styles/src/index.js'
import createDatasetsPlugin from '/plugins/datasets/src/index.js'
import createDrawPlugin from '/plugins/draw-ml/src/index.js'
import scaleBarPlugin from '/plugins/scale-bar/src/index.js'
import useLocationPlugin from '/plugins/beta/use-location/src/index.js'
import mapStylesPlugin from '/plugins/beta/map-styles/src/index.js'
import createDatasetsPlugin from '/plugins/beta/datasets/src/index.js'
import createDrawPlugin from '/plugins/beta/draw-ml/src/index.js'
import scaleBarPlugin from '/plugins/beta/scale-bar/src/index.js'
import searchPlugin from '/plugins/search/src/index.js'
import createInteractPlugin from '/plugins/interact/src/index.js'
import createFramePlugin from '/plugins/frame/src/index.js'
import createFramePlugin from '/plugins/beta/frame/src/index.js'

var feature = { id: 'test1234', type: 'Feature', geometry: { coordinates: [[[-2.9406643378873127,54.918060570259456],[-2.9092219779267054,54.91564249172612],[-2.904350626383433,54.90329530000005],[-2.909664828067463,54.89540129642464],[-2.9225074821353587,54.88979816151294],[-2.937121536764323,54.88826989853317],[-2.95682836800691,54.88916139231736],[-2.965463945742613,54.898966521920045],[-2.966349646023133,54.910805898763385],[-2.9406643378873127,54.918060570259456]]], type: 'Polygon' }}

Expand Down
8 changes: 4 additions & 4 deletions demo/js/forms.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ import { searchCustomDatasets } from './searchCustomDatasets.js'
import { transformGeocodeRequest, transformTileRequest } from './auth.js'
// Providers
import maplibreProvider from '/providers/maplibre/src/index.js'
import openNamesProvider from '/providers/open-names/src/index.js'
import openNamesProvider from '/providers/beta/open-names/src/index.js'
// Plugins
import useLocationPlugin from '/plugins/use-location/src/index.js'
import mapStylesPlugin from '/plugins/map-styles/src/index.js'
import scaleBarPlugin from '/plugins/scale-bar/src/index.js'
import useLocationPlugin from '/plugins/beta/use-location/src/index.js'
import mapStylesPlugin from '/plugins/beta/map-styles/src/index.js'
import scaleBarPlugin from '/plugins/beta/scale-bar/src/index.js'
import searchPlugin from '/plugins/search/src/index.js'
import createInteractPlugin from '/plugins/interact/src/index.js'

Expand Down
14 changes: 7 additions & 7 deletions demo/js/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ import { searchCustomDatasets } from './searchCustomDatasets.js'
import { transformGeocodeRequest, transformTileRequest, transformDataRequest } from './auth.js'
// Providers
import maplibreProvider from '/providers/maplibre/src/index.js'
import openNamesProvider from '/providers/open-names/src/index.js'
import openNamesProvider from '/providers/beta/open-names/src/index.js'
// Plugins
import useLocationPlugin from '/plugins/use-location/src/index.js'
import mapStylesPlugin from '/plugins/map-styles/src/index.js'
import createDatasetsPlugin from '/plugins/datasets/src/index.js'
import createDrawPlugin from '/plugins/draw-ml/src/index.js'
import scaleBarPlugin from '/plugins/scale-bar/src/index.js'
import useLocationPlugin from '/plugins/beta/use-location/src/index.js'
import mapStylesPlugin from '/plugins/beta/map-styles/src/index.js'
import createDatasetsPlugin from '/plugins/beta/datasets/src/index.js'
import createDrawPlugin from '/plugins/beta/draw-ml/src/index.js'
import scaleBarPlugin from '/plugins/beta/scale-bar/src/index.js'
import searchPlugin from '/plugins/search/src/index.js'
import createInteractPlugin from '/plugins/interact/src/index.js'
import createFramePlugin from '/plugins/frame/src/index.js'
import createFramePlugin from '/plugins/beta/frame/src/index.js'

var interactPlugin = createInteractPlugin({
dataLayers: [{
Expand Down
14 changes: 7 additions & 7 deletions demo/js/planning.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@ import { vtsMapStyles27700 } from './mapStyles.js'
import { searchCustomDatasets } from './searchCustomDatasets.js'
import { transformGeocodeRequest, transformTileRequest, setupEsriConfig } from './auth.js'
// Providers
import openNamesProvider from '/providers/open-names/src/index.js'
import esriProvider from '/providers/esri/src/index.js'
import openNamesProvider from '/providers/beta/open-names/src/index.js'
import esriProvider from '/providers/beta/esri/src/index.js'
// Plugins
import useLocationPlugin from '/plugins/use-location/src/index.js'
import mapStylesPlugin from '/plugins/map-styles/src/index.js'
import createDrawPlugin from '/plugins/draw-es/src/index.js'
import scaleBarPlugin from '/plugins/scale-bar/src/index.js'
import useLocationPlugin from '/plugins/beta/use-location/src/index.js'
import mapStylesPlugin from '/plugins/beta/map-styles/src/index.js'
import createDrawPlugin from '/plugins/beta/draw-es/src/index.js'
import scaleBarPlugin from '/plugins/beta/scale-bar/src/index.js'
import searchPlugin from '/plugins/search/src/index.js'
import createInteractPlugin from '/plugins/interact/src/index.js'
import createFramePlugin from '/plugins/frame/src/index.js'
import createFramePlugin from '/plugins/beta/frame/src/index.js'
// Demo utils
import { hideMenu, toggleButtonState, getGeometryShape } from './planning-utils.js'

Expand Down
14 changes: 7 additions & 7 deletions govuk-prototype-kit.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@
"/dist/css/",
"/dist/umd/",
"/providers/maplibre/dist",
"/providers/open-names/dist",
"/plugins/datasets/dist",
"/providers/beta/open-names/dist",
"/plugins/beta/datasets/dist",
"/plugins/interact/dist",
"/plugins/map-styles/dist",
"/plugins/scale-bar/dist",
"/plugins/beta/map-styles/dist",
"/plugins/beta/scale-bar/dist",
"/plugins/search/dist",
"/plugins/use-location/dist",
"/plugins/draw-ml/dist",
"/plugins/frame/dist"
"/plugins/beta/use-location/dist",
"/plugins/beta/draw-ml/dist",
"/plugins/beta/frame/dist"
]
}
6 changes: 5 additions & 1 deletion jest.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,11 @@ export default {
'<rootDir>/providers/**/*.test.[jt]s?(x)'
],
testPathIgnorePatterns: ['<rootDir>/src/test-utils.js'],
coveragePathIgnorePatterns: ['<rootDir>/src/test-utils.js'],
coveragePathIgnorePatterns: [
'<rootDir>/src/test-utils.js',
'<rootDir>/plugins/beta/',
'<rootDir>/providers/beta/'
],
transformIgnorePatterns: []
}]
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { getValueForStyle } from '../../../src/utils/getValueForStyle.js'
import { getValueForStyle } from '../../../../src/utils/getValueForStyle.js'

// Generate a hash for consistent source ID generation
const hashString = (str) => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from "react"
import { getValueForStyle } from '../../../../src/utils/getValueForStyle'
import { getValueForStyle } from '../../../../../src/utils/getValueForStyle'

export const Key = ({ mapState, pluginState }) => {
const { mapStyle } = mapState
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import DrawPolygon from '../../../../node_modules/@mapbox/mapbox-gl-draw/src/modes/draw_polygon.js'
import createVertex from '../../../../node_modules/@mapbox/mapbox-gl-draw/src/lib/create_vertex.js'
import DrawPolygon from '../../../../../node_modules/@mapbox/mapbox-gl-draw/src/modes/draw_polygon.js'
import createVertex from '../../../../../node_modules/@mapbox/mapbox-gl-draw/src/lib/create_vertex.js'
import { isValidClick } from '../utils.js'
import {
getSnapInstance,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import DirectSelect from '../../../../node_modules/@mapbox/mapbox-gl-draw/src/modes/direct_select.js'
import DirectSelect from '../../../../../node_modules/@mapbox/mapbox-gl-draw/src/modes/direct_select.js'
import { spatialNavigate } from '../utils.js'
import {
getSnapInstance, isSnapActive, isSnapEnabled, getSnapLngLat,
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react'
import { textSizeSvgPath } from './config.js'
import { scaleFactor } from '../../../src/config/appConfig.js'
import { scaleFactor } from '../../../../src/config/appConfig.js'

export const MapStyles = ({ mapState, pluginConfig, services, mapProvider }) => {
const { mapStyle: currentMapStyle, mapSize: currentMapSize } = mapState
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion sonar-project.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ sonar.javascript.lcov.reportPaths=coverage/lcov.info
sonar.sourceEncoding=UTF-8

sonar.sources=src,plugins,providers
sonar.exclusions=**/*.test.*,**/__mocks__/**,**/__stubs__/**,**/dist/**,**/node_modules/**
sonar.exclusions=**/*.test.*,**/__mocks__/**,**/__stubs__/**,**/dist/**,**/node_modules/**,plugins/beta/**,providers/beta/**
sonar.tests=src,plugins,providers
sonar.test.inclusions=**/*.test.*,**/__mocks__/**,**/__stubs__/**
sonar.cpd.exclusions=**/*.test.*,**/__mocks__/**,**/__stubs__/**
Expand Down
16 changes: 8 additions & 8 deletions webpack.esm.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -118,18 +118,18 @@ const ALL_BUILDS = [

// Providers
{ entryPath: './providers/maplibre/src/index.js', outDir: 'providers/maplibre/dist/esm' },
{ entryPath: './providers/open-names/src/index.js', outDir: 'providers/open-names/dist/esm' },
// { entryPath: './providers/esri/src/index.js', outDir: 'providers/esri/dist/esm' },
{ entryPath: './providers/beta/open-names/src/index.js', outDir: 'providers/beta/open-names/dist/esm' },
// { entryPath: './providers/beta/esri/src/index.js', outDir: 'providers/beta/esri/dist/esm' },

// Plugins
{ entryPath: './plugins/scale-bar/src/index.js', outDir: 'plugins/scale-bar/dist/esm' },
{ entryPath: './plugins/use-location/src/index.js', outDir: 'plugins/use-location/dist/esm' },
{ entryPath: './plugins/beta/scale-bar/src/index.js', outDir: 'plugins/beta/scale-bar/dist/esm' },
{ entryPath: './plugins/beta/use-location/src/index.js', outDir: 'plugins/beta/use-location/dist/esm' },
{ entryPath: './plugins/search/src/index.js', outDir: 'plugins/search/dist/esm' },
{ entryPath: './plugins/interact/src/index.js', outDir: 'plugins/interact/dist/esm' },
{ entryPath: './plugins/datasets/src/index.js', outDir: 'plugins/datasets/dist/esm' },
{ entryPath: './plugins/map-styles/src/index.js', outDir: 'plugins/map-styles/dist/esm' },
{ entryPath: './plugins/draw-ml/src/index.js', outDir: 'plugins/draw-ml/dist/esm' },
{ entryPath: './plugins/frame/src/index.js', outDir: 'plugins/frame/dist/esm' }
{ entryPath: './plugins/beta/datasets/src/index.js', outDir: 'plugins/beta/datasets/dist/esm' },
{ entryPath: './plugins/beta/map-styles/src/index.js', outDir: 'plugins/beta/map-styles/dist/esm' },
{ entryPath: './plugins/beta/draw-ml/src/index.js', outDir: 'plugins/beta/draw-ml/dist/esm' },
{ entryPath: './plugins/beta/frame/src/index.js', outDir: 'plugins/beta/frame/dist/esm' }
]

// === Filter via environment variable ===
Expand Down
16 changes: 8 additions & 8 deletions webpack.umd.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -133,18 +133,18 @@ const ALL_BUILDS = [

// Providers
{ entryPath: './providers/maplibre/src/index.js', libraryPath: 'maplibreProvider', outDir: 'providers/maplibre/dist/umd' },
{ entryPath: './providers/open-names/src/index.js', libraryPath: 'openNamesProvider', outDir: 'providers/open-names/dist/umd' },
// { entryPath: './providers/esri/src/index.js', libraryPath: 'esriProvider', outDir: 'providers/esri/dist/umd' },
{ entryPath: './providers/beta/open-names/src/index.js', libraryPath: 'openNamesProvider', outDir: 'providers/beta/open-names/dist/umd' },
// { entryPath: './providers/beta/esri/src/index.js', libraryPath: 'esriProvider', outDir: 'providers/beta/esri/dist/umd' },

// Plugins
{ entryPath: './plugins/scale-bar/src/index.js', libraryPath: 'scaleBarPlugin', outDir: 'plugins/scale-bar/dist/umd' },
{ entryPath: './plugins/use-location/src/index.js', libraryPath: 'drawPolygonMLPlugin', outDir: 'plugins/use-location/dist/umd' },
{ entryPath: './plugins/beta/scale-bar/src/index.js', libraryPath: 'scaleBarPlugin', outDir: 'plugins/beta/scale-bar/dist/umd' },
{ entryPath: './plugins/beta/use-location/src/index.js', libraryPath: 'drawPolygonMLPlugin', outDir: 'plugins/beta/use-location/dist/umd' },
{ entryPath: './plugins/search/src/index.js', libraryPath: 'searchPlugin', outDir: 'plugins/search/dist/umd' },
{ entryPath: './plugins/interact/src/index.js', libraryPath: 'interactPlugin', outDir: 'plugins/interact/dist/umd' },
{ entryPath: './plugins/datasets/src/index.js', libraryPath: 'datasetsPlugin', outDir: 'plugins/datasets/dist/umd' },
{ entryPath: './plugins/map-styles/src/index.js', libraryPath: 'mapStylesPlugin', outDir: 'plugins/map-styles/dist/umd' },
{ entryPath: './plugins/draw-ml/src/index.js', libraryPath: 'drawMLPlugin', outDir: 'plugins/draw-ml/dist/umd' },
{ entryPath: './plugins/frame/src/index.js', libraryPath: 'framePlugin', outDir: 'plugins/frame/dist/umd' }
{ entryPath: './plugins/beta/datasets/src/index.js', libraryPath: 'datasetsPlugin', outDir: 'plugins/beta/datasets/dist/umd' },
{ entryPath: './plugins/beta/map-styles/src/index.js', libraryPath: 'mapStylesPlugin', outDir: 'plugins/beta/map-styles/dist/umd' },
{ entryPath: './plugins/beta/draw-ml/src/index.js', libraryPath: 'drawMLPlugin', outDir: 'plugins/beta/draw-ml/dist/umd' },
{ entryPath: './plugins/beta/frame/src/index.js', libraryPath: 'framePlugin', outDir: 'plugins/beta/frame/dist/umd' }
]

// === Filter via environment variable ===
Expand Down