Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

React v19 Upgrade

ZachTRice1f85f335460f
diff --git a/.npmrc b/.npmrc
new file mode 100644
index 000000000..521a9f7c0
--- /dev/null
+++ b/.npmrc
@@ -0,0 +1 @@
+legacy-peer-deps=true
diff --git a/e2e/features/animation/animation-test.spec.js b/e2e/features/animation/animation-test.spec.js
index ea43c1150..b837d1bcc 100644
--- a/e2e/features/animation/animation-test.spec.js
+++ b/e2e/features/animation/animation-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour, activeAnimationWidget, animationGeostationary } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/animation/gif-test.spec.js b/e2e/features/animation/gif-test.spec.js
index 9901c1f56..e9556b87b 100644
--- a/e2e/features/animation/gif-test.spec.js
+++ b/e2e/features/animation/gif-test.spec.js
@@ -9,9 +9,10 @@ const {
} = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/animation/mobile-animation-test.spec.js b/e2e/features/animation/mobile-animation-test.spec.js
index eb1082784..ba5be8ac0 100644
--- a/e2e/features/animation/mobile-animation-test.spec.js
+++ b/e2e/features/animation/mobile-animation-test.spec.js
@@ -3,9 +3,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { knownDate } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/charting/charting-test.spec.js b/e2e/features/charting/charting-test.spec.js
index d676502b6..d4aedc9db 100644
--- a/e2e/features/charting/charting-test.spec.js
+++ b/e2e/features/charting/charting-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { swipeAndAIsActive, multipleDataLayers, referenceLayersOnly } = require('../../test-utils/global-variables/querystrings')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/classification/classification-test.spec.js b/e2e/features/classification/classification-test.spec.js
index b156b37f8..43dd3c736 100644
--- a/e2e/features/classification/classification-test.spec.js
+++ b/e2e/features/classification/classification-test.spec.js
@@ -1,8 +1,8 @@
// @ts-check
const { test, expect } = require('@playwright/test')
const UPNG = require('upng-js')
+/** @type {import('@playwright/test').Page} */
let page
-
const floodOnlyGrayUrl = 'http://localhost:3000/?v=-213,-96,107,99&df=true&l=MODIS_Combined_Flood_2-Day(disabled=3-0)&lg=true&t=2023-12-07-T18%3A49%3A23Z'
const floodGrayAndBlueUrl = 'http://localhost:3000/?v=-195,-120,202,122&df=true&l=MODIS_Combined_Flood_2-Day(disabled=3-1)&lg=true&t=2023-12-07-T18%3A49%3A23Z'
const floodAllColorsUrl = 'http://localhost:3000/?v=20.927495068573297,59.38686212149608,23.42534040372529,60.914081461203466&l=MODIS_Combined_Flood_2-Day(disabled=3)&lg=true&t=2021-04-05-T18%3A49%3A23Z'
diff --git a/e2e/features/compare/compare-mobile-test.spec.js b/e2e/features/compare/compare-mobile-test.spec.js
index 103c2a98b..33af32442 100644
--- a/e2e/features/compare/compare-mobile-test.spec.js
+++ b/e2e/features/compare/compare-mobile-test.spec.js
@@ -3,9 +3,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { swipeAndAIsActive, spyAndBIsActive, opacityAndBIsActive } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/compare/compare-test.spec.js b/e2e/features/compare/compare-test.spec.js
index 7aac62f8d..9c086cebc 100644
--- a/e2e/features/compare/compare-test.spec.js
+++ b/e2e/features/compare/compare-test.spec.js
@@ -4,9 +4,11 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { swipeAndAIsActive, spyAndBIsActive } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
-let selectors
+/** @type {ReturnType<typeof createSelectors>} */
+let selectors
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
@@ -46,12 +48,14 @@ test('Image download is disabled when compare mode active', async () => {
test('Data download is disabled when compare mode active', async () => {
const { dataDownloadTabButton } = selectors
const disableMessage = 'You must exit comparison mode to download data'
+ await page.goto(swipeAndAIsActive)
+ await closeModal(page)
await expect(dataDownloadTabButton).toHaveClass(/disabled/)
await expect(dataDownloadTabButton).toHaveAttribute('aria-label', disableMessage)
const downloadTab = page.locator('#download-sidebar-tab')
await downloadTab.hover()
- const tooltipSelector = page.locator('.tooltip-inner')
- await expect(tooltipSelector).toContainText(disableMessage)
+ const tooltipSelector = page.getByRole('tooltip', { name: disableMessage })
+ await expect(tooltipSelector).toBeVisible()
// Clicking does not switch tabs
await dataDownloadTabButton.click()
const smartHandoffPanel = page.locator('#smart-handoff-side-panel')
diff --git a/e2e/features/compare/layer-dialog-test.spec.js b/e2e/features/compare/layer-dialog-test.spec.js
index 0f234b04b..4a1967eb2 100644
--- a/e2e/features/compare/layer-dialog-test.spec.js
+++ b/e2e/features/compare/layer-dialog-test.spec.js
@@ -4,7 +4,9 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { swipeAOD } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
let aerosolLayer
let AodOptionsPanelBody
diff --git a/e2e/features/compare/layer-sidebar-test.spec.js b/e2e/features/compare/layer-sidebar-test.spec.js
index 101f11de0..aac7ebfc3 100644
--- a/e2e/features/compare/layer-sidebar-test.spec.js
+++ b/e2e/features/compare/layer-sidebar-test.spec.js
@@ -4,7 +4,9 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { swipeAndAIsActive } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
let aodCheckBox
let aodMAIACCheckbox
diff --git a/e2e/features/compare/permalinks-test.spec.js b/e2e/features/compare/permalinks-test.spec.js
index 7cf3f5f4c..12f45231f 100644
--- a/e2e/features/compare/permalinks-test.spec.js
+++ b/e2e/features/compare/permalinks-test.spec.js
@@ -8,9 +8,10 @@ const {
} = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/compare/timeline-test.spec.js b/e2e/features/compare/timeline-test.spec.js
index f932432a1..bfa4fc311 100644
--- a/e2e/features/compare/timeline-test.spec.js
+++ b/e2e/features/compare/timeline-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { swipeAndAIsActive } = require('../../test-utils/global-variables/querystrings')
const { timelineDrag, dateSelectorMonthDay, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/dev-test-mode/dev-test-mode-test.spec.js b/e2e/features/dev-test-mode/dev-test-mode-test.spec.js
index 0790c3c62..fbf7d060e 100644
--- a/e2e/features/dev-test-mode/dev-test-mode-test.spec.js
+++ b/e2e/features/dev-test-mode/dev-test-mode-test.spec.js
@@ -2,8 +2,8 @@
const { test, expect } = require('@playwright/test')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
+/** @type {import('@playwright/test').Page} */
let page
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/events/event-filter-test.spec.js b/e2e/features/events/event-filter-test.spec.js
index 2083d4fbe..4a4d51f24 100644
--- a/e2e/features/events/event-filter-test.spec.js
+++ b/e2e/features/events/event-filter-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { fixedAppNow, wildfiresWithDates, backwardsCompatibleEventUrl, extentsUrl } = require('../../test-utils/global-variables/querystrings')
const { switchProjections, clickAndWait, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/events/event-test.spec.js b/e2e/features/events/event-test.spec.js
index 631ccddd6..d71570fb3 100644
--- a/e2e/features/events/event-test.spec.js
+++ b/e2e/features/events/event-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { mockEvents } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/events/events-mobile-test.spec.js b/e2e/features/events/events-mobile-test.spec.js
index 4c8b2910b..bf216a99c 100644
--- a/e2e/features/events/events-mobile-test.spec.js
+++ b/e2e/features/events/events-mobile-test.spec.js
@@ -4,7 +4,9 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { mockEvents, stormEventSelected } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
let trackMarker
diff --git a/e2e/features/global-unit/coordinate-format-test.spec.js b/e2e/features/global-unit/coordinate-format-test.spec.js
index 29bf80bb5..2abe38e35 100644
--- a/e2e/features/global-unit/coordinate-format-test.spec.js
+++ b/e2e/features/global-unit/coordinate-format-test.spec.js
@@ -3,6 +3,7 @@ const { test, expect } = require('@playwright/test')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
const url = 'http://localhost:3000/?v=-78.52435703125,37.8608744140625,-75.56244296875,39.7483255859375&l=Reference_Features_15m(hidden),Coastlines_15m,VIIRS_NOAA20_CorrectedReflectance_TrueColor(hidden),VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor&lg=false&s=-77.0434,38.8046&t=2023-02-15-T19%3A53%3A41Z'
+/** @type {import('@playwright/test').Page} */
let page
let dmButton
let marker
diff --git a/e2e/features/global-unit/global-unit-test.spec.js b/e2e/features/global-unit/global-unit-test.spec.js
index a1f1e36ff..9e7f3405c 100644
--- a/e2e/features/global-unit/global-unit-test.spec.js
+++ b/e2e/features/global-unit/global-unit-test.spec.js
@@ -4,6 +4,7 @@ const { closeModal } = require('../../test-utils/hooks/wvHooks')
const SSTQueryString = 'http://localhost:3000/?l=GHRSST_L4_MUR_Sea_Surface_Temperature,Reference_Labels_15m(hidden),Reference_Features_15m(hidden),Coastlines_15m,VIIRS_NOAA20_CorrectedReflectance_TrueColor(hidden),VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor&lg=false&t=2020-09-28-T20%3A40%3A53Z'
+/** @type {import('@playwright/test').Page} */
let page
let globalSettingsModal
let settingContainer
diff --git a/e2e/features/image-download/crosses-dateline-test.spec.js b/e2e/features/image-download/crosses-dateline-test.spec.js
index c468a3088..d17b0c0dc 100644
--- a/e2e/features/image-download/crosses-dateline-test.spec.js
+++ b/e2e/features/image-download/crosses-dateline-test.spec.js
@@ -2,8 +2,8 @@
const { test, expect } = require('@playwright/test')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
-
const withinMapURLParams = 'http://localhost:3000/?v=-67.80916012733559,-56.052180562072095,-30.50743102883792,-30.873513420586164&t=2021-08-08-T0'
const crossesPrevDayURLParams = 'http://localhost:3000/?v=161.16767164758798,-54.46571918482002,198.46940074608565,-29.287052043334096&t=2021-08-08-T0'
const crossesNextDayURLParams = 'http://localhost:3000/?v=-198.76946733086245,-59.504883811673906,-161.46773823236478,-34.326216670187975&t=2021-08-08-T0'
diff --git a/e2e/features/image-download/formats-test.spec.js b/e2e/features/image-download/formats-test.spec.js
index d2dfc902d..73c7b5c4f 100644
--- a/e2e/features/image-download/formats-test.spec.js
+++ b/e2e/features/image-download/formats-test.spec.js
@@ -13,6 +13,7 @@ const {
selectOption
} = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
const startParams = [
'l=MODIS_Terra_CorrectedReflectance_TrueColor',
diff --git a/e2e/features/image-download/global-select-test.spec.js b/e2e/features/image-download/global-select-test.spec.js
index fa88613aa..7d9f2ee20 100644
--- a/e2e/features/image-download/global-select-test.spec.js
+++ b/e2e/features/image-download/global-select-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { openImageDownloadPanel, closeModal } = require('../../test-utils/hooks/wvHooks')
const { joinUrl } = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const startParams = [
'p=geographic',
'v=-180,-90,180,90',
diff --git a/e2e/features/image-download/initial-state-test.spec.js b/e2e/features/image-download/initial-state-test.spec.js
index 8944872a7..340423d9b 100644
--- a/e2e/features/image-download/initial-state-test.spec.js
+++ b/e2e/features/image-download/initial-state-test.spec.js
@@ -9,9 +9,10 @@ const {
closeModal
} = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const expectedResolutions = '30m60m125m250m500m1km5km10km'
const expectedFormats = 'JPEGPNGGeoTIFFKMZ'
const expectedWorldFile = 'NoYes'
diff --git a/e2e/features/image-download/layers-test.spec.js b/e2e/features/image-download/layers-test.spec.js
index 724443e6d..b9e1ace73 100644
--- a/e2e/features/image-download/layers-test.spec.js
+++ b/e2e/features/image-download/layers-test.spec.js
@@ -3,8 +3,8 @@ const { test, expect } = require('@playwright/test')
const { openImageDownloadPanel, clickDownload, closeModal } = require('../../test-utils/hooks/wvHooks')
const { joinUrl, getAttribute } = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
-
const startParams = [
'v=-180,-90,180,90',
't=2018-06-01',
diff --git a/e2e/features/image-download/projection-test.spec.js b/e2e/features/image-download/projection-test.spec.js
index f08f6bfe7..90429ff01 100644
--- a/e2e/features/image-download/projection-test.spec.js
+++ b/e2e/features/image-download/projection-test.spec.js
@@ -9,8 +9,8 @@ const {
const { joinUrl, getAttribute } = require('../../test-utils/hooks/basicHooks')
const { switchProjections } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
-
const startParams = [
'l=MODIS_Terra_CorrectedReflectance_TrueColor',
't=2018-06-01',
diff --git a/e2e/features/image-download/resolutions3413-test.spec.js b/e2e/features/image-download/resolutions3413-test.spec.js
index 0c4bbf3c8..e3a8c3c72 100644
--- a/e2e/features/image-download/resolutions3413-test.spec.js
+++ b/e2e/features/image-download/resolutions3413-test.spec.js
@@ -10,9 +10,10 @@ const {
} = require('../../test-utils/hooks/wvHooks')
const { joinUrl, getAttribute } = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const startParams = [
'p=arctic',
'v=-4194304,-3145728,4194304,3145728',
diff --git a/e2e/features/image-download/resolutions4326-test.spec.js b/e2e/features/image-download/resolutions4326-test.spec.js
index 027502983..6daf95c2d 100644
--- a/e2e/features/image-download/resolutions4326-test.spec.js
+++ b/e2e/features/image-download/resolutions4326-test.spec.js
@@ -10,9 +10,10 @@ const {
} = require('../../test-utils/hooks/wvHooks')
const { joinUrl, getAttribute } = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const startParams = [
'p=geographic',
'v=-180,-90,180,90',
diff --git a/e2e/features/image-download/time-test.spec.js b/e2e/features/image-download/time-test.spec.js
index 240543d2d..aaee630db 100644
--- a/e2e/features/image-download/time-test.spec.js
+++ b/e2e/features/image-download/time-test.spec.js
@@ -8,8 +8,8 @@ const {
} = require('../../test-utils/hooks/wvHooks')
const { joinUrl, getAttribute } = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
-
const startParams = [
'imageDownload='
]
diff --git a/e2e/features/image-download/unsupported-test.spec.js b/e2e/features/image-download/unsupported-test.spec.js
index cce0c6a18..f3be29f79 100644
--- a/e2e/features/image-download/unsupported-test.spec.js
+++ b/e2e/features/image-download/unsupported-test.spec.js
@@ -4,7 +4,9 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { closeImageDownloadPanel, closeModal } = require('../../test-utils/hooks/wvHooks')
const { joinUrl } = require('../../test-utils/hooks/basicHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
let notify
let cancelNotify
diff --git a/e2e/features/kiosk/kiosk-test.spec.js b/e2e/features/kiosk/kiosk-test.spec.js
index 0634145c0..3f0ffa318 100644
--- a/e2e/features/kiosk/kiosk-test.spec.js
+++ b/e2e/features/kiosk/kiosk-test.spec.js
@@ -2,9 +2,10 @@
const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const kioskQueryStringGeo = 'http://localhost:3000/?v=-250.17116762774398,-114.67919463709383,250.62557403459047,109.37518092954436&df=true&kiosk=true&l=Coastlines_15m,OrbitTracks_Terra_Descending,MODIS_Terra_CorrectedReflectance_TrueColor&lg=true'
const kioskQueryStringArctic = 'http://localhost:3000/?v=-9215416.788865805,-4212995.281243633,9489665.699466601,4155580.686192584&p=arctic&df=true&kiosk=true&eic=da&l=Land_Mask,AMSRU2_Sea_Ice_Concentration_12km(palette=blue_6)&lg=true'
const kioskQueryStringAntarctic = 'http://localhost:3000/?v=-9215416.788865805,-4212995.281243633,9489665.699466601,4155580.686192584&p=antarctic&df=true&kiosk=true&eic=da&l=Land_Mask,AMSRU2_Sea_Ice_Concentration_12km(palette=blue_6)&lg=true'
diff --git a/e2e/features/layers/layer-picker-mobile-test.spec.js b/e2e/features/layers/layer-picker-mobile-test.spec.js
index 505403453..2d85a7cdd 100644
--- a/e2e/features/layers/layer-picker-mobile-test.spec.js
+++ b/e2e/features/layers/layer-picker-mobile-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { assertDefaultLayers, assertCategories, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const url = 'http://localhost:3000/?t=2013-05-15'
test.describe.configure({ mode: 'serial' })
diff --git a/e2e/features/layers/layer-picker-test.spec.js b/e2e/features/layers/layer-picker-test.spec.js
index 26832bc8c..fc3e1ab15 100644
--- a/e2e/features/layers/layer-picker-test.spec.js
+++ b/e2e/features/layers/layer-picker-test.spec.js
@@ -3,7 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { assertCategories, switchProjections, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
const url = 'http://localhost:3000/?t=2013-05-15'
@@ -130,17 +133,18 @@ test('Closing and reopening layer picker restores state.', async () => {
test('Changing app date is reflected in coverage facets', async () => {
const {
layersModalCloseButton,
- yearDown,
- monthDown,
- dayDown,
+ dateSelectorYearInput,
+ dateSelectorMonthInput,
+ dateSelectorDayInput,
addLayers,
availableFilterTextEl,
availableFilterCheckboxInput
} = selectors
await layersModalCloseButton.click()
- await yearDown.click()
- await monthDown.click()
- await dayDown.click()
+ await dateSelectorYearInput.fill('2012')
+ await dateSelectorMonthInput.fill('APR')
+ await dateSelectorDayInput.fill('14')
+ await page.keyboard.press('Enter')
await addLayers.click()
await expect(availableFilterTextEl).toContainText('Available 2012 APR 14')
await expect(availableFilterCheckboxInput).toBeChecked()
diff --git a/e2e/features/layers/layers-sidebar-test.spec.js b/e2e/features/layers/layers-sidebar-test.spec.js
index 4a65c0dca..2545022f1 100644
--- a/e2e/features/layers/layers-sidebar-test.spec.js
+++ b/e2e/features/layers/layers-sidebar-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { assertLayerOrdering, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const vectorsQueryString = 'http://localhost:3000/?v=-70.43215000968726,28.678203599725197,-59.81569241792232,31.62330063930118&l=GRanD_Dams,Reference_Labels_15m(hidden),Reference_Features_15m(hidden),Coastlines_15m,VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),VIIRS_NOAA20_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor'
const someGroupsQueryString = 'http://localhost:3000/?l=MODIS_Combined_Value_Added_AOD,MODIS_Combined_MAIAC_L2G_AerosolOpticalDepth,Reference_Labels_15m(hidden),Reference_Features_15m,MODIS_Terra_CorrectedReflectance_TrueColor&lg=true'
const twoGroupsQueryString = 'http://localhost:3000/?v=-107.15747724134027,-81.6706340523014,47.81381180183274,89.12472754295932&l=VIIRS_SNPP_Thermal_Anomalies_375m_All,VIIRS_NOAA20_Thermal_Anomalies_375m_All,MODIS_Combined_Value_Added_AOD,MODIS_Combined_MAIAC_L2G_AerosolOpticalDepth,Reference_Features_15m,MODIS_Terra_CorrectedReflectance_TrueColor&lg=true'
diff --git a/e2e/features/layers/layers-vector-test.spec.js b/e2e/features/layers/layers-vector-test.spec.js
index efed03f3e..57d9d2f26 100644
--- a/e2e/features/layers/layers-vector-test.spec.js
+++ b/e2e/features/layers/layers-vector-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const damsLayerUrl = 'http://localhost:3000/?v=-70.43215000968726,28.678203599725197,-59.81569241792232,31.62330063930118&l=GRanD_Dams,Reference_Labels_15m(hidden),Reference_Features_15m(hidden),Coastlines_15m,VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),VIIRS_NOAA20_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor'
const damsLayerWMSZoomLevelUrl = 'http://localhost:3000/?v=-166.0537832499445,-8.893604135881553,79.78417648048394,59.303969410599414&l=GRanD_Dams,Reference_Labels_15m(hidden),Reference_Features_15m(hidden),Coastlines_15m,VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),VIIRS_NOAA20_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor'
diff --git a/e2e/features/layers/options-test.spec.js b/e2e/features/layers/options-test.spec.js
index d5a4fca95..e24cf15d7 100644
--- a/e2e/features/layers/options-test.spec.js
+++ b/e2e/features/layers/options-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const customsSquashedQuerystring = 'http://localhost:3000/?p=geographic&l=VIIRS_SNPP_CorrectedReflectance_TrueColor(hidden),MODIS_Aqua_CorrectedReflectance_TrueColor(hidden),MODIS_Terra_CorrectedReflectance_TrueColor,MODIS_Combined_Value_Added_AOD(opacity=0.7,palette=blue_2,min=0.1,0.105,max=0.56,0.565),MODIS_Terra_Aerosol,Reference_Labels_15m(opacity=0.94),Reference_Features_15m(hidden),Coastlines_15m&t=2019-01-15-T00%3A00%3A00Z&z=3&v=-271.7031658620978,-216.84375,370.1093341379022,36.84375'
test.describe.configure({ mode: 'serial' })
diff --git a/e2e/features/layers/recent-layers-mobile-test.spec.js b/e2e/features/layers/recent-layers-mobile-test.spec.js
index 586a0052e..8d7ce6b31 100644
--- a/e2e/features/layers/recent-layers-mobile-test.spec.js
+++ b/e2e/features/layers/recent-layers-mobile-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { assertCategories, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const url = 'http://localhost:3000/?t=2020-07-04'
test.describe.configure({ mode: 'serial' })
@@ -51,6 +52,30 @@ test('Recent tab shows layers that were selected', async () => {
await expect(aodSearchRow).toBeVisible()
})
+test('Swiping left removes a single recent layer', async () => {
+ const aquaAerosolRow = page.locator('#MODIS_Aqua_Aerosol-search-row')
+ const aodSearchRow = page.locator('#MODIS_Combined_Value_Added_AOD-search-row')
+ const omiSearchRow = page.locator('#OMI_Aerosol_Optical_Depth-search-row')
+
+ await expect(aquaAerosolRow).toBeVisible()
+
+ const box = await aquaAerosolRow.boundingBox()
+ expect(box).toBeTruthy()
+
+ const startX = box.x + box.width - 10
+ const endX = box.x + 10
+ const y = box.y + box.height / 2
+
+ await page.mouse.move(startX, y)
+ await page.mouse.down()
+ await page.mouse.move(endX, y, { steps: 12 })
+ await page.mouse.up()
+
+ await expect(aquaAerosolRow).not.toBeVisible()
+ await expect(omiSearchRow).toBeVisible()
+ await expect(aodSearchRow).toBeVisible()
+})
+
test('Clear list button empties the entire list', async () => {
await page.locator('#clear-recent-layers').click()
const productList = await page.locator('.product-outer-list-case.layers-all')
diff --git a/e2e/features/layers/recent-layers-no-local-storage-test.spec.js b/e2e/features/layers/recent-layers-no-local-storage-test.spec.js
index b3856a1e8..921d2d322 100644
--- a/e2e/features/layers/recent-layers-no-local-storage-test.spec.js
+++ b/e2e/features/layers/recent-layers-no-local-storage-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { localStorageEnabled } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const url = 'http://localhost:3000/?t=2020-07-04'
test.describe.configure({ mode: 'serial' })
diff --git a/e2e/features/layers/recent-layers-test.spec.js b/e2e/features/layers/recent-layers-test.spec.js
index 549bd4362..44c6fda77 100644
--- a/e2e/features/layers/recent-layers-test.spec.js
+++ b/e2e/features/layers/recent-layers-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { assertCategories, closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const url = 'http://localhost:3000/?t=2020-07-04'
test.describe.configure({ mode: 'serial' })
diff --git a/e2e/features/location-search/location-search-mobile-test.spec.js b/e2e/features/location-search/location-search-mobile-test.spec.js
index c9b9c3dec..f794fdc48 100644
--- a/e2e/features/location-search/location-search-mobile-test.spec.js
+++ b/e2e/features/location-search/location-search-mobile-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/location-search/location-search-test.spec.js b/e2e/features/location-search/location-search-test.spec.js
index 91ed297c0..8e268f177 100644
--- a/e2e/features/location-search/location-search-test.spec.js
+++ b/e2e/features/location-search/location-search-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const markerUrl = 'http://localhost:3000/?v=-176.3167432493038,-16.70650759975561,-16.988618249303812,108.30938074294103&s=-77.032,38.8904'
const removeMarkerUrl = 'http://localhost:3000/?v=-39.980778604772254,-93.78047406661956,48.73858468999798,-50.229432449264905&s=10,-75'
const invalidMarkerQuery = 'http://localhost:3000/?s=-51.5,invalidtext'
diff --git a/e2e/features/measure/measure-test.spec.js b/e2e/features/measure/measure-test.spec.js
index 35dff2182..fa237f915 100644
--- a/e2e/features/measure/measure-test.spec.js
+++ b/e2e/features/measure/measure-test.spec.js
@@ -10,9 +10,10 @@ const {
closeModal
} = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/modal/about-modal-test.spec.js b/e2e/features/modal/about-modal-test.spec.js
index cbd4d243b..c7cc540a8 100644
--- a/e2e/features/modal/about-modal-test.spec.js
+++ b/e2e/features/modal/about-modal-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
const aboutOpenURL = 'http://localhost:3000/?abt=on'
let aboutPage
diff --git a/e2e/features/palettes/disable-test.spec.js b/e2e/features/palettes/disable-test.spec.js
index 3c609573a..ed34bd1d6 100644
--- a/e2e/features/palettes/disable-test.spec.js
+++ b/e2e/features/palettes/disable-test.spec.js
@@ -2,8 +2,8 @@
const { test, expect } = require('@playwright/test')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
-
const enabledPermalink = 'http://localhost:3000/?l=Last_of_the_Wild_1995-2004'
const disabledPermalink = 'http://localhost:3000/?l=Last_of_the_Wild_1995-2004(disabled=0-13-12-1-2-6)'
@@ -27,8 +27,7 @@ test('Verify that toggling class updates permalink and layer-legend', async () =
await page.locator('.classification-list .react-switch-case .react-switch-button').first().click()
const colorBoxDisabled = await page.locator('#Last_of_the_Wild_1995-2004_0_legend-color-Last_of_the_Wild_1995-2004-active1.disabled-classification')
await expect(colorBoxDisabled).not.toBeVisible()
- const url = await page.url()
- expect(url).toContain('(disabled=0)')
+ await expect.poll(() => page.url(), { timeout: 15000 }).toContain('(disabled=0')
})
test('Verify that toggling class-all off updates permalink and layer-legend', async () => {
@@ -37,8 +36,8 @@ test('Verify that toggling class-all off updates permalink and layer-legend', as
const lastColorBoxDisabled = await page.locator('#Last_of_the_Wild_1995-2004_0_legend-color-Last_of_the_Wild_1995-2004-active15.disabled-classification')
await expect(firstColorBoxDisabled).toBeVisible()
await expect(lastColorBoxDisabled).toBeVisible()
- const url = await page.url()
- expect(url).toContain('(disabled=0-1-2-3-4-5-6-7-8-9-10-11-12-13-14-15)')
+ await expect.poll(() => page.url(), { timeout: 15000 })
+ .toContain('(disabled=0-1-2-3-4-5-6-7-8-9-10-11-12-13-14-15)')
})
test('Verify that toggling class-all on updates permalink and layer-legend', async () => {
diff --git a/e2e/features/projections/projections-test.spec.js b/e2e/features/projections/projections-test.spec.js
index 541e11c20..657f0ebf1 100644
--- a/e2e/features/projections/projections-test.spec.js
+++ b/e2e/features/projections/projections-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { switchProjections, closeModal } = require('../../test-utils/hooks/wvHooks')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/share/share-test.spec.js b/e2e/features/share/share-test.spec.js
index b356d253d..420813713 100644
--- a/e2e/features/share/share-test.spec.js
+++ b/e2e/features/share/share-test.spec.js
@@ -4,7 +4,9 @@ const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { getAttribute } = require('../../test-utils/hooks/basicHooks')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
let context
diff --git a/e2e/features/timeline/date-selector-test.spec.js b/e2e/features/timeline/date-selector-test.spec.js
index 2405262c2..dbc72a97f 100644
--- a/e2e/features/timeline/date-selector-test.spec.js
+++ b/e2e/features/timeline/date-selector-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { subdailyLayerIntervalTimescale, knownDate } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
@@ -171,10 +172,12 @@ test('Date selector up arrow rolls over from Feb 28 to 1 (non leap year) and the
const queryString = 'http://localhost:3000/?t=2013-02-28'
await page.goto(queryString)
await closeModal(page)
+ await dayUp.scrollIntoViewIfNeeded()
await dayUp.click()
await expect(dateSelectorDayInput).toHaveValue('01')
await expect(dateSelectorMonthInput).toHaveValue('FEB')
await expect(dateSelectorYearInput).toHaveValue('2013')
+ await dayDown.scrollIntoViewIfNeeded()
await dayDown.click()
await expect(dateSelectorDayInput).toHaveValue('28')
await expect(dateSelectorMonthInput).toHaveValue('FEB')
diff --git a/e2e/features/timeline/layer-coverage-panel-test.spec.js b/e2e/features/timeline/layer-coverage-panel-test.spec.js
index 737009010..967a124fb 100644
--- a/e2e/features/timeline/layer-coverage-panel-test.spec.js
+++ b/e2e/features/timeline/layer-coverage-panel-test.spec.js
@@ -3,8 +3,8 @@ const { test, expect } = require('@playwright/test')
const { skipTour, referenceLayersOnly } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/timeline/timeline-mobile-test.spec.js b/e2e/features/timeline/timeline-mobile-test.spec.js
index 5c7d6909e..84b08ae4b 100644
--- a/e2e/features/timeline/timeline-mobile-test.spec.js
+++ b/e2e/features/timeline/timeline-mobile-test.spec.js
@@ -3,8 +3,41 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @typedef {import('@playwright/test').Page} Page */
+/** @typedef {import('@playwright/test').Locator} Locator */
+
+/** @type {Page} */
let page
+/** @type {Record<string, Locator>} */
let selectors
+/**
+ * Open the mobile date picker and wait until the modal is visible.
+ * @param {Page} page
+ * @param {Locator} mobileDatePickerSelectBtn
+ */
+async function openMobileDatePicker (page, mobileDatePickerSelectBtn) {
+ await expect(mobileDatePickerSelectBtn).toBeVisible({ timeout: 5000 })
+ await mobileDatePickerSelectBtn.scrollIntoViewIfNeeded()
+
+ const modal = page.locator('.datepicker-modal')
+ const picker = page.locator('.datepicker-modal .datepicker')
+
+ if (await modal.isVisible().catch(() => false)) {
+ await expect(picker).toBeVisible({ timeout: 5000 })
+ return
+ }
+
+ // CI can occasionally miss the first tap/click on mobile view;
+ // fall back to a direct DOM click (bypasses hit-target issues).
+ try {
+ await mobileDatePickerSelectBtn.click({ timeout: 3000 })
+ } catch (e) {
+ await mobileDatePickerSelectBtn.dispatchEvent('click')
+ }
+
+ await expect(modal).toBeVisible({ timeout: 8000 })
+ await expect(picker).toBeVisible({ timeout: 8000 })
+}
test.describe.configure({ mode: 'serial' })
@@ -60,7 +93,10 @@ test('date.mob.range.1: Date label should show 2013-03-15', async () => {
test('date.mob.range.2: mobile selector header should show 2013 MAR 15', async () => {
const { mobileDatePickerSelectBtn, mobileDatePickerHeader } = selectors
- await mobileDatePickerSelectBtn.click()
+ const queryString = 'http://localhost:3000/?now=2013-03-15T12'
+ await page.goto(queryString)
+ await closeModal(page)
+ await openMobileDatePicker(page, mobileDatePickerSelectBtn)
await expect(mobileDatePickerHeader).toContainText('2013 MAR 15')
})
@@ -116,7 +152,10 @@ test('date.mob.nav.1: Date label should show 2013 JUL 20', async () => {
test('date.mob.nav.2a: mobile selector header should show 2013 JUL 20', async () => {
const { mobileDatePickerHeader, mobileDatePickerSelectBtn } = selectors
- await mobileDatePickerSelectBtn.click()
+ const queryString = 'http://localhost:3000/?now=2014-03-15&t=2013-07-20T12'
+ await page.goto(queryString)
+ await closeModal(page)
+ await openMobileDatePicker(page, mobileDatePickerSelectBtn)
await expect(mobileDatePickerHeader).toContainText('2013 JUL 20')
})
diff --git a/e2e/features/timeline/timeline-test.spec.js b/e2e/features/timeline/timeline-test.spec.js
index f762342b4..2e35bf3a7 100644
--- a/e2e/features/timeline/timeline-test.spec.js
+++ b/e2e/features/timeline/timeline-test.spec.js
@@ -8,9 +8,10 @@ const {
} = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/tour/tour-test.spec.js b/e2e/features/tour/tour-test.spec.js
index 73676573f..d7aeb6c8e 100644
--- a/e2e/features/tour/tour-test.spec.js
+++ b/e2e/features/tour/tour-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/ui/distraction-free-mode-test.spec.js b/e2e/features/ui/distraction-free-mode-test.spec.js
index 0984f5e1f..5ef959023 100644
--- a/e2e/features/ui/distraction-free-mode-test.spec.js
+++ b/e2e/features/ui/distraction-free-mode-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/ui/info-mobile-test.spec.js b/e2e/features/ui/info-mobile-test.spec.js
index 242121848..3e8b16caf 100644
--- a/e2e/features/ui/info-mobile-test.spec.js
+++ b/e2e/features/ui/info-mobile-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/ui/info-test.spec.js b/e2e/features/ui/info-test.spec.js
index db2daf944..0fe7a2725 100644
--- a/e2e/features/ui/info-test.spec.js
+++ b/e2e/features/ui/info-test.spec.js
@@ -4,9 +4,10 @@ const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
const { closeModal } = require('../../test-utils/hooks/wvHooks')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/features/ui/toolbar-test.spec.js b/e2e/features/ui/toolbar-test.spec.js
index 60e888013..d4d651ad2 100644
--- a/e2e/features/ui/toolbar-test.spec.js
+++ b/e2e/features/ui/toolbar-test.spec.js
@@ -3,9 +3,10 @@ const { test, expect } = require('@playwright/test')
const createSelectors = require('../../test-utils/global-variables/selectors')
const { skipTour } = require('../../test-utils/global-variables/querystrings')
+/** @type {import('@playwright/test').Page} */
let page
+/** @type {Record<string, import('@playwright/test').Locator>} */
let selectors
-
test.describe.configure({ mode: 'serial' })
test.beforeAll(async ({ browser }) => {
diff --git a/e2e/test-utils/global-variables/selectors.js b/e2e/test-utils/global-variables/selectors.js
index 4d08fdda4..ff507f5fb 100644
--- a/e2e/test-utils/global-variables/selectors.js
+++ b/e2e/test-utils/global-variables/selectors.js
@@ -112,12 +112,12 @@ module.exports = (page) => ({
dragger: page.locator('.timeline-dragger'),
draggerA: page.locator('.timeline-dragger.draggerA'),
draggerB: page.locator('.timeline-dragger.draggerB'),
- dayDown: page.locator('.input-wrapper-day > button.date-arrows.date-arrow-down'),
- dayUp: page.locator('.input-wrapper-day > button.date-arrows.date-arrow-up'),
- monthDown: page.locator('.input-wrapper-month > button.date-arrows.date-arrow-down'),
- monthUp: page.locator('.input-wrapper-month > button.date-arrows.date-arrow-up'),
- yearDown: page.locator('.input-wrapper-year > button.date-arrows.date-arrow-down'),
- yearUp: page.locator('.input-wrapper-year > button.date-arrows.date-arrow-up'),
+ dayDown: page.locator('#date-selector-main .input-wrapper-day > button.date-arrows.date-arrow-down'),
+ dayUp: page.locator('#date-selector-main .input-wrapper-day > button.date-arrows.date-arrow-up'),
+ monthDown: page.locator('#date-selector-main .input-wrapper-month > button.date-arrows.date-arrow-down'),
+ monthUp: page.locator('#date-selector-main .input-wrapper-month > button.date-arrows.date-arrow-up'),
+ yearDown: page.locator('#date-selector-main .input-wrapper-year > button.date-arrows.date-arrow-down'),
+ yearUp: page.locator('#date-selector-main .input-wrapper-year > button.date-arrows.date-arrow-up'),
datePickerWheel: page.locator('.datepicker-modal .datepicker-wheel'),
dateSelectorDayInput: page.locator('#date-selector-main .input-wrapper-day input'),
dateSelectorMonthInput: page.locator('#date-selector-main .input-wrapper-month input'),
@@ -126,7 +126,7 @@ module.exports = (page) => ({
dateSelectorMinuteInput: page.locator('#date-selector-main .input-wrapper-minute input'),
mobileDatePickerSelectBtn: page.locator('.mobile-date-picker-select-btn'),
rightArrow: page.locator('#right-arrow-group'),
- mobileDatePickerHeader: page.locator('.datepicker .datepicker-header .datepicker-header'),
+ mobileDatePickerHeader: page.locator('.datepicker-modal .datepicker .datepicker-header .datepicker-header'),
// layers
layersModalCloseButton: page.locator('.layer-btn-close'),
diff --git a/package-lock.json b/package-lock.json
index 38a602db4..6c6f7315d 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -49,22 +49,18 @@
"p-queue": "^9.1.0",
"proj4": "^2.20.3",
"prop-types": "^15.8.1",
- "react": "^18.3.1",
+ "react": "^19.2.4",
"react-device-detect": "^2.2.3",
- "react-dom": "^18.3.1",
+ "react-dom": "^19.2.4",
"react-draggable": "^4.5.0",
"react-image-crop": "^11.0.10",
"react-infinite-scroller": "^1.2.6",
- "react-joyride": "^2.9.3",
- "react-mobile-datepicker": "^4.0.2",
+ "react-joyride": "^3.0.0-7",
"react-redux": "^9.2.0",
"react-resizable": "^3.1.3",
- "react-swipe-to-delete-component": "1.0.5",
- "react-visibility-sensor": "^5.1.1",
"reactstrap": "^9.2.3",
"recharts": "^3.8.0",
"redux": "^5.0.1",
- "redux-location-state": "^2.8.2",
"redux-logger": "^3.0.6",
"redux-thunk": "^3.1.0",
"regenerator-runtime": "^0.14.1",
@@ -122,11 +118,10 @@
"node-fetch": "^2.6.9",
"node-ssh": "^13.2.1",
"npm-run-all": "^4.1.5",
- "patch-package": "^8.0.0",
"postcss": "^8.5.8",
"postcss-loader": "^8.2.1",
"react-refresh": "^0.18.0",
- "react-test-renderer": "^18.3.1",
+ "react-test-renderer": "^19.2.4",
"redux-mock-store": "^1.5.5",
"run-script-os": "^1.1.6",
"sass": "^1.98.0",
@@ -2572,6 +2567,7 @@
"version": "4.9.1",
"resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.9.1.tgz",
"integrity": "sha512-phrYmNiYppR7znFEdqgfWHXR6NCkZEK7hwWDHZUjit/2/U0r6XvkDl0SYnoM51Hq7FhCGdLDT6zxCCOY1hexsQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"eslint-visitor-keys": "^3.4.3"
@@ -2590,6 +2586,7 @@
"version": "3.4.3",
"resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz",
"integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": "^12.22.0 || ^14.17.0 || >=16.0.0"
@@ -2602,6 +2599,7 @@
"version": "4.12.2",
"resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.12.2.tgz",
"integrity": "sha512-EriSTlt5OC9/7SXkRSCAhfSxxoSUgBm33OH+IkwbdpgoqsSsUg7y3uh+IICI/Qg4BBWr3U2i39RpmycbxMq4ew==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": "^12.0.0 || ^14.0.0 || >=16.0.0"
@@ -2611,6 +2609,7 @@
"version": "0.21.1",
"resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.21.1.tgz",
"integrity": "sha512-aw1gNayWpdI/jSYVgzN5pL0cfzU02GT3NBpeT/DXbx1/1x7ZKxFPd9bwrzygx/qiwIQiJ1sw/zD8qY/kRvlGHA==",
+ "dev": true,
"license": "Apache-2.0",
"dependencies": {
"@eslint/object-schema": "^2.1.7",
@@ -2625,6 +2624,7 @@
"version": "0.4.2",
"resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.4.2.tgz",
"integrity": "sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==",
+ "dev": true,
"license": "Apache-2.0",
"dependencies": {
"@eslint/core": "^0.17.0"
@@ -2637,6 +2637,7 @@
"version": "0.17.0",
"resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz",
"integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==",
+ "dev": true,
"license": "Apache-2.0",
"dependencies": {
"@types/json-schema": "^7.0.15"
@@ -2649,6 +2650,7 @@
"version": "3.3.4",
"resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-3.3.4.tgz",
"integrity": "sha512-4h4MVF8pmBsncB60r0wSJiIeUKTSD4m7FmTFThG8RHlsg9ajqckLm9OraguFGZE4vVdpiI1Q4+hFnisopmG6gQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"ajv": "^6.14.0",
@@ -2672,6 +2674,7 @@
"version": "6.14.0",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-6.14.0.tgz",
"integrity": "sha512-IWrosm/yrn43eiKqkfkHis7QioDleaXQHdDVPKg0FSwwd/DuvyX79TZnFOnYpB7dcsFAMmtFztZuXPDvSePkFw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"fast-deep-equal": "^3.1.1",
@@ -2688,6 +2691,7 @@
"version": "14.0.0",
"resolved": "https://registry.npmjs.org/globals/-/globals-14.0.0.tgz",
"integrity": "sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=18"
@@ -2700,12 +2704,14 @@
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
"integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@eslint/js": {
"version": "9.39.3",
"resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.3.tgz",
"integrity": "sha512-1B1VkCq6FuUNlQvlBYb+1jDu/gV297TIs/OeiaSR9l1H27SVW55ONE1e1Vp16NqP683+xEGzxYtv4XCiDPaQiw==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -2718,6 +2724,7 @@
"version": "2.1.7",
"resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-2.1.7.tgz",
"integrity": "sha512-VtAOaymWVfZcmZbp6E2mympDIHvyjXs/12LqWYjVw6qjrfF+VK+fyG33kChz3nnK+SU5/NeHOqrTEHS8sXO3OA==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -2727,6 +2734,7 @@
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.1.tgz",
"integrity": "sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==",
+ "dev": true,
"license": "Apache-2.0",
"dependencies": {
"@eslint/core": "^0.17.0",
@@ -2825,10 +2833,44 @@
"integrity": "sha512-I7xWjLs2YSVMc5gGx1Z3ZG1lgFpITPndpi8Ku55GeEIKpACCPQNS/OTqQbxgTCfq0Ncvcc+CrFov96itVh6Qvw==",
"license": "MIT"
},
+ "node_modules/@gilbarbara/hooks": {
+ "version": "0.8.2",
+ "resolved": "https://registry.npmjs.org/@gilbarbara/hooks/-/hooks-0.8.2.tgz",
+ "integrity": "sha512-aWXlJFCrqmasGaDd6IhSpqOFeOD4pSBpRtILKw0WxWQzWE+HYCA0adLf0P18BNztR/G0byWnpkGupeGx+NFnuw==",
+ "license": "MIT",
+ "dependencies": {
+ "@gilbarbara/deep-equal": "^0.3.1"
+ },
+ "peerDependencies": {
+ "react": "16.8 - 18"
+ }
+ },
+ "node_modules/@gilbarbara/types": {
+ "version": "0.2.2",
+ "resolved": "https://registry.npmjs.org/@gilbarbara/types/-/types-0.2.2.tgz",
+ "integrity": "sha512-QuQDBRRcm1Q8AbSac2W1YElurOhprj3Iko/o+P1fJxUWS4rOGKMVli98OXS7uo4z+cKAif6a+L9bcZFSyauQpQ==",
+ "license": "MIT",
+ "dependencies": {
+ "type-fest": "^4.1.0"
+ }
+ },
+ "node_modules/@gilbarbara/types/node_modules/type-fest": {
+ "version": "4.41.0",
+ "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.41.0.tgz",
+ "integrity": "sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==",
+ "license": "(MIT OR CC0-1.0)",
+ "engines": {
+ "node": ">=16"
+ },
+ "funding": {
+ "url": "https://github.com/sponsors/sindresorhus"
+ }
+ },
"node_modules/@humanfs/core": {
"version": "0.19.1",
"resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.1.tgz",
"integrity": "sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": ">=18.18.0"
@@ -2838,6 +2880,7 @@
"version": "0.16.7",
"resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.7.tgz",
"integrity": "sha512-/zUx+yOsIrG4Y43Eh2peDeKCxlRt/gET6aHfaKpuq267qXdYDFViVHfMaLyygZOnl0kGWxFIgsBy8QFuTLUXEQ==",
+ "dev": true,
"license": "Apache-2.0",
"dependencies": {
"@humanfs/core": "^0.19.1",
@@ -2862,6 +2905,7 @@
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz",
"integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": ">=12.22"
@@ -2875,6 +2919,7 @@
"version": "0.4.3",
"resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.4.3.tgz",
"integrity": "sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": ">=18.18"
@@ -3583,6 +3628,7 @@
"version": "0.3.11",
"resolved": "https://registry.npmjs.org/@jridgewell/source-map/-/source-map-0.3.11.tgz",
"integrity": "sha512-ZMp1V8ZFcPG5dIWnQLr3NSI1MiCU7UETdS/A0G8V/XWHvJv3ZsFqutJn1Y5RPmAPX6F3BiE397OqveU/9NCuIA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@jridgewell/gen-mapping": "^0.3.5",
@@ -5014,6 +5060,7 @@
"version": "9.6.1",
"resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-9.6.1.tgz",
"integrity": "sha512-FXx2pKgId/WyYo2jXw63kk7/+TY7u7AziEJxJAnSFzHlqTAS3Ync6SvgYAN/k4/PQpnnVuzoMuVnByKK2qp0ag==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@types/estree": "*",
@@ -5024,6 +5071,7 @@
"version": "3.7.7",
"resolved": "https://registry.npmjs.org/@types/eslint-scope/-/eslint-scope-3.7.7.tgz",
"integrity": "sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@types/eslint": "*",
@@ -5034,6 +5082,7 @@
"version": "1.0.8",
"resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz",
"integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@types/express": {
@@ -5133,6 +5182,7 @@
"version": "7.0.15",
"resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz",
"integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@types/json5": {
@@ -5160,6 +5210,7 @@
"version": "25.3.3",
"resolved": "https://registry.npmjs.org/@types/node/-/node-25.3.3.tgz",
"integrity": "sha512-DpzbrH7wIcBaJibpKo9nnSQL0MTRdnWttGyE5haGwK86xgMOkFLp7vEyfQPGLOJh5wNYiJ3V9PmUMDhV9u8kkQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"undici-types": "~7.18.0"
@@ -5191,16 +5242,6 @@
"integrity": "sha512-+N+2H39P8X+Hy1I5mC6awlTX54k3FhiUmvt7HWzGJZvF+syUAAxP/stwppS8JE84YHqFgRMv6fCy31202CMFxQ==",
"license": "MIT"
},
- "node_modules/@types/react": {
- "version": "19.2.14",
- "resolved": "https://registry.npmjs.org/@types/react/-/react-19.2.14.tgz",
- "integrity": "sha512-ilcTH/UniCkMdtexkoCN0bI7pMcJDvmQFPvuPvmEaYA/NSfFTAgdUSLAoVjaRJm7+6PvcM+q1zYOwS4wTYMF9w==",
- "license": "MIT",
- "peer": true,
- "dependencies": {
- "csstype": "^3.2.2"
- }
- },
"node_modules/@types/react-transition-group": {
"version": "4.4.12",
"resolved": "https://registry.npmjs.org/@types/react-transition-group/-/react-transition-group-4.4.12.tgz",
@@ -5712,9 +5753,6 @@
"arm64"
],
"dev": true,
- "libc": [
- "glibc"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5729,9 +5767,6 @@
"arm64"
],
"dev": true,
- "libc": [
- "musl"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5746,9 +5781,6 @@
"ppc64"
],
"dev": true,
- "libc": [
- "glibc"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5763,9 +5795,6 @@
"riscv64"
],
"dev": true,
- "libc": [
- "glibc"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5780,9 +5809,6 @@
"riscv64"
],
"dev": true,
- "libc": [
- "musl"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5797,9 +5823,6 @@
"s390x"
],
"dev": true,
- "libc": [
- "glibc"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5814,9 +5837,6 @@
"x64"
],
"dev": true,
- "libc": [
- "glibc"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5831,9 +5851,6 @@
"x64"
],
"dev": true,
- "libc": [
- "musl"
- ],
"license": "MIT",
"optional": true,
"os": [
@@ -5903,6 +5920,7 @@
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.14.1.tgz",
"integrity": "sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/helper-numbers": "1.13.2",
@@ -5913,24 +5931,28 @@
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/floating-point-hex-parser/-/floating-point-hex-parser-1.13.2.tgz",
"integrity": "sha512-6oXyTOzbKxGH4steLbLNOu71Oj+C8Lg34n6CqRvqfS2O71BxY6ByfMDRhBytzknj9yGUPVJ1qIKhRlAwO1AovA==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@webassemblyjs/helper-api-error": {
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-api-error/-/helper-api-error-1.13.2.tgz",
"integrity": "sha512-U56GMYxy4ZQCbDZd6JuvvNV/WFildOjsaWD3Tzzvmw/mas3cXzRJPMjP83JqEsgSbyrmaGjBfDtV7KDXV9UzFQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@webassemblyjs/helper-buffer": {
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-buffer/-/helper-buffer-1.14.1.tgz",
"integrity": "sha512-jyH7wtcHiKssDtFPRB+iQdxlDf96m0E39yb0k5uJVhFGleZFoNw1c4aeIcVUPPbXUVJ94wwnMOAqUHyzoEPVMA==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@webassemblyjs/helper-numbers": {
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-numbers/-/helper-numbers-1.13.2.tgz",
"integrity": "sha512-FE8aCmS5Q6eQYcV3gI35O4J789wlQA+7JrqTTpJqn5emA4U2hvwJmvFRC0HODS+3Ye6WioDklgd6scJ3+PLnEA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/floating-point-hex-parser": "1.13.2",
@@ -5942,12 +5964,14 @@
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-bytecode/-/helper-wasm-bytecode-1.13.2.tgz",
"integrity": "sha512-3QbLKy93F0EAIXLh0ogEVR6rOubA9AoZ+WRYhNbFyuB70j3dRdwH9g+qXhLAO0kiYGlg3TxDV+I4rQTr/YNXkA==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@webassemblyjs/helper-wasm-section": {
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/helper-wasm-section/-/helper-wasm-section-1.14.1.tgz",
"integrity": "sha512-ds5mXEqTJ6oxRoqjhWDU83OgzAYjwsCV8Lo/N+oRsNDmx/ZDpqalmrtgOMkHwxsG0iI//3BwWAErYRHtgn0dZw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/ast": "1.14.1",
@@ -5960,6 +5984,7 @@
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/ieee754/-/ieee754-1.13.2.tgz",
"integrity": "sha512-4LtOzh58S/5lX4ITKxnAK2USuNEvpdVV9AlgGQb8rJDHaLeHciwG4zlGr0j/SNWlr7x3vO1lDEsuePvtcDNCkw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@xtuc/ieee754": "^1.2.0"
@@ -5969,6 +5994,7 @@
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/leb128/-/leb128-1.13.2.tgz",
"integrity": "sha512-Lde1oNoIdzVzdkNEAWZ1dZ5orIbff80YPdHx20mrHwHrVNNTjNr8E3xz9BdpcGqRQbAEa+fkrCb+fRFTl/6sQw==",
+ "dev": true,
"license": "Apache-2.0",
"dependencies": {
"@xtuc/long": "4.2.2"
@@ -5978,12 +6004,14 @@
"version": "1.13.2",
"resolved": "https://registry.npmjs.org/@webassemblyjs/utf8/-/utf8-1.13.2.tgz",
"integrity": "sha512-3NQWGjKTASY1xV5m7Hr0iPeXD9+RDobLll3T9d2AO+g3my8xy5peVyjSag4I50mR1bBSN/Ct12lo+R9tJk0NZQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/@webassemblyjs/wasm-edit": {
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-edit/-/wasm-edit-1.14.1.tgz",
"integrity": "sha512-RNJUIQH/J8iA/1NzlE4N7KtyZNHi3w7at7hDjvRNm5rcUXa00z1vRz3glZoULfJ5mpvYhLybmVcwcjGrC1pRrQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/ast": "1.14.1",
@@ -6000,6 +6028,7 @@
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-gen/-/wasm-gen-1.14.1.tgz",
"integrity": "sha512-AmomSIjP8ZbfGQhumkNvgC33AY7qtMCXnN6bL2u2Js4gVCg8fp735aEiMSBbDR7UQIj90n4wKAFUSEd0QN2Ukg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/ast": "1.14.1",
@@ -6013,6 +6042,7 @@
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-opt/-/wasm-opt-1.14.1.tgz",
"integrity": "sha512-PTcKLUNvBqnY2U6E5bdOQcSM+oVP/PmrDY9NzowJjislEjwP/C4an2303MCVS2Mg9d3AJpIGdUFIQQWbPds0Sw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/ast": "1.14.1",
@@ -6025,6 +6055,7 @@
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wasm-parser/-/wasm-parser-1.14.1.tgz",
"integrity": "sha512-JLBl+KZ0R5qB7mCnud/yyX08jWFw5MsoalJ1pQ4EdFlgj9VdXKGuENGsiCIjegI1W7p91rUlcB/LB5yRJKNTcQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/ast": "1.14.1",
@@ -6039,6 +6070,7 @@
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/@webassemblyjs/wast-printer/-/wast-printer-1.14.1.tgz",
"integrity": "sha512-kPSSXE6De1XOR820C90RIo2ogvZG+c3KiHzqUoO/F34Y2shGzesfqv7o57xrxovZJH/MetF5UjroJ/R/3isoiw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@webassemblyjs/ast": "1.14.1",
@@ -6096,20 +6128,15 @@
"version": "1.2.0",
"resolved": "https://registry.npmjs.org/@xtuc/ieee754/-/ieee754-1.2.0.tgz",
"integrity": "sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==",
+ "dev": true,
"license": "BSD-3-Clause"
},
"node_modules/@xtuc/long": {
"version": "4.2.2",
"resolved": "https://registry.npmjs.org/@xtuc/long/-/long-4.2.2.tgz",
"integrity": "sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==",
- "license": "Apache-2.0"
- },
- "node_modules/@yarnpkg/lockfile": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/@yarnpkg/lockfile/-/lockfile-1.1.0.tgz",
- "integrity": "sha512-GpSwvyXOcOOlV70vbnzjj4fW5xW/FdUF6nQEt1ENy7m4ZCczi1+/buVUPAqmGfqznsORNFzUMjctTIp8a9tuCQ==",
"dev": true,
- "license": "BSD-2-Clause"
+ "license": "Apache-2.0"
},
"node_modules/@zarrita/storage": {
"version": "0.1.4",
@@ -6149,6 +6176,7 @@
"version": "8.16.0",
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.16.0.tgz",
"integrity": "sha512-UVJyE9MttOsBQIDKw1skb9nAwQuR5wuGD3+82K6JgJlm/Y+KI92oNsMNGZCYdDsVtRHSak0pcV5Dno5+4jh9sw==",
+ "dev": true,
"license": "MIT",
"bin": {
"acorn": "bin/acorn"
@@ -6161,6 +6189,7 @@
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/acorn-import-phases/-/acorn-import-phases-1.0.4.tgz",
"integrity": "sha512-wKmbr/DDiIXzEOiWrTTUcDm24kQ2vGfZQvM2fwg2vXqR5uW6aapr7ObPtj1th32b9u90/Pf4AItvdTh42fBmVQ==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=10.13.0"
@@ -6173,6 +6202,7 @@
"version": "5.3.2",
"resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz",
"integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==",
+ "dev": true,
"license": "MIT",
"peerDependencies": {
"acorn": "^6.0.0 || ^7.0.0 || ^8.0.0"
@@ -6205,6 +6235,7 @@
"version": "8.18.0",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-8.18.0.tgz",
"integrity": "sha512-PlXPeEWMXMZ7sPYOHqmDyCJzcfNrUr3fGNKtezX14ykXOEIvyK81d+qydx89KY5O71FKMPaQ2vBfBFI5NHR63A==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"fast-deep-equal": "^3.1.3",
@@ -6221,6 +6252,7 @@
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/ajv-formats/-/ajv-formats-2.1.1.tgz",
"integrity": "sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"ajv": "^8.0.0"
@@ -6238,6 +6270,7 @@
"version": "5.1.0",
"resolved": "https://registry.npmjs.org/ajv-keywords/-/ajv-keywords-5.1.0.tgz",
"integrity": "sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"fast-deep-equal": "^3.1.3"
@@ -6296,6 +6329,7 @@
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"color-convert": "^2.0.1"
@@ -6338,6 +6372,7 @@
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
"integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==",
+ "dev": true,
"license": "Python-2.0"
},
"node_modules/aria-query": {
@@ -6902,6 +6937,7 @@
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz",
"integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/baseline-browser-mapping": {
@@ -7051,6 +7087,7 @@
"version": "1.1.12",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.12.tgz",
"integrity": "sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"balanced-match": "^1.0.0",
@@ -7117,6 +7154,7 @@
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz",
"integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/buildcheck": {
@@ -7299,6 +7337,7 @@
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"ansi-styles": "^4.1.0",
@@ -7395,6 +7434,7 @@
"version": "1.0.4",
"resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.4.tgz",
"integrity": "sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=6.0"
@@ -7573,6 +7613,7 @@
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"color-name": "~1.1.4"
@@ -7585,6 +7626,7 @@
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
+ "dev": true,
"license": "MIT"
},
"node_modules/colord": {
@@ -7678,6 +7720,7 @@
"version": "0.0.1",
"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
"integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==",
+ "dev": true,
"license": "MIT"
},
"node_modules/connect-history-api-fallback": {
@@ -7862,6 +7905,7 @@
"version": "7.0.6",
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.6.tgz",
"integrity": "sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"path-key": "^3.1.0",
@@ -8441,13 +8485,6 @@
}
}
},
- "node_modules/deep-diff": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/deep-diff/-/deep-diff-1.0.2.tgz",
- "integrity": "sha512-aWS3UIVH+NPGCD1kki+DCU9Dua032iSsO43LqQpcs4R3+dVv7tX0qBGjiVHJHjplsoUM2XRO/KB92glqc68awg==",
- "deprecated": "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.",
- "license": "MIT"
- },
"node_modules/deep-equal": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-1.1.2.tgz",
@@ -8472,6 +8509,7 @@
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz",
"integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/deepmerge": {
@@ -8483,6 +8521,15 @@
"node": ">=0.10.0"
}
},
+ "node_modules/deepmerge-ts": {
+ "version": "7.1.5",
+ "resolved": "https://registry.npmjs.org/deepmerge-ts/-/deepmerge-ts-7.1.5.tgz",
+ "integrity": "sha512-HOJkrhaYsweh+W+e74Yn7YStZOilkoPb6fycpwNLKzSPtruFs48nYis0zy5yJz1+ktUhHxoRDJ27RQAWLIJVJw==",
+ "license": "BSD-3-Clause",
+ "engines": {
+ "node": ">=16.0.0"
+ }
+ },
"node_modules/default-browser": {
"version": "5.5.0",
"resolved": "https://registry.npmjs.org/default-browser/-/default-browser-5.5.0.tgz",
@@ -8901,6 +8948,7 @@
"version": "5.20.0",
"resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.20.0.tgz",
"integrity": "sha512-/ce7+jQ1PQ6rVXwe+jKEg5hW5ciicHwIQUagZkp6IufBoY3YDgdTTY1azVs0qoRgVmvsNB+rbjLJxDAeHHtwsQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"graceful-fs": "^4.2.4",
@@ -9084,6 +9132,7 @@
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-2.0.0.tgz",
"integrity": "sha512-5POEcUuZybH7IdmGsD8wlf0AI55wMecM9rVBTI/qEAy2c1kTOm3DjFYjrBdI2K3BaJjJYfYFeRtM0t9ssnRuxw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/es-object-atoms": {
@@ -9186,6 +9235,7 @@
"version": "9.39.3",
"resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.3.tgz",
"integrity": "sha512-VmQ+sifHUbI/IcSopBCF/HO3YiHQx/AVd3UVyYL6weuwW+HvON9VYn5l6Zl1WZzPWXPNZrSQpxwkkZ/VuvJZzg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@eslint-community/eslint-utils": "^4.8.0",
@@ -9717,6 +9767,7 @@
"version": "5.1.1",
"resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz",
"integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==",
+ "dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"esrecurse": "^4.3.0",
@@ -9730,6 +9781,7 @@
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz",
"integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==",
+ "dev": true,
"license": "BSD-2-Clause",
"engines": {
"node": ">=4.0"
@@ -9775,6 +9827,7 @@
"version": "6.14.0",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-6.14.0.tgz",
"integrity": "sha512-IWrosm/yrn43eiKqkfkHis7QioDleaXQHdDVPKg0FSwwd/DuvyX79TZnFOnYpB7dcsFAMmtFztZuXPDvSePkFw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"fast-deep-equal": "^3.1.1",
@@ -9791,6 +9844,7 @@
"version": "8.4.0",
"resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-8.4.0.tgz",
"integrity": "sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==",
+ "dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"esrecurse": "^4.3.0",
@@ -9807,6 +9861,7 @@
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.1.tgz",
"integrity": "sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -9819,12 +9874,14 @@
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
"integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==",
+ "dev": true,
"license": "MIT"
},
"node_modules/espree": {
"version": "10.4.0",
"resolved": "https://registry.npmjs.org/espree/-/espree-10.4.0.tgz",
"integrity": "sha512-j6PAQ2uUr79PZhBjP5C5fhl8e39FmRnOjsD5lGnWrFU8i2G776tBK7+nP8KuQUTTyAZUwfQqXAgrVH5MbH9CYQ==",
+ "dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"acorn": "^8.15.0",
@@ -9842,6 +9899,7 @@
"version": "4.2.1",
"resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-4.2.1.tgz",
"integrity": "sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==",
+ "dev": true,
"license": "Apache-2.0",
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
@@ -9868,6 +9926,7 @@
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/esquery/-/esquery-1.7.0.tgz",
"integrity": "sha512-Ap6G0WQwcU/LHsvLwON1fAQX9Zp0A2Y6Y/cJBl9r/JbW90Zyg4/zbG6zzKa2OTALELarYHmKu0GhpM5EO+7T0g==",
+ "dev": true,
"license": "BSD-3-Clause",
"dependencies": {
"estraverse": "^5.1.0"
@@ -9880,6 +9939,7 @@
"version": "4.3.0",
"resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz",
"integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==",
+ "dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"estraverse": "^5.2.0"
@@ -9892,6 +9952,7 @@
"version": "5.3.0",
"resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz",
"integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==",
+ "dev": true,
"license": "BSD-2-Clause",
"engines": {
"node": ">=4.0"
@@ -9901,6 +9962,7 @@
"version": "2.0.3",
"resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz",
"integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==",
+ "dev": true,
"license": "BSD-2-Clause",
"engines": {
"node": ">=0.10.0"
@@ -9932,6 +9994,7 @@
"version": "3.3.0",
"resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz",
"integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=0.8.x"
@@ -10037,6 +10100,7 @@
"version": "3.1.3",
"resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
"integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
+ "dev": true,
"license": "MIT"
},
"node_modules/fast-glob": {
@@ -10073,18 +10137,21 @@
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz",
"integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/fast-levenshtein": {
"version": "2.0.6",
"resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz",
"integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/fast-uri": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.0.tgz",
"integrity": "sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==",
+ "dev": true,
"funding": [
{
"type": "github",
@@ -10168,6 +10235,7 @@
"version": "8.0.0",
"resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz",
"integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"flat-cache": "^4.0.0"
@@ -10227,6 +10295,7 @@
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz",
"integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"locate-path": "^6.0.0",
@@ -10239,16 +10308,6 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
- "node_modules/find-yarn-workspace-root": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/find-yarn-workspace-root/-/find-yarn-workspace-root-2.0.0.tgz",
- "integrity": "sha512-1IMnbjt4KzsQfnhnzNd8wUEgXZ44IzZaZmnLYx7D5FZlaHt2gW20Cri8Q+E/t5tIj4+epTBub+2Zxu/vNILzqQ==",
- "dev": true,
- "license": "Apache-2.0",
- "dependencies": {
- "micromatch": "^4.0.2"
- }
- },
"node_modules/fizzy-ui-utils": {
"version": "2.0.7",
"resolved": "https://registry.npmjs.org/fizzy-ui-utils/-/fizzy-ui-utils-2.0.7.tgz",
@@ -10272,6 +10331,7 @@
"version": "4.0.1",
"resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz",
"integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"flatted": "^3.2.9",
@@ -10282,9 +10342,10 @@
}
},
"node_modules/flatted": {
- "version": "3.3.4",
- "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.3.4.tgz",
- "integrity": "sha512-3+mMldrTAPdta5kjX2G2J7iX4zxtnwpdA8Tr2ZSjkyPSanvbZAcy6flmtnXbEybHrDcU9641lxrMfFuUxVz9vA==",
+ "version": "3.4.1",
+ "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.4.1.tgz",
+ "integrity": "sha512-IxfVbRFVlV8V/yRaGzk0UVIcsKKHMSfYw66T/u4nTwlWteQePsxe//LjudR1AMX4tZW3WFCh3Zqa/sjlqpbURQ==",
+ "dev": true,
"license": "ISC"
},
"node_modules/follow-redirects": {
@@ -10424,21 +10485,6 @@
"node": ">= 0.8"
}
},
- "node_modules/fs-extra": {
- "version": "10.1.0",
- "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz",
- "integrity": "sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "graceful-fs": "^4.2.0",
- "jsonfile": "^6.0.1",
- "universalify": "^2.0.0"
- },
- "engines": {
- "node": ">=12"
- }
- },
"node_modules/fs.realpath": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz",
@@ -10700,6 +10746,7 @@
"version": "6.0.2",
"resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz",
"integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==",
+ "dev": true,
"license": "ISC",
"dependencies": {
"is-glob": "^4.0.3"
@@ -10729,6 +10776,7 @@
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz",
"integrity": "sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==",
+ "dev": true,
"license": "BSD-2-Clause"
},
"node_modules/glob/node_modules/balanced-match": {
@@ -10920,6 +10968,7 @@
"version": "4.2.11",
"resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz",
"integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==",
+ "dev": true,
"license": "ISC"
},
"node_modules/handle-thing": {
@@ -10946,6 +10995,7 @@
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
@@ -11396,6 +11446,7 @@
"version": "5.3.2",
"resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz",
"integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">= 4"
@@ -11483,6 +11534,7 @@
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz",
"integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=0.8.19"
@@ -11726,26 +11778,11 @@
"url": "https://github.com/sponsors/ljharb"
}
},
- "node_modules/is-docker": {
- "version": "2.2.1",
- "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz",
- "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==",
- "dev": true,
- "license": "MIT",
- "bin": {
- "is-docker": "cli.js"
- },
- "engines": {
- "node": ">=8"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/is-extglob": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
"integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=0.10.0"
@@ -11811,6 +11848,7 @@
"version": "4.0.3",
"resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
"integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"is-extglob": "^2.1.1"
@@ -12156,19 +12194,6 @@
"url": "https://github.com/sponsors/ljharb"
}
},
- "node_modules/is-wsl": {
- "version": "2.2.0",
- "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz",
- "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "is-docker": "^2.0.0"
- },
- "engines": {
- "node": ">=8"
- }
- },
"node_modules/isarray": {
"version": "2.0.5",
"resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz",
@@ -12180,6 +12205,7 @@
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
"integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==",
+ "dev": true,
"license": "ISC"
},
"node_modules/isobject": {
@@ -13131,7 +13157,7 @@
"version": "2.6.1",
"resolved": "https://registry.npmjs.org/jiti/-/jiti-2.6.1.tgz",
"integrity": "sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==",
- "devOptional": true,
+ "dev": true,
"license": "MIT",
"bin": {
"jiti": "lib/jiti-cli.mjs"
@@ -13147,6 +13173,7 @@
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz",
"integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"argparse": "^2.0.1"
@@ -13257,6 +13284,7 @@
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz",
"integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/json-parse-better-errors": {
@@ -13276,32 +13304,14 @@
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
"integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==",
- "license": "MIT"
- },
- "node_modules/json-stable-stringify": {
- "version": "1.3.0",
- "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.3.0.tgz",
- "integrity": "sha512-qtYiSSFlwot9XHtF9bD9c7rwKjr+RecWT//ZnPvSmEjpV5mmPOCN4j8UjY5hbjNkOwZ/jQv3J6R1/pL7RwgMsg==",
"dev": true,
- "license": "MIT",
- "dependencies": {
- "call-bind": "^1.0.8",
- "call-bound": "^1.0.4",
- "isarray": "^2.0.5",
- "jsonify": "^0.0.1",
- "object-keys": "^1.1.1"
- },
- "engines": {
- "node": ">= 0.4"
- },
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
+ "license": "MIT"
},
"node_modules/json-stable-stringify-without-jsonify": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz",
"integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/json-stringify-pretty-compact": {
@@ -13322,29 +13332,6 @@
"node": ">=6"
}
},
- "node_modules/jsonfile": {
- "version": "6.2.0",
- "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.2.0.tgz",
- "integrity": "sha512-FGuPw30AdOIUTRMC2OMRtQV+jkVj2cfPqSeWXv1NEAJ1qZ5zb1X6z1mFhbfOB/iy3ssJCD+3KuZ8r8C3uVFlAg==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "universalify": "^2.0.0"
- },
- "optionalDependencies": {
- "graceful-fs": "^4.1.6"
- }
- },
- "node_modules/jsonify": {
- "version": "0.0.1",
- "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.1.tgz",
- "integrity": "sha512-2/Ki0GcmuqSrgFyelQq9M05y7PS0mEwuIzrf3f1fPqkVDVRvZrPZtVSMHxdgo8Aq0sxAOb/cr2aqqA3LeWHVPg==",
- "dev": true,
- "license": "Public Domain",
- "funding": {
- "url": "https://github.com/sponsors/ljharb"
- }
- },
"node_modules/jsx-ast-utils": {
"version": "3.3.5",
"resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz",
@@ -13371,6 +13358,7 @@
"version": "4.5.4",
"resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz",
"integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"json-buffer": "3.0.1"
@@ -13386,16 +13374,6 @@
"node": ">=0.10.0"
}
},
- "node_modules/klaw-sync": {
- "version": "6.0.0",
- "resolved": "https://registry.npmjs.org/klaw-sync/-/klaw-sync-6.0.0.tgz",
- "integrity": "sha512-nIeuVSzdCCs6TDPTqI8w1Yre34sSq7AkZ4B3sfOBbI2CgVSB4Du4aLQijFU2+lhAFCwt9+42Hel6lQNIv6AntQ==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "graceful-fs": "^4.1.11"
- }
- },
"node_modules/known-css-properties": {
"version": "0.37.0",
"resolved": "https://registry.npmjs.org/known-css-properties/-/known-css-properties-0.37.0.tgz",
@@ -13454,6 +13432,7 @@
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz",
"integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"prelude-ls": "^1.2.1",
@@ -13536,6 +13515,7 @@
"version": "4.3.1",
"resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.3.1.tgz",
"integrity": "sha512-IWqP2SCPhyVFTBtRcgMHdzlf9ul25NwaFx4wCEH/KjAXuuHY4yNjvPXsBokp8jCB936PyWRaPKUNh8NvylLp2Q==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=6.11.5"
@@ -13577,6 +13557,7 @@
"version": "6.0.0",
"resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz",
"integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"p-locate": "^5.0.0"
@@ -13631,6 +13612,7 @@
"version": "4.6.2",
"resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz",
"integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/lodash.truncate": {
@@ -13777,6 +13759,12 @@
"tslib": "2"
}
},
+ "node_modules/memoize-one": {
+ "version": "6.0.0",
+ "resolved": "https://registry.npmjs.org/memoize-one/-/memoize-one-6.0.0.tgz",
+ "integrity": "sha512-rkpe71W0N0c0Xz6QD0eJETuWAJGnJ9afsl1srmwPrI+yBCkge5EycXXbYRyvL29zZVUWQCY7InPRCv3GDXuZNw==",
+ "license": "MIT"
+ },
"node_modules/memory-fs": {
"version": "0.2.0",
"resolved": "https://registry.npmjs.org/memory-fs/-/memory-fs-0.2.0.tgz",
@@ -13823,6 +13811,7 @@
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-2.0.0.tgz",
"integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==",
+ "dev": true,
"license": "MIT"
},
"node_modules/merge2": {
@@ -13959,6 +13948,7 @@
"version": "3.1.5",
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.5.tgz",
"integrity": "sha512-VgjWUsnnT6n+NUk6eZq77zeFdpW2LWDzP6zFGrCbHXiYNul5Dzqk2HHQ5uFH2DNW5Xbp8+jVzaeNt94ssEEl4w==",
+ "dev": true,
"license": "ISC",
"dependencies": {
"brace-expansion": "^1.1.7"
@@ -14114,6 +14104,7 @@
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz",
"integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/negotiator": {
@@ -14129,6 +14120,7 @@
"version": "2.6.2",
"resolved": "https://registry.npmjs.org/neo-async/-/neo-async-2.6.2.tgz",
"integrity": "sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/neostandard": {
@@ -14320,6 +14312,7 @@
"version": "2.7.0",
"resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz",
"integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"whatwg-url": "^5.0.0"
@@ -14340,18 +14333,21 @@
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz",
"integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==",
+ "dev": true,
"license": "MIT"
},
"node_modules/node-fetch/node_modules/webidl-conversions": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz",
"integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==",
+ "dev": true,
"license": "BSD-2-Clause"
},
"node_modules/node-fetch/node_modules/whatwg-url": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz",
"integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"tr46": "~0.0.3",
@@ -14859,23 +14855,6 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
- "node_modules/open": {
- "version": "7.4.2",
- "resolved": "https://registry.npmjs.org/open/-/open-7.4.2.tgz",
- "integrity": "sha512-MVHddDVweXZF3awtlAS+6pgKLlm/JgxZ90+/NBurBoQctVOOB/zDdVjcyPzQ+0laDGbsWgrRkflI65sQeOgT9Q==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "is-docker": "^2.0.0",
- "is-wsl": "^2.1.1"
- },
- "engines": {
- "node": ">=8"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
"node_modules/opener": {
"version": "1.5.2",
"resolved": "https://registry.npmjs.org/opener/-/opener-1.5.2.tgz",
@@ -14890,6 +14869,7 @@
"version": "0.9.4",
"resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz",
"integrity": "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"deep-is": "^0.1.3",
@@ -14942,6 +14922,7 @@
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz",
"integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"yocto-queue": "^0.1.0"
@@ -14957,6 +14938,7 @@
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz",
"integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"p-limit": "^3.0.2"
@@ -15159,66 +15141,11 @@
"node": ">= 0.8"
}
},
- "node_modules/patch-package": {
- "version": "8.0.1",
- "resolved": "https://registry.npmjs.org/patch-package/-/patch-package-8.0.1.tgz",
- "integrity": "sha512-VsKRIA8f5uqHQ7NGhwIna6Bx6D9s/1iXlA1hthBVBEbkq+t4kXD0HHt+rJhf/Z+Ci0F/HCB2hvn0qLdLG+Qxlw==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "@yarnpkg/lockfile": "^1.1.0",
- "chalk": "^4.1.2",
- "ci-info": "^3.7.0",
- "cross-spawn": "^7.0.3",
- "find-yarn-workspace-root": "^2.0.0",
- "fs-extra": "^10.0.0",
- "json-stable-stringify": "^1.0.2",
- "klaw-sync": "^6.0.0",
- "minimist": "^1.2.6",
- "open": "^7.4.2",
- "semver": "^7.5.3",
- "slash": "^2.0.0",
- "tmp": "^0.2.4",
- "yaml": "^2.2.2"
- },
- "bin": {
- "patch-package": "index.js"
- },
- "engines": {
- "node": ">=14",
- "npm": ">5"
- }
- },
- "node_modules/patch-package/node_modules/ci-info": {
- "version": "3.9.0",
- "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-3.9.0.tgz",
- "integrity": "sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ==",
- "dev": true,
- "funding": [
- {
- "type": "github",
- "url": "https://github.com/sponsors/sibiraj-s"
- }
- ],
- "license": "MIT",
- "engines": {
- "node": ">=8"
- }
- },
- "node_modules/patch-package/node_modules/slash": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/slash/-/slash-2.0.0.tgz",
- "integrity": "sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==",
- "dev": true,
- "license": "MIT",
- "engines": {
- "node": ">=6"
- }
- },
"node_modules/path-exists": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz",
"integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
@@ -15245,6 +15172,7 @@
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz",
"integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
@@ -15549,17 +15477,6 @@
"node": "^8.16.0 || ^10.6.0 || >=11.0.0"
}
},
- "node_modules/popper.js": {
- "version": "1.16.1",
- "resolved": "https://registry.npmjs.org/popper.js/-/popper.js-1.16.1.tgz",
- "integrity": "sha512-Wb4p1J4zyFTbM+u6WuO4XstYx4Ky9Cewe4DWrel7B0w6VVICvPwdOpotjzcf6eD8TsckVnIMNONQyPIUFOUbCQ==",
- "deprecated": "You can find the new Popper v2 at @popperjs/core, this package is dedicated to the legacy v1",
- "license": "MIT",
- "funding": {
- "type": "opencollective",
- "url": "https://opencollective.com/popperjs"
- }
- },
"node_modules/possible-typed-array-names": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz",
@@ -16225,6 +16142,7 @@
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
"integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.8.0"
@@ -16339,6 +16257,7 @@
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz",
"integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=6"
@@ -16536,13 +16455,10 @@
"license": "MIT"
},
"node_modules/react": {
- "version": "18.3.1",
- "resolved": "https://registry.npmjs.org/react/-/react-18.3.1.tgz",
- "integrity": "sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ==",
+ "version": "19.2.4",
+ "resolved": "https://registry.npmjs.org/react/-/react-19.2.4.tgz",
+ "integrity": "sha512-9nfp2hYpCwOjAN+8TZFGhtWEwgvWHXqESH8qT89AT/lWklpLON22Lc8pEtnpsZz7VmawabSU0gCjnj8aC0euHQ==",
"license": "MIT",
- "dependencies": {
- "loose-envify": "^1.1.0"
- },
"engines": {
"node": ">=0.10.0"
}
@@ -16561,16 +16477,15 @@
}
},
"node_modules/react-dom": {
- "version": "18.3.1",
- "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.3.1.tgz",
- "integrity": "sha512-5m4nQKp+rZRb09LNH59GM4BxTh9251/ylbKIbpe7TpGxfJ+9kv6BLkLBXIjjspbgbnIBNqlI23tRnTWT0snUIw==",
+ "version": "19.2.4",
+ "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.2.4.tgz",
+ "integrity": "sha512-AXJdLo8kgMbimY95O2aKQqsz2iWi9jMgKJhRBAxECE4IFxfcazB2LmzloIoibJI3C12IlY20+KFaLv+71bUJeQ==",
"license": "MIT",
"dependencies": {
- "loose-envify": "^1.1.0",
- "scheduler": "^0.23.2"
+ "scheduler": "^0.27.0"
},
"peerDependencies": {
- "react": "^18.3.1"
+ "react": "^19.2.4"
}
},
"node_modules/react-draggable": {
@@ -16594,44 +16509,27 @@
"license": "MIT"
},
"node_modules/react-floater": {
- "version": "0.7.9",
- "resolved": "https://registry.npmjs.org/react-floater/-/react-floater-0.7.9.tgz",
- "integrity": "sha512-NXqyp9o8FAXOATOEo0ZpyaQ2KPb4cmPMXGWkx377QtJkIXHlHRAGer7ai0r0C1kG5gf+KJ6Gy+gdNIiosvSicg==",
+ "version": "0.9.5-5",
+ "resolved": "https://registry.npmjs.org/react-floater/-/react-floater-0.9.5-5.tgz",
+ "integrity": "sha512-9EFcYn8YOfqBoy9mAX0nnaG0KVvlTqOUCGMZgdJmI0ddvmZfnutlAo9s2RI89Up5ZN/pYuae8OObwZ5TBV91AQ==",
"license": "MIT",
"dependencies": {
- "deepmerge": "^4.3.1",
- "is-lite": "^0.8.2",
- "popper.js": "^1.16.0",
- "prop-types": "^15.8.1",
- "tree-changes": "^0.9.1"
+ "@popperjs/core": "^2.11.8",
+ "deepmerge-ts": "^7.1.5",
+ "is-lite": "^2.0.0",
+ "tree-changes-hook": "^0.11.3"
},
"peerDependencies": {
- "react": "15 - 18",
- "react-dom": "15 - 18"
+ "react": "16.8 - 19",
+ "react-dom": "16.8 - 19"
}
},
- "node_modules/react-floater/node_modules/@gilbarbara/deep-equal": {
- "version": "0.1.2",
- "resolved": "https://registry.npmjs.org/@gilbarbara/deep-equal/-/deep-equal-0.1.2.tgz",
- "integrity": "sha512-jk+qzItoEb0D0xSSmrKDDzf9sheQj/BAPxlgNxgmOaA3mxpUa6ndJLYGZKsJnIVEQSD8zcTbyILz7I0HcnBCRA==",
- "license": "MIT"
- },
"node_modules/react-floater/node_modules/is-lite": {
- "version": "0.8.2",
- "resolved": "https://registry.npmjs.org/is-lite/-/is-lite-0.8.2.tgz",
- "integrity": "sha512-JZfH47qTsslwaAsqbMI3Q6HNNjUuq6Cmzzww50TdP5Esb6e1y2sK2UAaZZuzfAzpoI2AkxoPQapZdlDuP6Vlsw==",
+ "version": "2.0.0",
+ "resolved": "https://registry.npmjs.org/is-lite/-/is-lite-2.0.0.tgz",
+ "integrity": "sha512-70f2BMIQlbSUXVKaZUd9a9fJH3IH1PDckV0m4BIIO4LjnNYvOh4Ng7vXIXEwpA0KDZknRq+7fHwGTu0jIdx28g==",
"license": "MIT"
},
- "node_modules/react-floater/node_modules/tree-changes": {
- "version": "0.9.3",
- "resolved": "https://registry.npmjs.org/tree-changes/-/tree-changes-0.9.3.tgz",
- "integrity": "sha512-vvvS+O6kEeGRzMglTKbc19ltLWNtmNt1cpBoSYLj/iEcPVvpJasemKOlxBrmZaCtDJoF+4bwv3m01UKYi8mukQ==",
- "license": "MIT",
- "dependencies": {
- "@gilbarbara/deep-equal": "^0.1.1",
- "is-lite": "^0.8.2"
- }
- },
"node_modules/react-image-crop": {
"version": "11.0.10",
"resolved": "https://registry.npmjs.org/react-image-crop/-/react-image-crop-11.0.10.tgz",
@@ -16667,73 +16565,29 @@
"version": "19.2.4",
"resolved": "https://registry.npmjs.org/react-is/-/react-is-19.2.4.tgz",
"integrity": "sha512-W+EWGn2v0ApPKgKKCy/7s7WHXkboGcsrXE+2joLyVxkbyVQfO3MUEaUQDHoSmb8TFFrSKYa9mw64WZHNHSDzYA==",
- "license": "MIT",
- "peer": true
+ "dev": true,
+ "license": "MIT"
},
"node_modules/react-joyride": {
- "version": "2.9.3",
- "resolved": "https://registry.npmjs.org/react-joyride/-/react-joyride-2.9.3.tgz",
- "integrity": "sha512-1+Mg34XK5zaqJ63eeBhqdbk7dlGCFp36FXwsEvgpjqrtyywX2C6h9vr3jgxP0bGHCw8Ilsp/nRDzNVq6HJ3rNw==",
+ "version": "3.0.0-7",
+ "resolved": "https://registry.npmjs.org/react-joyride/-/react-joyride-3.0.0-7.tgz",
+ "integrity": "sha512-NBgtdm8QehHEVI/Qkakb4EJ/WjKN7bQaZgZmO/01v1p2yBlzAcXyKM36FeS1YZaywX8v8R79bF5Z0OcV5BK1og==",
"license": "MIT",
"dependencies": {
"@gilbarbara/deep-equal": "^0.3.1",
- "deep-diff": "^1.0.2",
+ "@gilbarbara/hooks": "^0.8.2",
+ "@gilbarbara/types": "^0.2.2",
"deepmerge": "^4.3.1",
"is-lite": "^1.2.1",
- "react-floater": "^0.7.9",
+ "react-floater": "^0.9.5-4",
"react-innertext": "^1.1.5",
- "react-is": "^16.13.1",
"scroll": "^3.0.1",
"scrollparent": "^2.1.0",
- "tree-changes": "^0.11.2",
- "type-fest": "^4.27.0"
+ "tree-changes-hook": "^0.11.2"
},
"peerDependencies": {
- "react": "15 - 18",
- "react-dom": "15 - 18"
- }
- },
- "node_modules/react-joyride/node_modules/react-is": {
- "version": "16.13.1",
- "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
- "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==",
- "license": "MIT"
- },
- "node_modules/react-joyride/node_modules/type-fest": {
- "version": "4.41.0",
- "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.41.0.tgz",
- "integrity": "sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==",
- "license": "(MIT OR CC0-1.0)",
- "engines": {
- "node": ">=16"
- },
- "funding": {
- "url": "https://github.com/sponsors/sindresorhus"
- }
- },
- "node_modules/react-mobile-datepicker": {
- "version": "4.0.2",
- "resolved": "https://registry.npmjs.org/react-mobile-datepicker/-/react-mobile-datepicker-4.0.2.tgz",
- "integrity": "sha512-B83IF3fCcq7U2Q/ZX83PUfcdaHhXpTgYXqkZW1AffOSappDtKYd7Tc1IgSBCBnON8UghWdFbj0xtnkofZsLzzw==",
- "license": "ISC",
- "peerDependencies": {
- "react": ">=0.14",
- "react-dom": ">=0.14"
- }
- },
- "node_modules/react-popper": {
- "version": "2.3.0",
- "resolved": "https://registry.npmjs.org/react-popper/-/react-popper-2.3.0.tgz",
- "integrity": "sha512-e1hj8lL3uM+sgSR4Lxzn5h1GxBlpa4CQz0XLF8kx4MDrDRWY0Ena4c97PUeSX9i5W3UAfDP0z0FXCTQkoXUl3Q==",
- "license": "MIT",
- "dependencies": {
- "react-fast-compare": "^3.0.1",
- "warning": "^4.0.2"
- },
- "peerDependencies": {
- "@popperjs/core": "^2.0.0",
- "react": "^16.8.0 || ^17 || ^18",
- "react-dom": "^16.8.0 || ^17 || ^18"
+ "react": "16.8 - 19",
+ "react-dom": "16.8 - 19"
}
},
"node_modules/react-redux": {
@@ -16804,112 +16658,20 @@
"react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0"
}
},
- "node_modules/react-select/node_modules/memoize-one": {
- "version": "6.0.0",
- "resolved": "https://registry.npmjs.org/memoize-one/-/memoize-one-6.0.0.tgz",
- "integrity": "sha512-rkpe71W0N0c0Xz6QD0eJETuWAJGnJ9afsl1srmwPrI+yBCkge5EycXXbYRyvL29zZVUWQCY7InPRCv3GDXuZNw==",
- "license": "MIT"
- },
- "node_modules/react-shallow-renderer": {
- "version": "16.15.0",
- "resolved": "https://registry.npmjs.org/react-shallow-renderer/-/react-shallow-renderer-16.15.0.tgz",
- "integrity": "sha512-oScf2FqQ9LFVQgA73vr86xl2NaOIX73rh+YFqcOp68CWj56tSfgtGKrEbyhCj0rSijyG9M1CYprTh39fBi5hzA==",
- "dev": true,
- "license": "MIT",
- "dependencies": {
- "object-assign": "^4.1.1",
- "react-is": "^16.12.0 || ^17.0.0 || ^18.0.0"
- },
- "peerDependencies": {
- "react": "^16.0.0 || ^17.0.0 || ^18.0.0"
- }
- },
- "node_modules/react-shallow-renderer/node_modules/react-is": {
- "version": "18.3.1",
- "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz",
- "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==",
- "dev": true,
- "license": "MIT"
- },
- "node_modules/react-swipe-to-delete-component": {
- "version": "1.0.5",
- "resolved": "https://registry.npmjs.org/react-swipe-to-delete-component/-/react-swipe-to-delete-component-1.0.5.tgz",
- "integrity": "sha512-yp91Wl6zjNvJS2MaMo85x3kcu3zjngUGkxz3jMBaWHpzOstfD6Ruvmrv2EWpQfbzrp5YfnTsgXfihxHfZ/UxwA==",
- "license": "MIT",
- "dependencies": {
- "@babel/runtime": "^7.12.5",
- "prop-types": "^15.8.1",
- "react": "^17.0.2",
- "react-dom": "^17.0.2"
- },
- "engines": {
- "node": "^10.0.0"
- },
- "peerDependencies": {
- "prop-types": "^15.6.0",
- "react": "^16.1.1",
- "react-dom": "^16.1.1"
- }
- },
- "node_modules/react-swipe-to-delete-component/node_modules/react": {
- "version": "17.0.2",
- "resolved": "https://registry.npmjs.org/react/-/react-17.0.2.tgz",
- "integrity": "sha512-gnhPt75i/dq/z3/6q/0asP78D0u592D5L1pd7M8P+dck6Fu/jJeL6iVVK23fptSUZj8Vjf++7wXA8UNclGQcbA==",
- "license": "MIT",
- "dependencies": {
- "loose-envify": "^1.1.0",
- "object-assign": "^4.1.1"
- },
- "engines": {
- "node": ">=0.10.0"
- }
- },
- "node_modules/react-swipe-to-delete-component/node_modules/react-dom": {
- "version": "17.0.2",
- "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-17.0.2.tgz",
- "integrity": "sha512-s4h96KtLDUQlsENhMn1ar8t2bEa+q/YAtj8pPPdIjPDGBDIVNsrD9aXNWqspUe6AzKCIG0C1HZZLqLV7qpOBGA==",
- "license": "MIT",
- "dependencies": {
- "loose-envify": "^1.1.0",
- "object-assign": "^4.1.1",
- "scheduler": "^0.20.2"
- },
- "peerDependencies": {
- "react": "17.0.2"
- }
- },
- "node_modules/react-swipe-to-delete-component/node_modules/scheduler": {
- "version": "0.20.2",
- "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.20.2.tgz",
- "integrity": "sha512-2eWfGgAqqWFGqtdMmcL5zCMK1U8KlXv8SQFGglL3CEtd0aDVDWgeF/YoCmvln55m5zSk3J/20hTaSBeSObsQDQ==",
- "license": "MIT",
- "dependencies": {
- "loose-envify": "^1.1.0",
- "object-assign": "^4.1.1"
- }
- },
"node_modules/react-test-renderer": {
- "version": "18.3.1",
- "resolved": "https://registry.npmjs.org/react-test-renderer/-/react-test-renderer-18.3.1.tgz",
- "integrity": "sha512-KkAgygexHUkQqtvvx/otwxtuFu5cVjfzTCtjXLH9boS19/Nbtg84zS7wIQn39G8IlrhThBpQsMKkq5ZHZIYFXA==",
+ "version": "19.2.4",
+ "resolved": "https://registry.npmjs.org/react-test-renderer/-/react-test-renderer-19.2.4.tgz",
+ "integrity": "sha512-Ttl5D7Rnmi6JGMUpri4UjB4BAN0FPs4yRDnu2XSsigCWOLm11o8GwRlVsh27ER+4WFqsGtrBuuv5zumUaRCmKw==",
"dev": true,
"license": "MIT",
"dependencies": {
- "react-is": "^18.3.1",
- "react-shallow-renderer": "^16.15.0",
- "scheduler": "^0.23.2"
+ "react-is": "^19.2.4",
+ "scheduler": "^0.27.0"
},
"peerDependencies": {
- "react": "^18.3.1"
+ "react": "^19.2.4"
}
},
- "node_modules/react-test-renderer/node_modules/react-is": {
- "version": "18.3.1",
- "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz",
- "integrity": "sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==",
- "dev": true,
- "license": "MIT"
- },
"node_modules/react-transition-group": {
"version": "4.4.5",
"resolved": "https://registry.npmjs.org/react-transition-group/-/react-transition-group-4.4.5.tgz",
@@ -16926,19 +16688,6 @@
"react-dom": ">=16.6.0"
}
},
- "node_modules/react-visibility-sensor": {
- "version": "5.1.1",
- "resolved": "https://registry.npmjs.org/react-visibility-sensor/-/react-visibility-sensor-5.1.1.tgz",
- "integrity": "sha512-cTUHqIK+zDYpeK19rzW6zF9YfT4486TIgizZW53wEZ+/GPBbK7cNS0EHyJVyHYacwFEvvHLEKfgJndbemWhB/w==",
- "license": "MIT",
- "dependencies": {
- "prop-types": "^15.7.2"
- },
- "peerDependencies": {
- "react": ">=16.0.0",
- "react-dom": ">=16.0.0"
- }
- },
"node_modules/reactstrap": {
"version": "9.2.3",
"resolved": "https://registry.npmjs.org/reactstrap/-/reactstrap-9.2.3.tgz",
@@ -16957,6 +16706,21 @@
"react-dom": ">=16.8.0"
}
},
+ "node_modules/reactstrap/node_modules/react-popper": {
+ "version": "2.3.0",
+ "resolved": "https://registry.npmjs.org/react-popper/-/react-popper-2.3.0.tgz",
+ "integrity": "sha512-e1hj8lL3uM+sgSR4Lxzn5h1GxBlpa4CQz0XLF8kx4MDrDRWY0Ena4c97PUeSX9i5W3UAfDP0z0FXCTQkoXUl3Q==",
+ "license": "MIT",
+ "dependencies": {
+ "react-fast-compare": "^3.0.1",
+ "warning": "^4.0.2"
+ },
+ "peerDependencies": {
+ "@popperjs/core": "^2.0.0",
+ "react": "^16.8.0 || ^17 || ^18",
+ "react-dom": "^16.8.0 || ^17 || ^18"
+ }
+ },
"node_modules/read-pkg": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz",
@@ -17060,21 +16824,6 @@
"integrity": "sha512-M9/ELqF6fy8FwmkpnF0S3YKOqMyoWJ4+CS5Efg2ct3oY9daQvd/Pc71FpGZsVsbl3Cpb+IIcjBDUnnyBdQbq4w==",
"license": "MIT"
},
- "node_modules/redux-location-state": {
- "version": "2.8.2",
- "resolved": "https://registry.npmjs.org/redux-location-state/-/redux-location-state-2.8.2.tgz",
- "integrity": "sha512-KKbvnl0k+pRg1U2gWWSLuId8SbDbt2rdFfaSWX1mLZBDzMtftvnIGrxuQ528xrjd9nq7YcFxVWgGDYlRxMzAvg==",
- "license": "Apache-2.0",
- "dependencies": {
- "lodash": "^4.13.1"
- },
- "engines": {
- "node": ">4.0"
- },
- "peerDependencies": {
- "redux": "^3.0.0 || ^4.0.0"
- }
- },
"node_modules/redux-logger": {
"version": "3.0.6",
"resolved": "https://registry.npmjs.org/redux-logger/-/redux-logger-3.0.6.tgz",
@@ -17260,6 +17009,7 @@
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz",
"integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=0.10.0"
@@ -17690,18 +17440,16 @@
}
},
"node_modules/scheduler": {
- "version": "0.23.2",
- "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.23.2.tgz",
- "integrity": "sha512-UOShsPwz7NrMUqhR6t0hWjFduvOzbtv7toDH1/hIrfRNIDBnnBWd0CwJTGvTpngVlmwGCdP9/Zl/tVrDqcuYzQ==",
- "license": "MIT",
- "dependencies": {
- "loose-envify": "^1.1.0"
- }
+ "version": "0.27.0",
+ "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz",
+ "integrity": "sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==",
+ "license": "MIT"
},
"node_modules/schema-utils": {
"version": "4.3.3",
"resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-4.3.3.tgz",
"integrity": "sha512-eflK8wEtyOE6+hsaRVPxvUKYCpRgzLqDTb8krvAsRIwOGlHoSgYLgBXoubGgLd2fT41/OUYdb48v4k4WWHQurA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@types/json-schema": "^7.0.9",
@@ -18014,6 +17762,7 @@
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz",
"integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"shebang-regex": "^3.0.0"
@@ -18026,6 +17775,7 @@
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz",
"integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
@@ -18710,6 +18460,7 @@
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz",
"integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=8"
@@ -19040,6 +18791,7 @@
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"has-flag": "^4.0.0"
@@ -19163,6 +18915,7 @@
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/tapable/-/tapable-2.3.0.tgz",
"integrity": "sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=6"
@@ -19203,6 +18956,7 @@
"version": "5.46.0",
"resolved": "https://registry.npmjs.org/terser/-/terser-5.46.0.tgz",
"integrity": "sha512-jTwoImyr/QbOWFFso3YoU3ik0jBBDJ6JTOQiy/J2YxVJdZCc+5u7skhNwiOR3FQIygFqVUPHl7qbbxtjW2K3Qg==",
+ "dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"@jridgewell/source-map": "^0.3.3",
@@ -19221,6 +18975,7 @@
"version": "5.4.0",
"resolved": "https://registry.npmjs.org/terser-webpack-plugin/-/terser-webpack-plugin-5.4.0.tgz",
"integrity": "sha512-Bn5vxm48flOIfkdl5CaD2+1CiUVbonWQ3KQPyP7/EuIl9Gbzq/gQFOzaMFUEgVjB1396tcK0SG8XcNJ/2kDH8g==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@jridgewell/trace-mapping": "^0.3.25",
@@ -19254,6 +19009,7 @@
"version": "27.5.1",
"resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-27.5.1.tgz",
"integrity": "sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@types/node": "*",
@@ -19268,6 +19024,7 @@
"version": "8.1.1",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz",
"integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"has-flag": "^4.0.0"
@@ -19283,12 +19040,14 @@
"version": "2.20.3",
"resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz",
"integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==",
+ "dev": true,
"license": "MIT"
},
"node_modules/terser/node_modules/source-map": {
"version": "0.6.1",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz",
"integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==",
+ "dev": true,
"license": "BSD-3-Clause",
"engines": {
"node": ">=0.10.0"
@@ -19298,6 +19057,7 @@
"version": "0.5.21",
"resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.21.tgz",
"integrity": "sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"buffer-from": "^1.0.0",
@@ -19418,16 +19178,6 @@
"integrity": "sha512-pj7yygNMoMRqG7ML2SDQ0xNIOfN3IBDUcPVM2Sg6hP96oFNN2nqnzHreT3z9xLq85IWJyNTvD38O002DdOrPMw==",
"license": "MIT"
},
- "node_modules/tmp": {
- "version": "0.2.5",
- "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.5.tgz",
- "integrity": "sha512-voyz6MApa1rQGUxT3E+BK7/ROe8itEx7vD8/HEvt4xwXucvQ5G5oeEiHkmHZJuBO21RpOf+YYm9MOivj709jow==",
- "dev": true,
- "license": "MIT",
- "engines": {
- "node": ">=14.14"
- }
- },
"node_modules/tmpl": {
"version": "1.0.5",
"resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.5.tgz",
@@ -19509,6 +19259,19 @@
"is-lite": "^1.2.1"
}
},
+ "node_modules/tree-changes-hook": {
+ "version": "0.11.3",
+ "resolved": "https://registry.npmjs.org/tree-changes-hook/-/tree-changes-hook-0.11.3.tgz",
+ "integrity": "sha512-cNHPuFc5Qbi2B74VqSqL/Ee/l4n0SFfzYKTnXYViJW1yCFZ0bl97QsgUIw9vdQtqpWDwo83mpNkGUvcjeQc0Xw==",
+ "license": "MIT",
+ "dependencies": {
+ "@gilbarbara/deep-equal": "^0.3.1",
+ "tree-changes": "0.11.3"
+ },
+ "peerDependencies": {
+ "react": "16.8 - 19"
+ }
+ },
"node_modules/tree-dump": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/tree-dump/-/tree-dump-1.1.0.tgz",
@@ -19635,6 +19398,7 @@
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz",
"integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"prelude-ls": "^1.2.1"
@@ -19759,21 +19523,6 @@
"url": "https://github.com/sponsors/ljharb"
}
},
- "node_modules/typescript": {
- "version": "5.9.3",
- "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz",
- "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==",
- "dev": true,
- "license": "Apache-2.0",
- "peer": true,
- "bin": {
- "tsc": "bin/tsc",
- "tsserver": "bin/tsserver"
- },
- "engines": {
- "node": ">=14.17"
- }
- },
"node_modules/typescript-eslint": {
"version": "8.56.1",
"resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.56.1.tgz",
@@ -19857,6 +19606,7 @@
"version": "7.18.2",
"resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.18.2.tgz",
"integrity": "sha512-AsuCzffGHJybSaRrmr5eHr81mwJU3kjw6M+uprWvCXiNeN9SOGwQ3Jn8jb8m3Z6izVgknn1R0FTCEAP2QrLY/w==",
+ "dev": true,
"license": "MIT"
},
"node_modules/unicode-canonical-property-names-ecmascript": {
@@ -19916,16 +19666,6 @@
"url": "https://github.com/sponsors/sindresorhus"
}
},
- "node_modules/universalify": {
- "version": "2.0.1",
- "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz",
- "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==",
- "dev": true,
- "license": "MIT",
- "engines": {
- "node": ">= 10.0.0"
- }
- },
"node_modules/unpipe": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz",
@@ -20032,6 +19772,7 @@
"version": "4.4.1",
"resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
"integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
+ "dev": true,
"license": "BSD-2-Clause",
"dependencies": {
"punycode": "^2.1.0"
@@ -20213,6 +19954,7 @@
"version": "2.5.1",
"resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.5.1.tgz",
"integrity": "sha512-Zn5uXdcFNIA1+1Ei5McRd+iRzfhENPCe7LeABkJtNulSxjma+l7ltNx55BWZkRlwRnpOgHqxnjyaDgJnNXnqzg==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"glob-to-regexp": "^0.4.1",
@@ -20252,6 +19994,7 @@
"version": "5.105.4",
"resolved": "https://registry.npmjs.org/webpack/-/webpack-5.105.4.tgz",
"integrity": "sha512-jTywjboN9aHxFlToqb0K0Zs9SbBoW4zRUlGzI2tYNxVYcEi/IPpn+Xi4ye5jTLvX2YeLuic/IvxNot+Q1jMoOw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"@types/eslint-scope": "^3.7.7",
@@ -20928,6 +20671,7 @@
"version": "1.52.0",
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz",
"integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">= 0.6"
@@ -20937,6 +20681,7 @@
"version": "2.1.35",
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz",
"integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==",
+ "dev": true,
"license": "MIT",
"dependencies": {
"mime-db": "1.52.0"
@@ -20949,6 +20694,7 @@
"version": "3.3.4",
"resolved": "https://registry.npmjs.org/webpack-sources/-/webpack-sources-3.3.4.tgz",
"integrity": "sha512-7tP1PdV4vF+lYPnkMR0jMY5/la2ub5Fc/8VQrrU+lXkiM6C4TjVfGw7iKfyhnTQOsD+6Q/iKw0eFciziRgD58Q==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=10.13.0"
@@ -21027,6 +20773,7 @@
"version": "2.0.2",
"resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz",
"integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==",
+ "dev": true,
"license": "ISC",
"dependencies": {
"isexe": "^2.0.0"
@@ -21144,6 +20891,7 @@
"version": "1.2.5",
"resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz",
"integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=0.10.0"
@@ -21417,22 +21165,6 @@
"integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==",
"license": "ISC"
},
- "node_modules/yaml": {
- "version": "2.8.2",
- "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.8.2.tgz",
- "integrity": "sha512-mplynKqc1C2hTVYxd0PU2xQAc22TI1vShAYGksCCfxbn/dFwnHTNi1bvYsBTkhdUNtGIf5xNOg938rrSSYvS9A==",
- "dev": true,
- "license": "ISC",
- "bin": {
- "yaml": "bin.mjs"
- },
- "engines": {
- "node": ">= 14.6"
- },
- "funding": {
- "url": "https://github.com/sponsors/eemeli"
- }
- },
"node_modules/yargs": {
"version": "18.0.0",
"resolved": "https://registry.npmjs.org/yargs/-/yargs-18.0.0.tgz",
@@ -21519,6 +21251,7 @@
"version": "0.1.0",
"resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz",
"integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==",
+ "dev": true,
"license": "MIT",
"engines": {
"node": ">=10"
diff --git a/package.json b/package.json
index b26fd7903..f48ac8177 100644
--- a/package.json
+++ b/package.json
@@ -62,7 +62,7 @@
"lint:scss": "npx stylelint ./web/scss/**/*.scss",
"lint:js": "npx eslint .",
"preinstall": "node tasks/util/checkNodeVersion.js",
- "postinstall": "patch-package && husky",
+ "postinstall": "husky",
"start": "node ./tasks/util/start.js",
"t-debug": "npx playwright test --debug",
"test": "run-script-os",
@@ -127,11 +127,10 @@
"node-fetch": "^2.6.9",
"node-ssh": "^13.2.1",
"npm-run-all": "^4.1.5",
- "patch-package": "^8.0.0",
"postcss": "^8.5.8",
"postcss-loader": "^8.2.1",
"react-refresh": "^0.18.0",
- "react-test-renderer": "^18.3.1",
+ "react-test-renderer": "^19.2.4",
"redux-mock-store": "^1.5.5",
"run-script-os": "^1.1.6",
"sass": "^1.98.0",
@@ -193,22 +192,18 @@
"p-queue": "^9.1.0",
"proj4": "^2.20.3",
"prop-types": "^15.8.1",
- "react": "^18.3.1",
+ "react": "^19.2.4",
"react-device-detect": "^2.2.3",
- "react-dom": "^18.3.1",
+ "react-dom": "^19.2.4",
"react-draggable": "^4.5.0",
"react-image-crop": "^11.0.10",
"react-infinite-scroller": "^1.2.6",
- "react-joyride": "^2.9.3",
- "react-mobile-datepicker": "^4.0.2",
+ "react-joyride": "^3.0.0-7",
"react-redux": "^9.2.0",
"react-resizable": "^3.1.3",
- "react-swipe-to-delete-component": "1.0.5",
- "react-visibility-sensor": "^5.1.1",
"reactstrap": "^9.2.3",
"recharts": "^3.8.0",
"redux": "^5.0.1",
- "redux-location-state": "^2.8.2",
"redux-logger": "^3.0.6",
"redux-thunk": "^3.1.0",
"regenerator-runtime": "^0.14.1",
@@ -224,8 +219,8 @@
},
"overrides": {
"semver": "^7.5.4",
- "redux-location-state": {
- "redux": "^5.0.1"
+ "@gilbarbara/hooks": {
+ "react": "^19.2.4"
}
},
"browserslist": [
diff --git a/setupJest.js b/setupJest.js
index 167ff3a7a..62f02b025 100644
--- a/setupJest.js
+++ b/setupJest.js
@@ -1,3 +1,5 @@
const fetchMock = require('jest-fetch-mock')
fetchMock.enableMocks()
fetchMock.dontMock()
+
+globalThis.IS_REACT_ACT_ENVIRONMENT = true;
diff --git a/web/index.html b/web/index.html
index e71756586..b1beb4fe8 100644
--- a/web/index.html
+++ b/web/index.html
@@ -41,6 +41,7 @@ Licensed under the NASA Open Source Agreement, Version 1.3 (https://opensource.o
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
+ <meta name="mobile-web-app-capable" content="yes">
<meta name="keywords" content="nasa, worldview, nasa worldview, eosdis worldview, esdis worldview, satellite imagery, remote sensing, natural hazards, natural disasters, daily, near real-time, nrt, lance, wildfire management, air quality, weather forecasting, agriculture, dust storms, smoke plumes, vegetation, severe storms, shipping, fisheries, floods, drought, oil spills">
<meta name="description" content="Interactive interface for browsing full-resolution, global, daily satellite images. Supports time-critical application areas such as wildfire management, air quality measurements, and weather forecasting. Data is generally available within three hours of observation.">
<meta http-equiv="Cache-control" content="no-cache">
diff --git a/web/js/components/image-download/image-download-panel.js b/web/js/components/image-download/image-download-panel.js
index 13abacab2..a63ae8a69 100644
--- a/web/js/components/image-download/image-download-panel.js
+++ b/web/js/components/image-download/image-download-panel.js
@@ -31,9 +31,9 @@ const RESOLUTION_KEY = {
function ImageDownloadPanel(props) {
const {
- fileType,
- isWorldfile,
- resolution,
+ fileType = 'image/jpeg',
+ isWorldfile = false,
+ resolution = '1',
getLayers,
url,
lonlats,
@@ -41,16 +41,16 @@ function ImageDownloadPanel(props) {
date,
markerCoordinates,
onPanelChange,
- fileTypeOptions,
+ fileTypeOptions = true,
fileTypes,
- secondLabel,
- worldFileOptions,
+ secondLabel = 'Format',
+ worldFileOptions = true,
datelineMessage,
map,
viewExtent,
resolutions,
- maxImageSize,
- firstLabel,
+ maxImageSize = '8200px x 8200px',
+ firstLabel = 'Resolution (per pixel)',
geoLatLong,
onLatLongChange,
} = props;
@@ -253,17 +253,6 @@ function ImageDownloadPanel(props) {
);
}
-ImageDownloadPanel.defaultProps = {
- fileType: 'image/jpeg',
- fileTypeOptions: true,
- firstLabel: 'Resolution (per pixel)',
- isWorldfile: false,
- maxImageSize: '8200px x 8200px',
- resolution: '1',
- secondLabel: 'Format',
- worldFileOptions: true,
-};
-
ImageDownloadPanel.propTypes = {
datelineMessage: PropTypes.string,
fileType: PropTypes.string,
diff --git a/web/js/components/layer/product-picker/search/search-layer-row.js b/web/js/components/layer/product-picker/search/search-layer-row.js
index d6cb68d10..884a3306f 100644
--- a/web/js/components/layer/product-picker/search/search-layer-row.js
+++ b/web/js/components/layer/product-picker/search/search-layer-row.js
@@ -3,7 +3,6 @@ import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import { Button, UncontrolledTooltip } from 'reactstrap';
-import { Check } from '@edsc/earthdata-react-icons/horizon-design-system/hds/ui';
import {
addLayer as addLayerAction,
removeLayer as removeLayerAction,
@@ -140,7 +139,12 @@ class SearchLayerRow extends React.Component {
onChange={this.toggleEnabled}
/>
{isEnabled && (
- <Check class="check" size="15px" />
+ <FontAwesomeIcon
+ icon="check-circle"
+ className="check"
+ style={{ fontSize: '15px' }}
+ widthAuto
+ />
)}
</div>
{(chartableLayer || layerNotices) && (
diff --git a/web/js/components/layer/product-picker/search/search-layers-list.js b/web/js/components/layer/product-picker/search/search-layers-list.js
index 85e1b18ce..cf9965d81 100644
--- a/web/js/components/layer/product-picker/search/search-layers-list.js
+++ b/web/js/components/layer/product-picker/search/search-layers-list.js
@@ -4,7 +4,7 @@ import { connect } from 'react-redux';
import { withSearch } from '@elastic/react-search-ui';
import InfiniteScroll from 'react-infinite-scroller';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
-import SwipeToDelete from 'react-swipe-to-delete-component';
+import SwipeToDelete from '../../../util/swipe-to-delete';
import SearchLayerRow from './search-layer-row';
import {
selectLayer as selectLayerAction,
diff --git a/web/js/components/map/coordinates.test.js b/web/js/components/map/coordinates.test.js
index 212c1f6bf..a98b0c9e6 100644
--- a/web/js/components/map/coordinates.test.js
+++ b/web/js/components/map/coordinates.test.js
@@ -1,6 +1,5 @@
import { createRoot } from 'react-dom/client';
-import { act } from 'react-dom/test-utils';
-import renderer from 'react-test-renderer';
+import { act } from 'react';
import Coordinates from './coordinates';
let container;
@@ -13,7 +12,9 @@ beforeEach(() => {
});
afterEach(() => {
- root.unmount(container);
+ act(() => {
+ root.unmount();
+ });
container.remove();
container = null;
});
@@ -39,16 +40,21 @@ describe('formats', () => {
test('change format from latlon-dd to latlon-dm', () => {
const callback = jest.fn();
- const component = renderer.create(
- <Coordinates
- format="latlon-dd"
- latitude={0}
- longitude={0}
- crs="EPSG:4326"
- onFormatChange={callback}
- />);
- const instance = component.getInstance();
+ act(() => {
+ root.render(
+ <Coordinates
+ format="latlon-dd"
+ latitude={0}
+ longitude={0}
+ crs="EPSG:4326"
+ onFormatChange={callback}
+ />,
+ );
+ });
- instance.changeFormat();
+ const button = container.querySelector('#coords-panel');
+ act(() => {
+ button.dispatchEvent(new MouseEvent('click', { bubbles: true }));
+ });
expect(callback).toHaveBeenCalledWith('latlon-dm');
});
diff --git a/web/js/components/map/ol-coordinates.test.js b/web/js/components/map/ol-coordinates.test.js
index 72987f412..cc3ca5e08 100644
--- a/web/js/components/map/ol-coordinates.test.js
+++ b/web/js/components/map/ol-coordinates.test.js
@@ -1,5 +1,5 @@
import { createRoot } from 'react-dom/client';
-import { act } from 'react-dom/test-utils';
+import { act } from 'react';
import util from '../../util/util';
import OlCoordinates from './ol-coordinates';
import { registerProjections } from '../../fixtures';
@@ -29,7 +29,9 @@ beforeEach(() => {
afterEach(() => {
util.setCoordinateFormat('latlon-dd');
- root.unmount(container);
+ act(() => {
+ root.unmount();
+ });
container.remove();
container = null;
});
diff --git a/web/js/components/range-selection/dragger-range.js b/web/js/components/range-selection/dragger-range.js
index 093049bc1..0beddb083 100644
--- a/web/js/components/range-selection/dragger-range.js
+++ b/web/js/components/range-selection/dragger-range.js
@@ -1,4 +1,4 @@
-import { PureComponent } from 'react';
+import { PureComponent, createRef } from 'react';
import PropTypes from 'prop-types';
import Draggable from 'react-draggable';
import { timeScaleOptions } from '../../modules/date/constants';
@@ -11,6 +11,7 @@ import { timeScaleOptions } from '../../modules/date/constants';
class TimelineDraggerRange extends PureComponent {
constructor(props) {
super(props);
+ this.nodeRef = createRef();
const { startLocation } = props;
this.state = {
width: 0,
@@ -216,12 +217,14 @@ class TimelineDraggerRange extends PureComponent {
<Draggable
handle=".dragger-range"
axis="x"
+ nodeRef={this.nodeRef}
position={null}
defaultPosition={{ x: 0, y: 11 }}
onStop={onStop}
onDrag={this.handleDrag}
>
<rect
+ ref={this.nodeRef}
x={this.handleStartPositionRestriction()}
fill={color}
width={width}
diff --git a/web/js/components/range-selection/dragger.js b/web/js/components/range-selection/dragger.js
index 10ce9b06a..2a193bd6f 100644
--- a/web/js/components/range-selection/dragger.js
+++ b/web/js/components/range-selection/dragger.js
@@ -1,4 +1,4 @@
-import { PureComponent } from 'react';
+import { PureComponent, createRef } from 'react';
import PropTypes from 'prop-types';
import Draggable from 'react-draggable';
import lodashRound from 'lodash/round';
@@ -16,6 +16,7 @@ class TimelineDragger extends PureComponent {
*/
constructor(props) {
super(props);
+ this.nodeRef = createRef();
this.state = {
position: props.position,
backgroundColor: props.backgroundColor,
@@ -30,13 +31,17 @@ class TimelineDragger extends PureComponent {
* Update state if position has changed
* @param {object} props
*/
- UNSAFE_componentWillReceiveProps(props) {
+ componentDidUpdate(prevProps) {
const { position, max } = this.state;
- if (props.position !== position) {
- this.setState({ position: props.position });
+ const positionChanged = prevProps.position !== this.props.position;
+ const maxChanged = prevProps.max !== this.props.max;
+
+ if (positionChanged && this.props.position !== position) {
+ this.setState({ position: this.props.position });
}
- if (props.max !== max) {
- this.setState({ max: props.max });
+
+ if (maxChanged && this.props.max !== max) {
+ this.setState({ max: this.props.max });
}
}
@@ -173,6 +178,7 @@ class TimelineDragger extends PureComponent {
const { position } = this.state;
return (
<Draggable
+ nodeRef={this.nodeRef}
onDrag={this.handleDrag}
position={{ x: position, y: yOffset }}
onStop={() => {
@@ -180,7 +186,7 @@ class TimelineDragger extends PureComponent {
}}
axis="x"
>
- <g>
+ <g ref={this.nodeRef}>
{!path
? this.getDefaultDragger(visibility)
: this.getCustomDragger(visibility)}
diff --git a/web/js/components/sidebar/compare-mode-options.js b/web/js/components/sidebar/compare-mode-options.js
index 23d4fccc8..55f8782ef 100644
--- a/web/js/components/sidebar/compare-mode-options.js
+++ b/web/js/components/sidebar/compare-mode-options.js
@@ -3,20 +3,6 @@ import PropTypes from 'prop-types';
import { Button, ButtonGroup } from 'reactstrap';
class CompareModeOptions extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- selected: props.selected,
- };
- }
-
- UNSAFE_componentWillReceiveProps(newProp) {
- const { selected } = this.state;
- if (selected !== newProp.selected) {
- this.setState({ selected: newProp.selected });
- }
- }
-
render() {
const {
isActive, isMobile, selected, onclick,
diff --git a/web/js/components/sidebar/paletteLegend.js b/web/js/components/sidebar/paletteLegend.js
index 437259326..6b29fa7a3 100644
--- a/web/js/components/sidebar/paletteLegend.js
+++ b/web/js/components/sidebar/paletteLegend.js
@@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
import lodashIsNumber from 'lodash/isNumber';
import lodashIsEqual from 'lodash/isEqual';
import { Tooltip } from 'reactstrap';
-import VisibilitySensor from 'react-visibility-sensor/visibility-sensor';
+import VisibilitySensor from '../util/visibility-sensor';
import { connect } from 'react-redux';
import { getOrbitTrackTitle } from '../../modules/layers/util';
import {
@@ -72,23 +72,25 @@ class PaletteLegend extends React.Component {
}));
}
- UNSAFE_componentWillReceiveProps(props) {
- const { colorHex, isRunningData } = this.state;
- if (props.colorHex !== colorHex || props.isRunningData !== isRunningData) {
- this.setState({
- isRunningData: props.isRunningData,
- colorHex: props.colorHex,
- });
- }
- }
-
componentDidUpdate(prevProps) {
const {
isDistractionFreeModeActive,
layer,
width,
paletteLegends,
+ colorHex,
+ isRunningData,
} = this.props;
+
+ // Keep state in sync with prop changes, without clobbering hover-driven state.
+ if (prevProps.colorHex !== colorHex || prevProps.isRunningData !== isRunningData) {
+ this.setState({
+ colorHex,
+ isRunningData,
+ });
+ return;
+ }
+
// Updates when layer options/settings changed, if ZOT changes the width of the palette,
// or distraction free mode exit
const layerChange = !lodashIsEqual(layer, prevProps.layer);
diff --git a/web/js/components/timeline/mobile-date-picker.js b/web/js/components/timeline/mobile-date-picker.js
index 794cfde21..cda64a3b3 100644
--- a/web/js/components/timeline/mobile-date-picker.js
+++ b/web/js/components/timeline/mobile-date-picker.js
@@ -1,10 +1,11 @@
-import { useEffect, useState } from 'react';
+import { useEffect, useRef, useState } from 'react';
+import { createPortal } from 'react-dom';
import PropTypes from 'prop-types';
-import DatePicker from 'react-mobile-datepicker';
+import DatePicker from '../../util/react-mobile-datepicker';
import { getDisplayDate, getISODateFormatted } from './date-util';
import { MONTH_STRING_ARRAY } from '../../modules/date/constants';
-// https://www.npmjs.com/package/react-mobile-datepicker
+// Local datepicker utility adapted from react-mobile-datepicker
// configs for date order, caption, and date step
const defaultDateConfig = {
year: {
@@ -78,6 +79,7 @@ function MobileDatePicker(props) {
const [minDate, setMinDate] = useState(convertToUTCDateObject(startDateLimit));
const [maxDate, setMaxDate] = useState(convertToUTCDateObject(endDateLimit));
const [isOpen, setIsOpen] = useState(false);
+ const portalElRef = useRef(null);
const setInitDates = () => {
setTime(convertToUTCDateObject(date));
@@ -89,8 +91,28 @@ function MobileDatePicker(props) {
setInitDates();
}, [endDateLimit, date]);
+ const ensurePortalContainer = () => {
+ if (portalElRef.current || typeof document === 'undefined') return;
+ const el = document.createElement('div');
+ el.classList.add('Modal-Portal');
+ document.body.appendChild(el);
+ portalElRef.current = el;
+ };
+
+ const removePortalContainer = () => {
+ const el = portalElRef.current;
+ if (!el) return;
+ if (el.parentNode) el.parentNode.removeChild(el);
+ portalElRef.current = null;
+ };
+
+ useEffect(() => () => {
+ removePortalContainer();
+ }, []);
+
const handleClickDateButton = () => {
if (!isEmbedModeActive) {
+ ensurePortalContainer();
setIsOpen(true);
}
};
@@ -98,6 +120,7 @@ function MobileDatePicker(props) {
const handleCancel = () => {
setTime(convertToUTCDateObject(date));
setIsOpen(false);
+ removePortalContainer();
};
const handleChange = (newDate) => {
@@ -108,11 +131,17 @@ function MobileDatePicker(props) {
setIsOpen(false);
setTime(newTime);
+ removePortalContainer();
+
// convert date back to local time
const newDate = convertToLocalDateObject(newTime);
onDateChange(getISODateFormatted(newDate));
};
+ const handleBackdropClick = (e) => {
+ if (e.target === e.currentTarget) handleCancel();
+ };
+
const getHeaderTime = (newTime, isSubdaily) => (
<div className="datepicker-header">
{getDisplayDate(new Date(convertToLocalDateObject(newTime)), isSubdaily)}
@@ -134,21 +163,32 @@ function MobileDatePicker(props) {
<span>{displayDate}</span>
</div>
</button>
- <DatePicker
- dateConfig={hasSubdailyLayers ? subDailyDateConfig : defaultDateConfig}
- showCaption
- theme="android-dark"
- customHeader={headerTime}
- confirmText="OK"
- cancelText="CANCEL"
- min={minDate}
- max={maxDate}
- value={time}
- isOpen={isOpen}
- onCancel={handleCancel}
- onChange={handleChange}
- onSelect={handleSelect}
- />
+ {isOpen && portalElRef.current &&
+ createPortal(
+ (
+ <div className="datepicker-modal" onClick={handleBackdropClick}>
+ <DatePicker
+ isPopup={false}
+ dateConfig={hasSubdailyLayers ? subDailyDateConfig : defaultDateConfig}
+ showHeader
+ showFooter
+ showCaption
+ theme="android-dark"
+ customHeader={headerTime}
+ confirmText="OK"
+ cancelText="CANCEL"
+ min={minDate}
+ max={maxDate}
+ value={time}
+ isOpen={isOpen}
+ onCancel={handleCancel}
+ onChange={handleChange}
+ onSelect={handleSelect}
+ />
+ </div>
+ ),
+ portalElRef.current,
+ )}
</>
)
);
diff --git a/web/js/components/timeline/timeline-axis/timeline-axis.js b/web/js/components/timeline/timeline-axis/timeline-axis.js
index 7d110db1c..d4003c923 100644
--- a/web/js/components/timeline/timeline-axis/timeline-axis.js
+++ b/web/js/components/timeline/timeline-axis/timeline-axis.js
@@ -1,4 +1,4 @@
-import { Component } from 'react';
+import { Component, createRef } from 'react';
import PropTypes from 'prop-types';
import Draggable from 'react-draggable';
import moment from 'moment';
@@ -59,6 +59,8 @@ class TimelineAxis extends Component {
constructor(props) {
super(props);
+
+ this.nodeRef = createRef();
this.state = {
init: true,
draggerWidth: 49,
@@ -1637,6 +1639,7 @@ class TimelineAxis extends Component {
<Draggable
axis="x"
handle=".axis-grid-container"
+ nodeRef={this.nodeRef}
position={{ x: position, y: 0 }}
onDrag={this.handleDrag}
onStart={this.handleStartDrag}
@@ -1645,7 +1648,7 @@ class TimelineAxis extends Component {
left: leftBound, top: 0, bottom: 0, right: rightBound,
}}
>
- <g clipPath="url(#timelineBoundary)">
+ <g ref={this.nodeRef} clipPath="url(#timelineBoundary)">
<GridRange
showHover={showHover}
timeScale={timeScale}
diff --git a/web/js/components/timeline/timeline-controls/date-change-arrows.js b/web/js/components/timeline/timeline-controls/date-change-arrows.js
index cc6f02dbe..ca86080f8 100644
--- a/web/js/components/timeline/timeline-controls/date-change-arrows.js
+++ b/web/js/components/timeline/timeline-controls/date-change-arrows.js
@@ -110,7 +110,7 @@ class DateChangeArrows extends PureComponent {
placement="top"
target="left-arrow-group"
/>
- <ArrowChevronLeft class="arrow" size="30px" />
+ <ArrowChevronLeft className="arrow" size="30px" />
</button>
{/* RIGHT ARROW */}
@@ -130,7 +130,7 @@ class DateChangeArrows extends PureComponent {
placement="top"
target="right-arrow-group"
/>
- <ArrowChevronRight class="arrow" size="30px" />
+ <ArrowChevronRight className="arrow" size="30px" />
</button>
{/* NOW BUTTON */}
diff --git a/web/js/components/timeline/timeline-draggers/timeline-dragger.js b/web/js/components/timeline/timeline-draggers/timeline-dragger.js
index 98ff36820..fd0754666 100644
--- a/web/js/components/timeline/timeline-draggers/timeline-dragger.js
+++ b/web/js/components/timeline/timeline-draggers/timeline-dragger.js
@@ -1,4 +1,4 @@
-import { PureComponent } from 'react';
+import { PureComponent, createRef } from 'react';
import PropTypes from 'prop-types';
import Draggable from 'react-draggable';
@@ -11,6 +11,8 @@ import Draggable from 'react-draggable';
class Dragger extends PureComponent {
constructor(props) {
super(props);
+
+ this.nodeRef = createRef();
this.state = {
isHoveredDragging: false,
isHoveredDrag: false,
@@ -146,6 +148,7 @@ class Dragger extends PureComponent {
? (
<Draggable
axis="x"
+ nodeRef={this.nodeRef}
onMouseDown={this.selectDragger}
onDrag={this.handleDragDragger}
position={{ x: draggerPosition + 25, y: 0 }}
@@ -154,6 +157,7 @@ class Dragger extends PureComponent {
disabled={disabled}
>
<g
+ ref={this.nodeRef}
style={{
cursor: 'pointer',
}}
diff --git a/web/js/components/tour/content-intro.js b/web/js/components/tour/content-intro.js
index 8feb108bf..30116567e 100644
--- a/web/js/components/tour/content-intro.js
+++ b/web/js/components/tour/content-intro.js
@@ -14,7 +14,7 @@ function TourIntro(props) {
{' '}
<a href="#" title="Start using @NAME@" onClick={props.toggleModalStart} className="start-link">
Start using @NAME@
- <ArrowLineRightCircleFill class="intro-arrow" size="16px" />
+ <ArrowLineRightCircleFill className="intro-arrow" size="16px" />
</a>
</p>
</div>
diff --git a/web/js/components/tour/modal-tour-complete.js b/web/js/components/tour/modal-tour-complete.js
index aba8dc93b..0f60238ec 100644
--- a/web/js/components/tour/modal-tour-complete.js
+++ b/web/js/components/tour/modal-tour-complete.js
@@ -11,7 +11,7 @@ function ModalComplete(props) {
const { readMoreLinks } = currentStory;
const closeBtn = (
<button className="tour-close-btn" onClick={endTour} type="button">
- <Close class="add-plus" size="14px" />
+ <Close className="add-plus" size="14px" />
</button>
);
let list;
@@ -23,10 +23,10 @@ function ModalComplete(props) {
<>
<p>Read more about this story at the links below:</p>
<ul>
- {readMoreLinks.map((linkId) => (
- <li key={linkId}>
- <a href={linkId.link} target="_blank" rel="noopener noreferrer">
- {linkId.title}
+ {readMoreLinks.map((linkObj) => (
+ <li key={`${linkObj.link || 'link'}-${linkObj.title || 'title'}`}>
+ <a href={linkObj.link} target="_blank" rel="noopener noreferrer">
+ {linkObj.title}
</a>
</li>
))}
diff --git a/web/js/components/tour/modal-tour-in-progress.js b/web/js/components/tour/modal-tour-in-progress.js
index c552115c0..7ee96d3cf 100644
--- a/web/js/components/tour/modal-tour-in-progress.js
+++ b/web/js/components/tour/modal-tour-in-progress.js
@@ -7,6 +7,11 @@ import { Close } from '@edsc/earthdata-react-icons/horizon-design-system/hds/ui'
import Steps from './widget-steps';
class ModalInProgress extends React.Component {
+ constructor(props) {
+ super(props);
+ this.stepContentRef = React.createRef();
+ }
+
render() {
const {
className,
@@ -22,7 +27,7 @@ class ModalInProgress extends React.Component {
} = this.props;
const closeBtn = (
<button className={isKioskModeActive ? 'd-none' : 'end-tour-close-btn'} onClick={endTour} type="button">
- <Close class="add-plus" size="14px" />
+ <Close className="add-plus" size="14px" />
</button>
);
return (
@@ -44,7 +49,7 @@ class ModalInProgress extends React.Component {
<ModalBody>
{ }
<div
- ref="stepContent"
+ ref={this.stepContentRef}
dangerouslySetInnerHTML={{ __html: description }}
/>
{ }
diff --git a/web/js/components/tour/modal-tour-start.js b/web/js/components/tour/modal-tour-start.js
index 5f386d2ab..9e8c46a14 100644
--- a/web/js/components/tour/modal-tour-start.js
+++ b/web/js/components/tour/modal-tour-start.js
@@ -45,7 +45,7 @@ class ModalStart extends React.Component {
const { checked } = this.state;
const closeBtn = (
<button className="tour-close-btn" onClick={endTour} type="button">
- <Close class="add-plus" size="14px" />
+ <Close className="add-plus" size="14px" />
</button>
);
return (
diff --git a/web/js/components/tour/tour-box.js b/web/js/components/tour/tour-box.js
index ffdb76076..fa16dac9e 100644
--- a/web/js/components/tour/tour-box.js
+++ b/web/js/components/tour/tour-box.js
@@ -4,25 +4,17 @@ import PropTypes from 'prop-types';
class TourBox extends React.Component {
constructor(props) {
super(props);
+ const { backgroundImage, storyId } = props;
this.state = {
- styles: { },
+ styles: backgroundImage
+ ? { backgroundImage: `url(config/metadata/stories/${storyId}/${backgroundImage})` }
+ : {},
};
this.onMouseOver = this.onMouseOver.bind(this);
this.onMouseOut = this.onMouseOut.bind(this);
}
- UNSAFE_componentWillMount() {
- const { backgroundImage, storyId } = this.props;
- if (backgroundImage) {
- this.setState({
- styles: {
- backgroundImage: `url(config/metadata/stories/${storyId}/${backgroundImage})`,
- },
- });
- }
- }
-
onMouseOver(e) {
const { backgroundImageHover, storyId } = this.props;
e.preventDefault();
diff --git a/web/js/components/util/button.js b/web/js/components/util/button.js
index 8556794b2..a8e02431b 100644
--- a/web/js/components/util/button.js
+++ b/web/js/components/util/button.js
@@ -6,7 +6,12 @@ import PropTypes from 'prop-types';
*/
export default function Button(props) {
const {
- id, onClick, style, valid, className, text,
+ id = '',
+ onClick,
+ style = null,
+ valid = true,
+ className = 'gray',
+ text,
} = props;
return (
<button
diff --git a/web/js/components/util/checkbox.js b/web/js/components/util/checkbox.js
index 33649df44..0b3f39313 100644
--- a/web/js/components/util/checkbox.js
+++ b/web/js/components/util/checkbox.js
@@ -37,7 +37,7 @@ export default function Checkbox (props) {
tabIndex="0"
/>
{checked && (
- <Check class="check" size="15px" />
+ <Check className="check" size="15px" />
)}
{children}
<label htmlFor={id}>
diff --git a/web/js/components/util/swipe-to-delete.js b/web/js/components/util/swipe-to-delete.js
new file mode 100644
index 000000000..e6a677829
--- /dev/null
+++ b/web/js/components/util/swipe-to-delete.js
@@ -0,0 +1,122 @@
+import { useRef, useState } from 'react';
+import PropTypes from 'prop-types';
+
+export default function SwipeToDelete(props) {
+ const {
+ children,
+ deleteSwipe,
+ item,
+ onDelete,
+ } = props;
+
+ const containerRef = useRef(null);
+ const pointerIdRef = useRef(null);
+ const startRef = useRef({ x: 0, y: 0 });
+ const directionDecidedRef = useRef(false);
+ const isHorizontalRef = useRef(false);
+
+ const [translateX, setTranslateX] = useState(0);
+ const [isDragging, setIsDragging] = useState(false);
+
+ const getWidth = () => containerRef.current?.getBoundingClientRect()?.width || 0;
+
+ const resetGesture = () => {
+ pointerIdRef.current = null;
+ directionDecidedRef.current = false;
+ isHorizontalRef.current = false;
+ setIsDragging(false);
+ setTranslateX(0);
+ };
+
+ const onPointerDown = (e) => {
+ // Only track primary pointer; allow scroll until we detect a horizontal swipe.
+ if (pointerIdRef.current !== null) return;
+ pointerIdRef.current = e.pointerId;
+ startRef.current = { x: e.clientX, y: e.clientY };
+ directionDecidedRef.current = false;
+ isHorizontalRef.current = false;
+ setIsDragging(false);
+
+ // Capture so we keep getting move/up even if pointer leaves.
+ if (containerRef.current?.setPointerCapture) {
+ containerRef.current.setPointerCapture(e.pointerId);
+ }
+ };
+
+ const onPointerMove = (e) => {
+ if (pointerIdRef.current !== e.pointerId) return;
+
+ const dx = e.clientX - startRef.current.x;
+ const dy = e.clientY - startRef.current.y;
+
+ if (!directionDecidedRef.current) {
+ const absDx = Math.abs(dx);
+ const absDy = Math.abs(dy);
+
+ // Don’t decide too early; small jitter should still allow vertical scroll.
+ if (absDx < 10 && absDy < 10) return;
+
+ directionDecidedRef.current = true;
+ isHorizontalRef.current = absDx > absDy;
+ setIsDragging(isHorizontalRef.current);
+ }
+
+ if (!isHorizontalRef.current) return;
+
+ // We’re handling a horizontal swipe; prevent scrolling/selection.
+ if (e.cancelable) e.preventDefault();
+
+ // Only allow swipe left to delete.
+ const nextTranslate = Math.min(0, dx);
+ setTranslateX(nextTranslate);
+ };
+
+ const onPointerUp = (e) => {
+ if (pointerIdRef.current !== e.pointerId) return;
+
+ if (isHorizontalRef.current) {
+ const width = getWidth();
+ const threshold = width * deleteSwipe;
+ if (Math.abs(translateX) >= threshold && threshold > 0) {
+ onDelete?.(item);
+ }
+ }
+
+ resetGesture();
+ };
+
+ const onPointerCancel = (e) => {
+ if (pointerIdRef.current !== e.pointerId) return;
+ resetGesture();
+ };
+
+ return (
+ <div
+ ref={containerRef}
+ onPointerDown={onPointerDown}
+ onPointerMove={onPointerMove}
+ onPointerUp={onPointerUp}
+ onPointerCancel={onPointerCancel}
+ style={{
+ touchAction: 'pan-y',
+ transform: `translateX(${translateX}px)`,
+ transition: isDragging ? 'none' : 'transform 150ms ease-out',
+ }}
+ >
+ {children}
+ </div>
+ );
+}
+
+SwipeToDelete.defaultProps = {
+ deleteSwipe: 0.33,
+ item: null,
+ onDelete: null,
+};
+
+SwipeToDelete.propTypes = {
+ children: PropTypes.node.isRequired,
+ deleteSwipe: PropTypes.number,
+ item: PropTypes.oneOfType([PropTypes.object, PropTypes.oneOf([null])]),
+ onDelete: PropTypes.func,
+};
diff --git a/web/js/components/util/visibility-sensor.js b/web/js/components/util/visibility-sensor.js
new file mode 100644
index 000000000..373f5a184
--- /dev/null
+++ b/web/js/components/util/visibility-sensor.js
@@ -0,0 +1,60 @@
+import { useEffect, useRef, useState } from 'react';
+import PropTypes from 'prop-types';
+
+export default function VisibilitySensor(props) {
+ const {
+ children,
+ containment,
+ partialVisibility,
+ } = props;
+
+ const containerRef = useRef(null);
+ const [isVisible, setIsVisible] = useState(false);
+
+ useEffect(() => {
+ const el = containerRef.current;
+ if (!el) return undefined;
+
+ if (typeof IntersectionObserver === 'undefined') {
+ setIsVisible(true);
+ return undefined;
+ }
+
+ const observer = new IntersectionObserver(
+ (entries) => {
+ const entry = entries && entries.length ? entries[0] : null;
+ setIsVisible(!!entry?.isIntersecting);
+ },
+ {
+ root: containment || null,
+ threshold: partialVisibility ? 0 : 1,
+ },
+ );
+
+ observer.observe(el);
+
+ return () => {
+ observer.disconnect();
+ };
+ }, [containment, partialVisibility]);
+
+ return (
+ <div ref={containerRef} style={{ display: 'contents' }}>
+ {typeof children === 'function' ? children({ isVisible }) : children}
+ </div>
+ );
+}
+
+VisibilitySensor.defaultProps = {
+ containment: null,
+ partialVisibility: false,
+};
+
+VisibilitySensor.propTypes = {
+ children: PropTypes.oneOfType([PropTypes.func, PropTypes.node]).isRequired,
+ containment: PropTypes.oneOfType([
+ PropTypes.instanceOf(Element),
+ PropTypes.oneOf([null]),
+ ]),
+ partialVisibility: PropTypes.bool,
+};
diff --git a/web/js/components/vector-metadata/table.test.js b/web/js/components/vector-metadata/table.test.js
index a5741db62..8311b71db 100644
--- a/web/js/components/vector-metadata/table.test.js
+++ b/web/js/components/vector-metadata/table.test.js
@@ -1,43 +1,63 @@
+import { act } from 'react';
import renderer from 'react-test-renderer';
import VectorMetaTable from './table';
+let consoleErrorSpy;
+let originalConsoleError;
+
+beforeAll(() => {
+ originalConsoleError = console.error;
+ consoleErrorSpy = jest.spyOn(console, 'error').mockImplementation((...args) => {
+ if (typeof args[0] === 'string' && args[0].includes('react-test-renderer is deprecated')) return;
+ originalConsoleError.call(console, ...args);
+ });
+});
+
+afterAll(() => {
+ if (consoleErrorSpy) consoleErrorSpy.mockRestore();
+});
+
let component;
beforeEach(() => {
- component = renderer.create(
- <VectorMetaTable
- metaArray={[{
- features: {
- GRAND_ID: 4886,
- },
- legend: [{ Identifier: 'GRAND_ID' }],
- featureTitle: 'Choclococha',
- }]}
- />,
- );
+ act(() => {
+ component = renderer.create(
+ <VectorMetaTable
+ metaArray={[{
+ features: {
+ GRAND_ID: 4886,
+ },
+ legend: [{ Identifier: 'GRAND_ID' }],
+ featureTitle: 'Choclococha',
+ }]}
+ />,
+ );
+ });
});
test('Check that there is not popup', () => {
expect(component.toJSON()).toMatchSnapshot();
});
test('If there is a valuemap, use valuemap', () => {
- component = renderer.create(
- <VectorMetaTable
- metaArray={[{
- features: {
- GRAND_ID: 4886,
- Urborrur: 'U',
- },
- legend: [
- {
- Identifier: 'GRAND_ID',
- }, {
- Identifier: 'Urborrur',
- ValueMap: { U: 'Urban', R: 'Rural' },
+ act(() => {
+ component = renderer.create(
+ <VectorMetaTable
+ metaArray={[{
+ features: {
+ GRAND_ID: 4886,
+ Urborrur: 'U',
},
- ],
- featureTitle: 'Choclococha',
- }]}
- />,
- );
+ legend: [
+ {
+ Identifier: 'GRAND_ID',
+ }, {
+ Identifier: 'Urborrur',
+ ValueMap: { U: 'Urban', R: 'Rural' },
+ },
+ ],
+ featureTitle: 'Choclococha',
+ }]}
+ />,
+ );
+ });
expect(component.toJSON()).toMatchSnapshot();
});
diff --git a/web/js/containers/alerts.js b/web/js/containers/alerts.js
index ad69e44d1..fd1ee493d 100644
--- a/web/js/containers/alerts.js
+++ b/web/js/containers/alerts.js
@@ -172,7 +172,8 @@ class DismissableAlerts extends React.Component {
{showDDVZoomAlert &&
ddvZoomAlerts.map((layer) => (
<AlertUtil
- id="zoom-alert"
+ key={`ddv-zoom-${layer}`}
+ id={`zoom-alert-${`${layer}`.replace(/[^a-z0-9_-]/gi, '-')}`}
isOpen
noPortal
title="Zoom in to see imagery for this layer"
@@ -185,7 +186,8 @@ class DismissableAlerts extends React.Component {
{ showDDVLocationAlert &&
ddvLocationAlerts.map((layer) => (
<AlertUtil
- id="granule-alert"
+ key={`ddv-location-${layer}`}
+ id={`granule-alert-${`${layer}`.replace(/[^a-z0-9_-]/gi, '-')}`}
isOpen
noPortal
title="Try moving the map or select a different date in the layer's settings."
diff --git a/web/js/containers/animation-widget/collapsed-animation-widget.js b/web/js/containers/animation-widget/collapsed-animation-widget.js
index bc1f8a642..2481d0ed7 100644
--- a/web/js/containers/animation-widget/collapsed-animation-widget.js
+++ b/web/js/containers/animation-widget/collapsed-animation-widget.js
@@ -1,9 +1,11 @@
+import { useRef } from 'react';
import PropTypes from 'prop-types';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import Draggable from 'react-draggable';
import PlayButton from '../../components/animation-widget/play-button';
function CollapsedAnimationWidget (props) {
+ const nodeRef = useRef(null);
const {
breakpoints,
collapsedWidgetPosition,
@@ -54,6 +56,7 @@ function CollapsedAnimationWidget (props) {
return !dontShow && (
<Draggable
+ nodeRef={nodeRef}
bounds="body"
cancel={cancelSelector}
onStart={handleDragStart}
@@ -62,6 +65,7 @@ function CollapsedAnimationWidget (props) {
disabled={isMobile}
>
<div
+ ref={nodeRef}
className={widgetClasses}
id={`collapsed-animate-widget${widgetIDs}`}
>
diff --git a/web/js/containers/animation-widget/desktop-animation-widget.js b/web/js/containers/animation-widget/desktop-animation-widget.js
index 03be2d8b0..b6069ac20 100644
--- a/web/js/containers/animation-widget/desktop-animation-widget.js
+++ b/web/js/containers/animation-widget/desktop-animation-widget.js
@@ -1,3 +1,4 @@
+import { useRef } from 'react';
import PropTypes from 'prop-types';
import Draggable from 'react-draggable';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
@@ -9,6 +10,7 @@ import TimeScaleIntervalChange from '../../components/timeline/timeline-controls
import CustomIntervalSelector from '../../components/timeline/custom-interval-selector/custom-interval-selector';
function DesktopAnimationWidget(props) {
+ const nodeRef = useRef(null);
const {
animationCustomModalOpen,
autoplay,
@@ -52,6 +54,7 @@ function DesktopAnimationWidget(props) {
return (
<Draggable
+ nodeRef={nodeRef}
bounds="body"
cancel={cancelSelector}
handle=".wv-animation-widget-header"
@@ -59,7 +62,7 @@ function DesktopAnimationWidget(props) {
onDrag={onExpandedDrag}
onStart={handleDragStart}
>
- <div className={`wv-animation-widget-wrapper ${hideWidget}`}>
+ <div ref={nodeRef} className={`wv-animation-widget-wrapper ${hideWidget}`}>
<div
id="wv-animation-widget"
className={`wv-animation-widget${subDailyMode ? ' subdaily' : ''}`}
diff --git a/web/js/containers/map-interactions/ol-vector-interactions.test.js b/web/js/containers/map-interactions/ol-vector-interactions.test.js
index 09a6b0b2f..becc55c55 100644
--- a/web/js/containers/map-interactions/ol-vector-interactions.test.js
+++ b/web/js/containers/map-interactions/ol-vector-interactions.test.js
@@ -1,9 +1,25 @@
+import { act } from 'react';
import renderer from 'react-test-renderer';
import util from '../../util/util';
import { VectorInteractions } from './ol-vector-interactions';
import { registerProjections } from '../../fixtures';
import { MAP_MOUSE_MOVE, MAP_SINGLE_CLICK } from '../../util/constants';
+let consoleErrorSpy;
+let originalConsoleError;
+
+beforeAll(() => {
+ originalConsoleError = console.error;
+ consoleErrorSpy = jest.spyOn(console, 'error').mockImplementation((...args) => {
+ if (typeof args[0] === 'string' && args[0].includes('react-test-renderer is deprecated')) return;
+ originalConsoleError.call(console, ...args);
+ });
+});
+
+afterAll(() => {
+ if (consoleErrorSpy) consoleErrorSpy.mockRestore();
+});
+
const { events } = util;
let component;
let map;
@@ -19,24 +35,26 @@ beforeEach(() => {
getDialogObject = () => ({
metaArray: [0], selected: [1], offsetLeft: 100, offsetTop: 100,
});
- component = renderer.create(
- <VectorInteractions
- mouseEvents={events}
- isShowingClick={false}
- changeCursor={changeCursor}
- getDialogObject={getDialogObject}
- openVectorDialog={openVectorDialog}
- selectVectorFeatures={selectVectorFeatures}
- lastSelected={{}}
- measureIsActive={false}
- onCloseModal={jest.fn()}
- modalState={{ id: [], isOpen: false }}
- isDistractionFreeModeActive={false}
- isMobile={false}
- proj={{ id: 'geographic' }}
- activeLayers={[{ def: { type: 'vector' } }]}
- />,
- );
+ act(() => {
+ component = renderer.create(
+ <VectorInteractions
+ mouseEvents={events}
+ isShowingClick={false}
+ changeCursor={changeCursor}
+ getDialogObject={getDialogObject}
+ openVectorDialog={openVectorDialog}
+ selectVectorFeatures={selectVectorFeatures}
+ lastSelected={{}}
+ measureIsActive={false}
+ onCloseModal={jest.fn()}
+ modalState={{ id: [], isOpen: false }}
+ isDistractionFreeModeActive={false}
+ isMobile={false}
+ proj={{ id: 'geographic' }}
+ activeLayers={[{ def: { type: 'vector' } }]}
+ />,
+ );
+ });
map = {
getEventPixel: jest.fn(),
getCoordinateFromPixel: () => [0, 0],
@@ -59,7 +77,9 @@ test('if there is a feature at pixel dispatch changeCursor action', () => {
doAsync(() => expect(changeCursor.mock.calls.length).toBe(1));
});
test('if there is a feature at pixel on click get dialog', () => {
- events.trigger(MAP_SINGLE_CLICK, { pixel: [0, 0] }, map, 'EPSG:4326');
+ act(() => {
+ events.trigger(MAP_SINGLE_CLICK, { pixel: [0, 0] }, map, 'EPSG:4326');
+ });
expect(changeCursor.mock.calls.length).toBe(0);
expect(selectVectorFeatures.mock.calls.length).toBe(1);
expect(openVectorDialog.mock.calls.length).toBe(1);
diff --git a/web/js/containers/modal.js b/web/js/containers/modal.js
index 6eb046df3..00795816d 100644
--- a/web/js/containers/modal.js
+++ b/web/js/containers/modal.js
@@ -1,4 +1,4 @@
-import { useState, useEffect, useCallback } from 'react';
+import { useState, useEffect, useCallback, useRef } from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import update from 'immutability-helper';
@@ -57,6 +57,7 @@ function ModalContainer(props) {
const [offsetTop, setOffsetTop] = useState(propsOffsetTop);
const [offsetRight, setOffsetRight] = useState(propsOffsetRight);
const [measuredElement, setMeasuredElement] = useState();
+ const draggableNodeRef = useRef(null);
const prevScreenHeight = usePrevious(screenHeight);
const prevScreenWidth = usePrevious(screenWidth);
const prevWidth = usePrevious(width);
@@ -185,6 +186,7 @@ function ModalContainer(props) {
: '';
return (
<Draggable
+ nodeRef={draggableNodeRef}
handle={dragHandle}
disabled={!isDraggable}
bounds={bounds}
@@ -264,6 +266,7 @@ function ModalContainer(props) {
isOpen={isOpen}
toggle={toggleFunction}
backdrop={backdrop}
+ innerRef={draggableNodeRef}
id={lowerCaseId}
size={size}
className={isTemplateModal ? 'template-modal' : modalClassName || 'default-modal'}
diff --git a/web/js/containers/sidebar/add-layers-content.js b/web/js/containers/sidebar/add-layers-content.js
index 2f4d74388..1f5777635 100644
--- a/web/js/containers/sidebar/add-layers-content.js
+++ b/web/js/containers/sidebar/add-layers-content.js
@@ -40,7 +40,7 @@ function AddLayersContent (props) {
className="layers-add red"
text={(
<>
- <Plus class="add-plus" size="10px" />
+ <Plus className="add-plus" size="10px" />
Add Layers
</>
)}
diff --git a/web/js/containers/timeline/timeline.js b/web/js/containers/timeline/timeline.js
index d7b71f348..de040139c 100644
--- a/web/js/containers/timeline/timeline.js
+++ b/web/js/containers/timeline/timeline.js
@@ -322,7 +322,12 @@ class Timeline extends React.Component {
// handle location update triggered from animation start/end date change from animation widget
if (isAnimationWidgetOpen) {
- if (prevStartLocationDate && prevEndLocationDate) {
+ if (
+ prevStartLocationDate &&
+ prevEndLocationDate &&
+ animStartLocationDate &&
+ animEndLocationDate
+ ) {
const animStartDateChanged = prevStartLocationDate.getTime() !==
animStartLocationDate.getTime();
const animEndDateChanged = prevEndLocationDate.getTime() !== animEndLocationDate.getTime();
diff --git a/web/js/location.js b/web/js/location.js
index f9dece0a5..cac197a7d 100644
--- a/web/js/location.js
+++ b/web/js/location.js
@@ -61,7 +61,7 @@ export const mapLocationToState = (state, location) => {
const { config } = state;
if (location.search) {
const parameters = util.fromQueryString(location.search);
- let stateFromLocation = location.query;
+ let stateFromLocation = location.query || {};
stateFromLocation = mapLocationToDateState(
parameters,
stateFromLocation,
diff --git a/web/js/main.js b/web/js/main.js
index a851ae06e..0c3a23c09 100644
--- a/web/js/main.js
+++ b/web/js/main.js
@@ -9,7 +9,7 @@ import { configureStore } from '@reduxjs/toolkit';
import {
createReduxLocationActions,
listenForHistoryChange,
-} from 'redux-location-state';
+} from './redux-location-state';
import { createBrowserHistory } from 'history';
import { uniqBy, get as lodashGet } from 'lodash';
import getMiddleware from './combine-middleware';
diff --git a/web/js/map/compare/opacity.js b/web/js/map/compare/opacity.js
index e61f9cdf2..4ddd2b88c 100644
--- a/web/js/map/compare/opacity.js
+++ b/web/js/map/compare/opacity.js
@@ -7,13 +7,15 @@ import { COMPARE_MOVE_END } from '../../util/constants';
const { events } = util;
-let slider;
let value = 50;
export default class Opacity {
constructor(olMap, store, eventListenerStringObj, valueOverride) {
this.map = olMap;
this.sliderCase = document.createElement('div');
+ this.root = createRoot(this.sliderCase);
+ this.mapCase = null;
+ this.isDestroyed = false;
value = Number(valueOverride) || value;
this.create(store);
}
@@ -23,7 +25,7 @@ export default class Opacity {
const { dateA, dateB } = getCompareDates(state);
this.dateA = dateA;
this.dateB = dateB;
- slider = this.createSlider(this.map.getLayers().getArray());
+ this.renderSlider(this.map.getLayers().getArray());
this.oninput(value);
}
@@ -33,22 +35,36 @@ export default class Opacity {
update(store) {
const state = store.getState();
const { dateA, dateB } = getCompareDates(state);
- if (dateA !== this.dateA || dateB !== this.dateB) {
- this.destroy();
- this.create(store);
- } else {
- [this.firstLayer, this.secondLayer] = this.map.getLayers().getArray();
- this.oninput(value);
- }
+ this.dateA = dateA;
+ this.dateB = dateB;
+ this.renderSlider(this.map.getLayers().getArray());
+ this.oninput(value);
}
/**
* Remove all nodes
*/
destroy() {
- const root = createRoot(slider);
- root.unmount(slider);
- this.mapCase.removeChild(slider);
+ if (this.isDestroyed) return;
+ this.isDestroyed = true;
+
+ const root = this.root;
+ const sliderCase = this.sliderCase;
+ const mapCase = this.mapCase;
+
+ // Prevent further renders immediately.
+ this.root = null;
+
+ // Avoid unmounting during an in-progress React render elsewhere.
+ setTimeout(() => {
+ try {
+ root?.unmount();
+ } finally {
+ if (mapCase && sliderCase && sliderCase.parentNode === mapCase) {
+ mapCase.removeChild(sliderCase);
+ }
+ }
+ }, 0);
}
/**
@@ -56,19 +72,22 @@ export default class Opacity {
* @param {Object} map | OL Map Object
* @param {Object} secondLayer | Second layer group on Map
*/
- createSlider(layerArray) {
+ renderSlider(layerArray) {
+ if (this.isDestroyed || !this.root) return;
[this.firstLayer, this.secondLayer] = layerArray;
- this.mapCase = document.getElementById('wv-map');
+ if (!this.mapCase) {
+ this.mapCase = document.getElementById('wv-map');
+ }
const Props = {
onSlide: this.oninput.bind(this),
value,
dateA: this.dateA,
dateB: this.dateB,
};
- this.mapCase.appendChild(this.sliderCase);
- const root = createRoot(this.sliderCase);
- root.render(React.createElement(OpacitySlider, Props));
- return this.sliderCase;
+ if (this.mapCase && this.sliderCase.parentNode !== this.mapCase) {
+ this.mapCase.appendChild(this.sliderCase);
+ }
+ this.root.render(React.createElement(OpacitySlider, Props));
}
/**
diff --git a/web/js/modules/animation/util.js b/web/js/modules/animation/util.js
index 88efc1435..6f3084f4b 100644
--- a/web/js/modules/animation/util.js
+++ b/web/js/modules/animation/util.js
@@ -157,16 +157,21 @@ export function mapLocationToAnimationState(
let stateFromLocation = stateFromLocationObj;
const startDate = lodashGet(stateFromLocation, 'animation.startDate');
const endDate = lodashGet(stateFromLocation, 'animation.endDate');
- if (parameters.playanim && parameters.ab) {
- stateFromLocation = update(stateFromLocation, {
- animation: { isPlaying: { $set: true } },
- });
- } else if (
- parameters.ab !== 'on' &&
+ const isActiveFromParams = parameters.ab === 'on' || parameters.ab === true;
+ const isPlayingFromParams = !!parameters.playanim && isActiveFromParams;
+
+ stateFromLocation = update(stateFromLocation, {
+ animation: {
+ isActive: { $set: isActiveFromParams },
+ isPlaying: { $set: isPlayingFromParams },
+ },
+ });
+
+ if (
+ !isActiveFromParams &&
(!parameters.ae || (!parameters.as && (!!endDate || !!startDate)))
) {
// wipe anim start & end dates on tour change
-
stateFromLocation = update(stateFromLocation, {
animation: { endDate: { $set: undefined } },
});
diff --git a/web/js/modules/animation/util.test.js b/web/js/modules/animation/util.test.js
index 42280d739..473541bb8 100644
--- a/web/js/modules/animation/util.test.js
+++ b/web/js/modules/animation/util.test.js
@@ -12,9 +12,29 @@ test('mapLocationToAnimationState updates state to have isPlaying bool true if p
stateFromLocation,
);
expect(stateFromLocation.animation.isPlaying).toBeFalsy();
+ expect(response.animation.isActive).toBeTruthy();
expect(response.animation.isPlaying).toBeTruthy();
});
+test('mapLocationToAnimationState closes animation if ab is not present [animation-location-state]', () => {
+ const stateFromLocation = {
+ animation: {
+ ...defaultState,
+ isActive: true,
+ isPlaying: true,
+ startDate: new Date('2020-01-01T00:00:00Z'),
+ endDate: new Date('2020-01-02T00:00:00Z'),
+ },
+ };
+ const PERMALINK_STATE = {};
+ const response = mapLocationToAnimationState(
+ PERMALINK_STATE,
+ stateFromLocation,
+ );
+ expect(response.animation.isActive).toBeFalsy();
+ expect(response.animation.isPlaying).toBeFalsy();
+});
+
test('snapToIntervalDelta snaps at the year interval [animation-year-interval]', () => {
const currentDate = new Date('2010-06-23');
const startDate = new Date(' 2000-04-15');
diff --git a/web/js/modules/location-search/util.js b/web/js/modules/location-search/util.js
index 7d9cb9220..bd5777f61 100644
--- a/web/js/modules/location-search/util.js
+++ b/web/js/modules/location-search/util.js
@@ -52,7 +52,7 @@ const createPin = function(coordinates, pinProps, id, removeMarkerPin) {
const overlayEl = document.createElement('div');
const root = createRoot(overlayEl);
const removeMarker = () => {
- root.unmount(overlayEl);
+ root.unmount();
removeMarkerPin();
};
root.render(
diff --git a/web/js/modules/map/util.js b/web/js/modules/map/util.js
index 7e06cb638..2974357c7 100644
--- a/web/js/modules/map/util.js
+++ b/web/js/modules/map/util.js
@@ -168,6 +168,12 @@ function promiseTileLayer(layer, map) {
return new Promise((resolve) => {
if (!preloadMap) {
const mapContainerEl = document.getElementById('wv-map');
+ if (!mapContainerEl) {
+ // If the main map container isn't mounted yet, skip the preload-map
+ // optimization rather than throwing during layer creation.
+ resolve();
+ return;
+ }
const mapEl = document.createElement('div');
const id = 'wv-map-preload';
diff --git a/web/js/modules/natural-events/reducers.js b/web/js/modules/natural-events/reducers.js
index 0637adeed..16f079f30 100644
--- a/web/js/modules/natural-events/reducers.js
+++ b/web/js/modules/natural-events/reducers.js
@@ -24,16 +24,19 @@ import { CHANGE_TAB as CHANGE_SIDEBAR_TAB } from '../sidebar/constants';
* @returns
*/
const sortEvents = function(events) {
+ if (!Array.isArray(events) || events.length === 0) return [];
+
return events
.map((e) => {
- e.geometry = lodashOrderBy(e.geometry, 'date', 'desc');
+ const geometry = Array.isArray(e.geometry) ? e.geometry : [];
+ e.geometry = lodashOrderBy(geometry, 'date', 'desc');
// Discard duplicate geometry dates
e.geometry = lodashUniqBy(e.geometry, (g) => g.date.split('T')[0]);
return e;
})
.sort((eventA, eventB) => {
- const dateA = new Date(eventA.geometry[0].date).valueOf();
- const dateB = new Date(eventB.geometry[0].date).valueOf();
+ const dateA = new Date(eventA?.geometry?.[0]?.date || 0).valueOf();
+ const dateB = new Date(eventB?.geometry?.[0]?.date || 0).valueOf();
return dateB - dateA;
});
};
@@ -171,10 +174,12 @@ export function eventsRequestReducer(actionName, state, action) {
const key = actionName === REQUEST_EVENTS
? 'events'
: 'sources';
+
+ const payload = action?.response?.[key];
return eventRequestResponse({
response: actionName === REQUEST_EVENTS
- ? sortEvents(action.response[key])
- : action.response[key],
+ ? sortEvents(payload)
+ : (payload || null),
isLoading: false,
});
}
diff --git a/web/js/modules/projection/util.js b/web/js/modules/projection/util.js
index cd330ea5f..377e6ff67 100644
--- a/web/js/modules/projection/util.js
+++ b/web/js/modules/projection/util.js
@@ -30,7 +30,12 @@ export function mapLocationToProjState(parameters, stateFromLocationObj, state)
const selected = lodashGet(state, `config.projections.${projId}`);
if (selected) {
stateFromLocation = update(stateFromLocation, {
- proj: { selected: { $set: selected } },
+ proj: {
+ $set: {
+ ...(lodashGet(stateFromLocation, 'proj') || {}),
+ selected,
+ },
+ },
});
}
} else if (parameters.switch) {
@@ -46,7 +51,12 @@ export function mapLocationToProjState(parameters, stateFromLocationObj, state)
} else {
const selected = lodashGet(state, 'config.projections.geographic');
stateFromLocation = update(stateFromLocation, {
- proj: { selected: { $set: selected } },
+ proj: {
+ $set: {
+ ...(lodashGet(stateFromLocation, 'proj') || {}),
+ selected,
+ },
+ },
});
}
return stateFromLocation;
diff --git a/web/js/modules/screen-size/reducer.js b/web/js/modules/screen-size/reducer.js
index 925febf8e..732a05b45 100644
--- a/web/js/modules/screen-size/reducer.js
+++ b/web/js/modules/screen-size/reducer.js
@@ -10,14 +10,35 @@ export const initialState = {
isMobileTablet: false,
};
-export const getInitialState = () => ({
- breakpoints: {
+export const getInitialState = () => {
+ const breakpoints = {
extraSmall: 480,
small: 768,
medium: 992,
large: 1200,
- },
-});
+ };
+
+ // Seed initial screen info synchronously so connected components can render
+ // the correct mobile/desktop layout on first paint.
+ if (typeof window === 'undefined') {
+ return { breakpoints };
+ }
+
+ const screenHeight = window.innerHeight;
+ const screenWidth = window.innerWidth;
+ const isMobileDevice = screenWidth < breakpoints.small;
+ const orientation = screenHeight > screenWidth ? 'portrait' : 'landscape';
+
+ return {
+ breakpoints,
+ screenHeight,
+ screenWidth,
+ isMobileDevice,
+ orientation,
+ isMobilePhone: false,
+ isMobileTablet: false,
+ };
+};
export const screenSizeReducer = (state = initialState, action) => {
switch (action.type) {
diff --git a/web/js/redux-location-state-customs.js b/web/js/redux-location-state-customs.js
index efcc9e6de..c7b4f6851 100644
--- a/web/js/redux-location-state-customs.js
+++ b/web/js/redux-location-state-customs.js
@@ -1,13 +1,41 @@
import { each as lodashEach } from 'lodash';
-import {
- get,
- createObjectFromConfig,
- isEqual,
-} from 'redux-location-state/lib/helpers';
-import { typeHandles } from 'redux-location-state/lib/typeHandles';
+import { get as lodashGet, isEqual as lodashIsEqual } from 'lodash';
import { ENCODING_EXCEPTIONS } from './modules/link/constants';
export const LOCATION_POP_ACTION = 'REDUX-LOCATION-POP-ACTION';
+
+function createObjectFromConfig(config, location) {
+ // Worldview only uses a `global` config; keep the signature for compatibility.
+ if (config && typeof config === 'object') {
+ if (config.global && typeof config.global === 'object') return config.global;
+ }
+ return null;
+}
+
+const typeHandles = {
+ bool: {
+ serialize: (value) => (value ? 'true' : 'false'),
+ },
+ number: {
+ serialize: (value) => (typeof value === 'number' ? value.toString() : `${Number(value)}`),
+ },
+ date: {
+ serialize: (value) => (value && typeof value.toISOString === 'function' ? value.toISOString() : undefined),
+ },
+ array: {
+ serialize: (value) => (Array.isArray(value) ? value.join(',') : undefined),
+ },
+ object: {
+ serialize: (value) => {
+ if (!value || typeof value !== 'object') return undefined;
+ try {
+ return JSON.stringify(value);
+ } catch {
+ return undefined;
+ }
+ },
+ },
+};
function isNotDefined(value) {
return typeof value === 'undefined' || value === null;
}
@@ -49,7 +77,7 @@ export function stateToParams(initialState, currentState, location) {
initialState: initialValue,
type,
} = pathConfig[curr];
- let currentItemState = get(currentState, stateKey);
+ let currentItemState = lodashGet(currentState, stateKey);
let isDefault = false;
// check if the date is the same as the one in initial value
if (type === 'date') {
@@ -70,7 +98,7 @@ export function stateToParams(initialState, currentState, location) {
}
// check if the item is default
isDefault = typeof currentItemState === 'object'
- ? isEqual(initialValue, currentItemState)
+ ? lodashIsEqual(initialValue, currentItemState)
: currentItemState === initialValue;
}
// if it is default or doesn't exist don't make a query parameter
diff --git a/web/js/redux-location-state.js b/web/js/redux-location-state.js
new file mode 100644
index 000000000..401a759cb
--- /dev/null
+++ b/web/js/redux-location-state.js
@@ -0,0 +1,264 @@
+// Local replacement for the unmaintained `redux-location-state` package.
+
+const LOCATION_POP_ACTION = 'REDUX-LOCATION-POP-ACTION';
+
+function omitOverlayGroups(value) {
+ if (!value || typeof value !== 'object') return value;
+ if (!Object.prototype.hasOwnProperty.call(value, 'overlayGroups')) return value;
+ return Object.entries(value).reduce((acc, [key, entryValue]) => {
+ if (key !== 'overlayGroups') acc[key] = entryValue;
+ return acc;
+ }, {});
+}
+
+function isPlainObject(value) {
+ if (!value || typeof value !== 'object') return false;
+ return Object.prototype.toString.call(value) === '[object Object]';
+}
+
+function mergeDeep(baseValue, patchValue) {
+ if (typeof patchValue === 'undefined') return baseValue;
+ if (Array.isArray(patchValue)) return patchValue;
+ if (isPlainObject(baseValue) && isPlainObject(patchValue)) {
+ const merged = { ...baseValue };
+ Object.keys(patchValue).forEach((key) => {
+ merged[key] = mergeDeep(baseValue[key], patchValue[key]);
+ });
+ return merged;
+ }
+ // Dates, class instances, functions, etc: replace.
+ return patchValue;
+}
+
+function safeDecode(value) {
+ if (typeof value !== 'string') return value;
+ try {
+ return decodeURIComponent(value);
+ } catch {
+ return value;
+ }
+}
+
+function parseSearch(search) {
+ if (!search) return {};
+ const queryString = search[0] === '?' ? search.slice(1) : search;
+ if (!queryString) return {};
+
+ return queryString.split('&').reduce((acc, part) => {
+ if (!part) return acc;
+ const equalsIndex = part.indexOf('=');
+ if (equalsIndex === -1) {
+ acc[safeDecode(part)] = '';
+ return acc;
+ }
+ const key = safeDecode(part.slice(0, equalsIndex));
+ const value = safeDecode(part.slice(equalsIndex + 1));
+ acc[key] = value;
+ return acc;
+ }, {});
+}
+
+function setAtPath(target, path, value) {
+ if (!path) return;
+ const parts = path.split('.');
+ let node = target;
+ for (let i = 0; i < parts.length; i += 1) {
+ const key = parts[i];
+ if (i === parts.length - 1) {
+ node[key] = value;
+ } else {
+ node[key] = node[key] && typeof node[key] === 'object' ? node[key] : {};
+ node = node[key];
+ }
+ }
+}
+
+function getPathConfig(paramSetup, location) {
+ // The historical `redux-location-state` helper supports path-specific configs.
+ // Worldview currently only uses the `global` config, so prefer it.
+ if (paramSetup && typeof paramSetup === 'object') {
+ if (paramSetup.global && typeof paramSetup.global === 'object') return paramSetup.global;
+ }
+ return null;
+}
+
+function parseByType(type, rawValue) {
+ if (typeof rawValue !== 'string') return rawValue;
+ switch (type) {
+ case 'bool':
+ return rawValue === 'true';
+ case 'number': {
+ const num = Number(rawValue);
+ return Number.isNaN(num) ? undefined : num;
+ }
+ case 'array':
+ return rawValue ? rawValue.split(',').filter((v) => v !== '') : [];
+ case 'object':
+ try {
+ return rawValue ? JSON.parse(rawValue) : {};
+ } catch {
+ return {};
+ }
+ case 'date': {
+ const dt = new Date(rawValue);
+ return Number.isNaN(dt.valueOf()) ? undefined : dt;
+ }
+ default:
+ return rawValue;
+ }
+}
+
+function parseQuery(paramSetup, location) {
+ const pathConfig = getPathConfig(paramSetup, location);
+ if (!pathConfig) return {};
+
+ const params = parseSearch(location?.search);
+
+ const stateFromLocation = {};
+ Object.keys(params).forEach((paramName) => {
+ const definition = pathConfig[paramName];
+ if (!definition) return;
+
+ const { stateKey, options = {}, type } = definition;
+ if (!stateKey) return;
+
+ const rawValue = params[paramName];
+
+ let parsedValue;
+ if (typeof options.parse === 'function') {
+ parsedValue = options.parse(rawValue);
+ } else if (type) {
+ parsedValue = parseByType(type, rawValue);
+ } else {
+ parsedValue = rawValue;
+ }
+
+ // Preserve explicit empty items when requested; otherwise drop undefineds.
+ if (typeof parsedValue === 'undefined' && !options.setAsEmptyItem) return;
+
+ setAtPath(stateFromLocation, stateKey, parsedValue);
+ });
+
+ return stateFromLocation;
+}
+
+function locationsEqual(a, b) {
+ return !!a && !!b &&
+ a.pathname === b.pathname &&
+ a.search === b.search &&
+ a.hash === b.hash;
+}
+
+/**
+ * @param {object} paramSetup Config returned by `getParamObject`
+ * @param {function} mapLocationToState Maps URL-derived data to redux state on POP
+ * @param {import('history').BrowserHistory} history
+ * @param {function} reducers Root reducer
+ * @param {function} stateToParams Maps redux state back to a `location` object
+ */
+export function createReduxLocationActions(
+ paramSetup,
+ mapLocationToState,
+ history,
+ reducers,
+ stateToParams,
+) {
+ let lastLocation = history.location;
+
+ const locationMiddleware = (store) => (next) => (action) => {
+ const prevState = store.getState();
+ const result = next(action);
+ const nextState = store.getState();
+
+ const currentLocation = history.location;
+ const pathnameChanged = currentLocation.pathname !== lastLocation.pathname;
+
+ if (nextState !== prevState || pathnameChanged) {
+ lastLocation = currentLocation;
+
+ const mapped = stateToParams(paramSetup, nextState, currentLocation);
+ const desiredLocation = mapped?.location;
+ const shouldPush = !!mapped?.shouldPush;
+
+ if (desiredLocation && !locationsEqual(desiredLocation, currentLocation)) {
+ const { pathname, hash, state } = currentLocation;
+ const nextLocation = {
+ pathname: desiredLocation.pathname || pathname,
+ hash: desiredLocation.hash || hash,
+ state,
+ search: desiredLocation.search || '',
+ };
+
+ if (shouldPush && !pathnameChanged) {
+ history.push(nextLocation);
+ } else {
+ history.replace(nextLocation);
+ }
+ }
+ }
+
+ return result;
+ };
+
+ const reducersWithLocation = (state, action) => {
+ const reduced = reducers(state, action);
+ if (action?.type !== LOCATION_POP_ACTION || !action?.payload) return reduced;
+
+ const patchFromLocation = parseQuery(paramSetup, action.payload);
+ // Seed slices that `mapLocationToState` and its helpers assume exist.
+ // Avoid seeding slices that may contain non-plain objects (e.g. OL map instances).
+ const activeLayers = reduced?.layers?.active;
+ const activeBLayers = reduced?.layers?.activeB;
+ const activeWithoutOverlayGroups = omitOverlayGroups(activeLayers);
+ const activeBWithoutOverlayGroups = omitOverlayGroups(activeBLayers);
+ const baseQuery = {
+ date: reduced?.date,
+ proj: reduced?.proj,
+ // Do not seed `overlayGroups` here. `mapLocationToLayerState` computes them from
+ // the active layers list; seeding an existing (truthy) value can cause it to
+ // incorrectly clear groups when the URL has any query params.
+ layers: reduced?.layers
+ ? {
+ active: activeWithoutOverlayGroups,
+ activeB: activeBWithoutOverlayGroups,
+ }
+ : reduced?.layers,
+ locationSearch: reduced?.locationSearch,
+ compare: reduced?.compare,
+ charting: reduced?.charting,
+ palettes: reduced?.palettes,
+ animation: reduced?.animation,
+ sidebar: reduced?.sidebar,
+ tour: reduced?.tour,
+ embed: reduced?.embed,
+ events: reduced?.events,
+ ui: reduced?.ui,
+ smartHandoffs: reduced?.smartHandoffs,
+ };
+
+ const location = {
+ ...action.payload,
+ query: mergeDeep(baseQuery, patchFromLocation),
+ };
+
+ return mapLocationToState(reduced, location);
+ };
+
+ return { locationMiddleware, reducersWithLocation };
+}
+
+/**
+ * Listen for browser history changes and dispatch POP actions.
+ */
+export function listenForHistoryChange(store, history) {
+ // Initialize location state on startup
+ store.dispatch({ type: LOCATION_POP_ACTION, payload: history.location });
+
+ return history.listen(({ location, action }) => {
+ // Only treat real browser back/forward navigations as POP.
+ // push/replace are used by the app to sync redux state -> URL and
+ // should not trigger a URL->state remap.
+ if (action !== 'POP') return;
+ store.dispatch({ type: LOCATION_POP_ACTION, payload: location });
+ });
+}
diff --git a/web/js/util/react-mobile-datepicker.js b/web/js/util/react-mobile-datepicker.js
new file mode 100644
index 000000000..57df4be0c
--- /dev/null
+++ b/web/js/util/react-mobile-datepicker.js
@@ -0,0 +1,1235 @@
+/* eslint-disable */
+(function (global, factory) {
+ typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('react'), require('react-dom')) :
+ typeof define === 'function' && define.amd ? define(['react', 'react-dom'], factory) :
+ (global.reactMobileDatePicker = factory(global.React,global.ReactDOM));
+}(this, (function (React,ReactDOM) { 'use strict';
+
+function __$styleInject(css, ref) {
+ if ( ref === void 0 ) ref = {};
+ var insertAt = ref.insertAt;
+
+ if (!css || typeof document === 'undefined') { return; }
+
+ var head = document.head || document.getElementsByTagName('head')[0];
+ var style = document.createElement('style');
+ style.type = 'text/css';
+
+ if (insertAt === 'top') {
+ if (head.firstChild) {
+ head.insertBefore(style, head.firstChild);
+ } else {
+ head.appendChild(style);
+ }
+ } else {
+ head.appendChild(style);
+ }
+
+ if (style.styleSheet) {
+ style.styleSheet.cssText = css;
+ } else {
+ style.appendChild(document.createTextNode(css));
+ }
+}
+
+var React__default = 'default' in React ? React['default'] : React;
+ReactDOM = ReactDOM && ReactDOM.hasOwnProperty('default') ? ReactDOM['default'] : ReactDOM;
+
+__$styleInject(".datepicker-modal {\n position: absolute;\n right: 0;\n bottom: 0;\n width: 100%;\n height: 100%;\n background-color: rgba(0, 0, 0, .6);\n z-index: 999;\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n\n.datepicker {\n position: absolute;\n left: 0;\n bottom: 0;\n width: 100%;\n z-index: 1;\n font-size: 16px;\n text-align: center;\n font-family: arial,verdana,sans-serif;\n -webkit-box-sizing: content-box;\n box-sizing: content-box;\n -webkit-font-smoothing: antialiased;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n}\n\n.datepicker .datepicker-header {\n padding: 0 .5em;\n min-height: 2em;\n line-height: 2em;\n font-size: 1.125em;\n }\n\n.datepicker .datepicker-navbar {\n padding: 0 .5em .5em .5em;\n overflow: hidden;\n }\n\n.datepicker .datepicker-navbar-btn {\n height: 2.5em;\n line-height: 2.5em;\n float: right;\n padding: 0 1em;\n cursor: pointer;\n }\n\n.datepicker .datepicker-caption {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n padding: .5em .25em;\n }\n\n.datepicker .datepicker-caption-item {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n margin: 0 .25em;\n height: 40px;\n line-height: 40px;\n font-size: 1.2em;\n }\n\n.datepicker .datepicker-content {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n padding: .5em .25em;\n }\n\n.datepicker .datepicker-col-1 {\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n margin: 0 .25em;\n }\n\n.datepicker .datepicker-viewport {\n height: 200px;\n position: relative;\n overflow: hidden\n }\n\n.datepicker .datepicker-viewport::after {\n content: '';\n position: absolute;\n z-index: 2;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n pointer-events: none;\n}\n\n.datepicker .datepicker-wheel {\n position: absolute;\n height: 40px;\n top: 50%;\n margin-top: -20px;\n width: 100%;\n }\n\n.datepicker .datepicker-scroll {\n list-style-type: none;\n padding: 0\n }\n\n.datepicker .datepicker-scroll>li {\n height: 40px;\n line-height: 40px;\n font-size: 1.375em;\n cursor: pointer;\n}\n\n.datepicker {\n\n /* default */\n}\n\n.datepicker.default {\n background-color: #f7f7f7;\n}\n\n.datepicker.default .datepicker-header {\n color: #4eccc4;\n}\n\n.datepicker.default .datepicker-wheel {\n border-top: 1px solid #4eccc4;\n border-bottom: 1px solid #4eccc4;\n}\n\n.datepicker.default .datepicker-caption-item {\n color: rgb(59, 59, 59);\n}\n\n.datepicker.default .datepicker-scroll li {\n color: rgb(59, 59, 59);\n }\n\n.datepicker.default .datepicker-scroll li.disabled {\n color: rgb(191, 191, 191);\n }\n\n.datepicker.default .datepicker-navbar-btn {\n color: #4eccc4;\n}\n\n.datepicker {\n\n /* dark */\n}\n\n.datepicker.dark {\n background-color: #263238;\n}\n\n.datepicker.dark .datepicker-header {\n color: #50ccc4;\n}\n\n.datepicker.dark .datepicker-wheel {\n border-top: 1px solid #50ccc4;\n border-bottom: 1px solid #50ccc4;\n}\n\n.datepicker.dark .datepicker-caption-item {\n color: rgb(201, 203, 204);\n}\n\n.datepicker.dark .datepicker-scroll li {\n color: rgb(201, 203, 204);\n }\n\n.datepicker.dark .datepicker-scroll li.disabled {\n color: rgb(87, 96, 100);\n }\n\n.datepicker.dark .datepicker-navbar-btn {\n color: #50ccc4;\n}\n\n.datepicker {\n\n /* ios */\n}\n\n.datepicker.ios {\n background-color: #f7f7f7;\n}\n\n.datepicker.ios .datepicker-col-1 {margin: 0;\n}\n\n.datepicker.ios .datepicker-header {\n color: rgb(59, 59, 59);\n padding: 0 3.5em;\n}\n\n.datepicker.ios .datepicker-viewport::after {\n background: -webkit-gradient(linear,left top, left bottom,from(#f7f7f7),color-stop(52%, rgba(245, 245, 245, 0)),color-stop(48%, rgba(245, 245, 245, 0)),to(#f7f7f7));\n background: linear-gradient(#f7f7f7,rgba(245, 245, 245, 0)52%,rgba(245, 245, 245, 0)48%,#f7f7f7);\n}\n\n.datepicker.ios .datepicker-wheel {\n border-top: 1px solid #dbdbdb;\n border-bottom: 1px solid #dbdbdb;\n}\n\n.datepicker.ios .datepicker-caption-item {\n color: rgb(59, 59, 59);\n}\n\n.datepicker.ios .datepicker-scroll li {\n color: rgb(59, 59, 59);\n }\n\n.datepicker.ios .datepicker-scroll li.disabled {\n color: rgb(191, 191, 191);\n }\n\n.datepicker.ios .datepicker-navbar {\n position: absolute;\n z-index: 2;\n top: 0;\n left: 0;\n width: 100%;\n padding: 0;\n border-bottom: 1px solid #acacac;\n}\n\n.datepicker.ios .datepicker-navbar-btn {\n color: #007aff;\n}\n\n.datepicker.ios .datepicker-navbar-btn:nth-child(2) {\n float: left;\n}\n\n.datepicker.ios .datepicker-content {\n padding-top: 48px;\n}\n\n.datepicker.ios .datepicker-header + .datepicker-content {\n padding-top: 0;\n}\n\n.datepicker.ios .datepicker-caption + .datepicker-content {\n padding-top: 0;\n}\n\n.datepicker {\n\n /* android */\n}\n\n.datepicker.android, .datepicker.android-dark {\n background-color: #f5f5f5;\n}\n\n.datepicker.android .datepicker-header, .datepicker.android-dark .datepicker-header {\n color: #31b6e7;\n border-bottom: 2px solid #31b6e7;\n}\n\n.datepicker.android .datepicker-col-1, .datepicker.android-dark .datepicker-col-1 {margin: 0 .625em;\n}\n\n.datepicker.android .datepicker-viewport::after, .datepicker.android-dark .datepicker-viewport::after {\n background-image: -webkit-gradient(linear,left top, left bottom,from(#f5f5f5),color-stop(52%, rgba(245, 245, 245, 0)),color-stop(48%, rgba(245, 245, 245, 0)),to(#f5f5f5));\n background-image: linear-gradient(#f5f5f5,rgba(245, 245, 245, 0)52%,rgba(245, 245, 245, 0)48%,#f5f5f5);\n}\n\n.datepicker.android .datepicker-wheel, .datepicker.android-dark .datepicker-wheel {\n border-top: 2px solid #31b6e7;\n border-bottom: 2px solid #31b6e7;\n}\n\n.datepicker.android .datepicker-caption-item, .datepicker.android-dark .datepicker-caption-item {\n color: rgb(56, 56, 56);\n}\n\n.datepicker.android .datepicker-scroll li, .datepicker.android-dark .datepicker-scroll li {\n font-size: 1.125em;\n color: rgb(56, 56, 56);\n }\n\n.datepicker.android .datepicker-scroll li.disabled, .datepicker.android-dark .datepicker-scroll li.disabled {\n color: rgb(188, 188, 188);\n }\n\n.datepicker.android .datepicker-navbar, .datepicker.android-dark .datepicker-navbar {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n border-top: 1px solid #d9d4d4;\n padding: 0;\n}\n\n.datepicker.android .datepicker-navbar-btn, .datepicker.android-dark .datepicker-navbar-btn {\n padding: 0;\n color: #000;\n -webkit-box-flex: 1;\n -ms-flex: 1;\n flex: 1;\n}\n\n.datepicker.android .datepicker-navbar-btn:nth-child(2), .datepicker.android-dark .datepicker-navbar-btn:nth-child(2) {\n border-left: 1px solid #d9d4d4;\n}\n\n.datepicker {\n\n /* android-dark */\n}\n\n.datepicker.android-dark {\n background-color: #292829;\n}\n\n.datepicker.android-dark .datepicker-viewport::after {\n background-image: -webkit-gradient(linear,left top, left bottom,from(#282828),color-stop(52%, rgba(40, 40, 40, 0)),color-stop(48%, rgba(40, 40, 40, 0)),to(#282828));\n background-image: linear-gradient(#282828,rgba(40, 40, 40, 0)52%,rgba(40, 40, 40, 0)48%,#282828);\n}\n\n.datepicker.android-dark .datepicker-caption-item {\n color: rgb(199, 199, 199);\n}\n\n.datepicker.android-dark .datepicker-scroll li {\n color: rgb(199, 199, 199);\n }\n\n.datepicker.android-dark .datepicker-scroll li.disabled {\n color: rgb(88, 88, 88);\n }\n\n.datepicker.android-dark .datepicker-navbar { border-color: #424542;\n}\n\n.datepicker.android-dark .datepicker-navbar-btn {\n color: #fff;\n}\n\n.datepicker.android-dark .datepicker-navbar-btn:nth-child(2) {\n border-color: #424542;\n}\n", {});
+
+/**
+ * @module time utilities
+ */
+
+function throwIfInvalidDate(date) {
+ if (Object.prototype.toString.call(date, null) !== '[object Date]') {
+ throw new Error('Invalid argument type');
+ }
+}
+
+function daysInMonth(year, month) {
+ return new Date(year, month + 1, 0).getDate();
+}
+
+/**
+ * Date extension: convert a Date to a string with the given format
+ * @param {Date} date
+ * @return {String} formatted string
+ */
+function convertDate(date, format) {
+ var str = format;
+ var o = {
+ 'M+': date.getMonth() + 1,
+ 'D+': date.getDate(),
+ 'h+': date.getHours(),
+ 'm+': date.getMinutes(),
+ 's+': date.getSeconds()
+ };
+ if (/(Y+)/.test(format)) {
+ str = str.replace(RegExp.$1, date.getFullYear().toString().substr(4 - RegExp.$1.length));
+ }
+
+ for (var k in o) {
+ if (new RegExp('(' + k + ')').test(format)) {
+ str = str.replace(RegExp.$1, RegExp.$1.length === 1 ? o[k] : ('00' + o[k]).substr(o[k].toString().length));
+ }
+ }
+
+ return str;
+}
+
+/**
+ * Get a date offset relative to the input date
+ * @param {Date} date
+ * @return {number} offset days
+ */
+function nextYear(now) {
+ var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
+
+ throwIfInvalidDate(now);
+ var date = new Date(now.getFullYear() + index, now.getMonth(), now.getDate(), now.getHours(), now.getMinutes(), now.getSeconds());
+ return date;
+}
+
+function nextMonth(now) {
+ var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
+
+ throwIfInvalidDate(now);
+ var year = now.getFullYear();
+ var month = now.getMonth() + index;
+ var dayOfMonth = Math.min(now.getDate(), daysInMonth(year, month));
+ var date = new Date(year, month, dayOfMonth, now.getHours(), now.getMinutes(), now.getSeconds());
+ return date;
+}
+
+function nextDate(now) {
+ var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
+
+ throwIfInvalidDate(now);
+ var date = new Date(now.getTime() + index * 24 * 60 * 60 * 1000);
+ return date;
+}
+
+function nextHour(now) {
+ var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
+
+ throwIfInvalidDate(now);
+ var date = new Date(now.getTime() + index * 60 * 60 * 1000);
+ return date;
+}
+
+function nextMinute(now) {
+ var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
+
+ throwIfInvalidDate(now);
+ var date = new Date(now.getTime() + index * 60 * 1000);
+ return date;
+}
+
+function nextSecond(now) {
+ var index = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
+
+ throwIfInvalidDate(now);
+ var date = new Date(now.getTime() + index * 1000);
+ return date;
+}
+
+var TimeUtil = Object.freeze({
+ convertDate: convertDate,
+ nextYear: nextYear,
+ nextMonth: nextMonth,
+ nextDate: nextDate,
+ nextHour: nextHour,
+ nextMinute: nextMinute,
+ nextSecond: nextSecond
+});
+
+function shallowEqual(prev, next) {
+ if (prev === next) return true;
+ var prevKeys = Object.keys(prev);
+ var nextKeys = Object.keys(next);
+
+ if (prevKeys.length !== nextKeys.length) return false;
+
+ return prevKeys.every(function (key) {
+ return prev.hasOwnProperty(key) && prev[key] === next[key];
+ });
+}
+
+function PureRender(Component$$1) {
+ Component$$1.prototype.shouldComponentUpdate = function (nextProps, nextState) {
+ return PureRender.shouldComponentUpdate(nextProps, nextState, this.props, this.state);
+ };
+}
+
+PureRender.shouldComponentUpdate = function (nextProps, nextState, preProps, preState) {
+ return !shallowEqual(preProps, nextProps) || !shallowEqual(preState, nextState);
+};
+
+/**
+ * Convert to camelCase
+ * @param {String} str source string to convert
+ * @return {String} converted string
+ */
+function camelCase(str) {
+ return str.replace(/-([a-z])/g, function ($0, $1) {
+ return $1.toUpperCase();
+ }).replace('-', '');
+}
+
+/**
+ * Format a CSS properties object
+ * @param {Object} props properties object
+ * @return {Object} formatted properties object with vendor prefixes
+ */
+function formatCss(props) {
+ var prefixs = ['-webkit-', '-moz-', '-ms-'];
+
+ var result = {};
+
+ var regPrefix = /transform|transition/;
+
+ for (var key in props) {
+ if (props.hasOwnProperty(key)) {
+ var styleValue = props[key];
+
+ // If the key is transform or transition
+ if (regPrefix.test(key)) {
+ for (var i = 0; i < prefixs.length; i++) {
+ var styleName = camelCase(prefixs[i] + key);
+ result[styleName] = styleValue.replace(regPrefix, prefixs[i] + '$&');
+ }
+ }
+
+ result[key] = styleValue;
+ }
+ }
+
+ return result;
+}
+
+/**
+ * Add CSS styles to an element
+ * @param {Object} element target element
+ * @param {Object} props CSS properties object
+ */
+function addPrefixCss(element, props) {
+ var formatedProps = formatCss(props);
+ for (var key in formatedProps) {
+ if (formatedProps.hasOwnProperty(key)) {
+ element.style[key] = formatedProps[key];
+ }
+ }
+}
+
+var asyncGenerator = function () {
+ function AwaitValue(value) {
+ this.value = value;
+ }
+
+ function AsyncGenerator(gen) {
+ var front, back;
+
+ function send(key, arg) {
+ return new Promise(function (resolve, reject) {
+ var request = {
+ key: key,
+ arg: arg,
+ resolve: resolve,
+ reject: reject,
+ next: null
+ };
+
+ if (back) {
+ back = back.next = request;
+ } else {
+ front = back = request;
+ resume(key, arg);
+ }
+ });
+ }
+
+ function resume(key, arg) {
+ try {
+ var result = gen[key](arg);
+ var value = result.value;
+
+ if (value instanceof AwaitValue) {
+ Promise.resolve(value.value).then(function (arg) {
+ resume("next", arg);
+ }, function (arg) {
+ resume("throw", arg);
+ });
+ } else {
+ settle(result.done ? "return" : "normal", result.value);
+ }
+ } catch (err) {
+ settle("throw", err);
+ }
+ }
+
+ function settle(type, value) {
+ switch (type) {
+ case "return":
+ front.resolve({
+ value: value,
+ done: true
+ });
+ break;
+
+ case "throw":
+ front.reject(value);
+ break;
+
+ default:
+ front.resolve({
+ value: value,
+ done: false
+ });
+ break;
+ }
+
+ front = front.next;
+
+ if (front) {
+ resume(front.key, front.arg);
+ } else {
+ back = null;
+ }
+ }
+
+ this._invoke = send;
+
+ if (typeof gen.return !== "function") {
+ this.return = undefined;
+ }
+ }
+
+ if (typeof Symbol === "function" && Symbol.asyncIterator) {
+ AsyncGenerator.prototype[Symbol.asyncIterator] = function () {
+ return this;
+ };
+ }
+
+ AsyncGenerator.prototype.next = function (arg) {
+ return this._invoke("next", arg);
+ };
+
+ AsyncGenerator.prototype.throw = function (arg) {
+ return this._invoke("throw", arg);
+ };
+
+ AsyncGenerator.prototype.return = function (arg) {
+ return this._invoke("return", arg);
+ };
+
+ return {
+ wrap: function (fn) {
+ return function () {
+ return new AsyncGenerator(fn.apply(this, arguments));
+ };
+ },
+ await: function (value) {
+ return new AwaitValue(value);
+ }
+ };
+}();
+
+
+
+
+
+var classCallCheck = function (instance, Constructor) {
+ if (!(instance instanceof Constructor)) {
+ throw new TypeError("Cannot call a class as a function");
+ }
+};
+
+var createClass = function () {
+ function defineProperties(target, props) {
+ for (var i = 0; i < props.length; i++) {
+ var descriptor = props[i];
+ descriptor.enumerable = descriptor.enumerable || false;
+ descriptor.configurable = true;
+ if ("value" in descriptor) descriptor.writable = true;
+ Object.defineProperty(target, descriptor.key, descriptor);
+ }
+ }
+
+ return function (Constructor, protoProps, staticProps) {
+ if (protoProps) defineProperties(Constructor.prototype, protoProps);
+ if (staticProps) defineProperties(Constructor, staticProps);
+ return Constructor;
+ };
+}();
+
+
+
+
+
+
+
+var _extends = Object.assign || function (target) {
+ for (var i = 1; i < arguments.length; i++) {
+ var source = arguments[i];
+
+ for (var key in source) {
+ if (Object.prototype.hasOwnProperty.call(source, key)) {
+ target[key] = source[key];
+ }
+ }
+ }
+
+ return target;
+};
+
+
+
+var inherits = function (subClass, superClass) {
+ if (typeof superClass !== "function" && superClass !== null) {
+ throw new TypeError("Super expression must either be null or a function, not " + typeof superClass);
+ }
+
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
+ constructor: {
+ value: subClass,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ });
+ if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass;
+};
+
+
+
+
+
+
+
+
+
+var objectWithoutProperties = function (obj, keys) {
+ var target = {};
+
+ for (var i in obj) {
+ if (keys.indexOf(i) >= 0) continue;
+ if (!Object.prototype.hasOwnProperty.call(obj, i)) continue;
+ target[i] = obj[i];
+ }
+
+ return target;
+};
+
+var possibleConstructorReturn = function (self, call) {
+ if (!self) {
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
+ }
+
+ return call && (typeof call === "object" || typeof call === "function") ? call : self;
+};
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+var toArray = function (arr) {
+ return Array.isArray(arr) ? arr : Array.from(arr);
+};
+
+var toConsumableArray = function (arr) {
+ if (Array.isArray(arr)) {
+ for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) arr2[i] = arr[i];
+
+ return arr2;
+ } else {
+ return Array.from(arr);
+ }
+};
+
+/**
+ * @module Date component
+ */
+var DATE_HEIGHT = 40; // Height of each date row
+var DATE_LENGTH = 10; // Number of date rows
+var MIDDLE_INDEX = Math.floor(DATE_LENGTH / 2); // Middle index in the date list
+var MIDDLE_Y = -DATE_HEIGHT * MIDDLE_INDEX; // translateY baseline
+
+var isUndefined = function isUndefined(val) {
+ return typeof val === 'undefined';
+};
+var isFunction = function isFunction(val) {
+ return Object.prototype.toString.apply(val) === '[object Function]';
+};
+
+/**
+ * Date component class
+ * @extends Component
+ */
+var DatePickerItem = function (_Component) {
+ inherits(DatePickerItem, _Component);
+
+ function DatePickerItem(props) {
+ classCallCheck(this, DatePickerItem);
+
+ var _this = possibleConstructorReturn(this, (DatePickerItem.__proto__ || Object.getPrototypeOf(DatePickerItem)).call(this, props));
+
+ _this.animating = false; // Whether a transition animation is active
+ _this.touchY = 0; // touchstart pageY value
+ _this.translateY = 0; // Current container offset
+ _this.currentIndex = MIDDLE_INDEX; // Current date index while scrolling
+ _this.moveDateCount = 0; // Number of date steps moved per scroll
+
+ _this.state = {
+ translateY: MIDDLE_Y,
+ marginTop: (_this.currentIndex - MIDDLE_INDEX) * DATE_HEIGHT
+ };
+
+ _this.renderDatepickerItem = _this.renderDatepickerItem.bind(_this);
+ _this.handleContentTouch = _this.handleContentTouch.bind(_this);
+ _this.handleContentMouseDown = _this.handleContentMouseDown.bind(_this);
+ _this.handleContentMouseMove = _this.handleContentMouseMove.bind(_this);
+ _this.handleContentMouseUp = _this.handleContentMouseUp.bind(_this);
+ return _this;
+ }
+
+ createClass(DatePickerItem, [{
+ key: 'UNSAFE_componentWillMount',
+ value: function UNSAFE_componentWillMount() {
+ this._iniDates(this.props.value);
+ }
+ }, {
+ key: 'componentDidMount',
+ value: function componentDidMount() {
+ var viewport = this.viewport;
+ viewport.addEventListener('touchstart', this.handleContentTouch, false);
+ viewport.addEventListener('touchmove', this.handleContentTouch, false);
+ viewport.addEventListener('touchend', this.handleContentTouch, false);
+ viewport.addEventListener('mousedown', this.handleContentMouseDown, false);
+ }
+ }, {
+ key: 'UNSAFE_componentWillReceiveProps',
+ value: function UNSAFE_componentWillReceiveProps(nextProps) {
+ if (nextProps.value.getTime() === this.props.value.getTime()) {
+ return;
+ }
+ this._iniDates(nextProps.value);
+ this.currentIndex = MIDDLE_INDEX;
+ this.setState({
+ translateY: MIDDLE_Y,
+ marginTop: (this.currentIndex - MIDDLE_INDEX) * DATE_HEIGHT
+ });
+ }
+
+ /**
+ * Optimization component, Prevents unnecessary rendering
+ * Only value or state change should re-rendering
+ *
+ * @param {Object} nextProps next props
+ * @param {Object} nextState next state
+ * @return {Boolean} Whether re-rendering
+ */
+
+ }, {
+ key: 'shouldComponentUpdate',
+ value: function shouldComponentUpdate(nextProps, nextState) {
+ return nextProps.value.getTime() !== this.props.value.getTime() || !shallowEqual(nextState, this.state);
+ }
+ }, {
+ key: 'componentWillUnmount',
+ value: function componentWillUnmount() {
+ var viewport = this.viewport;
+ viewport.removeEventListener('touchstart', this.handleContentTouch, false);
+ viewport.removeEventListener('touchmove', this.handleContentTouch, false);
+ viewport.removeEventListener('touchend', this.handleContentTouch, false);
+ viewport.removeEventListener('mousedown', this.handleContentMouseDown, false);
+ }
+ }, {
+ key: '_iniDates',
+ value: function _iniDates(date) {
+ var _this2 = this;
+
+ var typeName = this.props.type;
+ var dates = Array.apply(undefined, toConsumableArray(Array(DATE_LENGTH))).map(function (value, index) {
+ return TimeUtil['next' + typeName](date, (index - MIDDLE_INDEX) * _this2.props.step);
+ });
+ this.setState({ dates: dates });
+ }
+ }, {
+ key: '_updateDates',
+ value: function _updateDates(direction) {
+ var typeName = this.props.type;
+ var dates = this.state.dates;
+
+ if (direction === 1) {
+ this.currentIndex++;
+ this.setState({
+ dates: [].concat(toConsumableArray(dates.slice(1)), [TimeUtil['next' + typeName](dates[dates.length - 1], this.props.step)]),
+ marginTop: (this.currentIndex - MIDDLE_INDEX) * DATE_HEIGHT
+ });
+ } else {
+ this.currentIndex--;
+ this.setState({
+ dates: [TimeUtil['next' + typeName](dates[0], -this.props.step)].concat(toConsumableArray(dates.slice(0, dates.length - 1))),
+ marginTop: (this.currentIndex - MIDDLE_INDEX) * DATE_HEIGHT
+ });
+ }
+ }
+ }, {
+ key: '_checkIsUpdateDates',
+ value: function _checkIsUpdateDates(direction, translateY) {
+ return direction === 1 ? this.currentIndex * DATE_HEIGHT + DATE_HEIGHT / 2 < -translateY : this.currentIndex * DATE_HEIGHT - DATE_HEIGHT / 2 > -translateY;
+ }
+
+ /**
+ * Clear an element's transition style
+ * @param {Dom} obj target element
+ * @return {undefined}
+ */
+
+ }, {
+ key: '_clearTransition',
+ value: function _clearTransition(obj) {
+ addPrefixCss(obj, { transition: '' });
+ }
+
+ /**
+ * Move to the next date
+ * @param {number} direction scroll direction
+ * @return {undefined}
+ */
+
+ }, {
+ key: '_moveToNext',
+ value: function _moveToNext(direction) {
+ var date = this.state.dates[MIDDLE_INDEX];
+ var _props = this.props,
+ max = _props.max,
+ min = _props.min;
+
+ if (direction === -1 && date.getTime() < min.getTime() && this.moveDateCount) {
+ this._updateDates(1);
+ } else if (direction === 1 && date.getTime() > max.getTime() && this.moveDateCount) {
+ this._updateDates(-1);
+ }
+
+ this._moveTo(this.scrollEl, this.currentIndex);
+ }
+
+ /**
+ * Apply scroll animation
+ * @param {DOM} obj DOM element
+ * @param {number} angle angle
+ * @return {undefined}
+ */
+
+ }, {
+ key: '_moveTo',
+ value: function _moveTo(obj, currentIndex) {
+ var _this3 = this;
+
+ this.animating = true;
+
+ addPrefixCss(obj, { transition: 'transform .2s ease-out' });
+
+ this.setState({
+ translateY: -currentIndex * DATE_HEIGHT
+ });
+
+ // NOTE: There is no transitionend, setTimeout is used instead.
+ setTimeout(function () {
+ _this3.animating = false;
+ _this3.props.onSelect(_this3.state.dates[MIDDLE_INDEX]);
+ _this3._clearTransition(_this3.scrollEl);
+ }, 200);
+ }
+ }, {
+ key: 'handleStart',
+ value: function handleStart(event) {
+ this.touchY = !isUndefined(event.targetTouches) && !isUndefined(event.targetTouches[0]) ? event.targetTouches[0].pageY : event.pageY;
+
+ this.translateY = this.state.translateY;
+ this.moveDateCount = 0;
+ }
+ }, {
+ key: 'handleMove',
+ value: function handleMove(event) {
+ var touchY = !isUndefined(event.targetTouches) && !isUndefined(event.targetTouches[0]) ? event.targetTouches[0].pageY : event.pageY;
+
+ var dir = touchY - this.touchY;
+ var translateY = this.translateY + dir;
+ var direction = dir > 0 ? -1 : 1;
+
+ // Enforce minimum and maximum date limits
+ var date = this.state.dates[MIDDLE_INDEX];
+ var _props2 = this.props,
+ max = _props2.max,
+ min = _props2.min;
+
+ if (date.getTime() < min.getTime() || date.getTime() > max.getTime()) {
+ return;
+ }
+
+ // Check whether the date list should be updated
+ if (this._checkIsUpdateDates(direction, translateY)) {
+ this.moveDateCount = direction > 0 ? this.moveDateCount + 1 : this.moveDateCount - 1;
+ this._updateDates(direction);
+ }
+
+ this.setState({ translateY: translateY });
+ }
+ }, {
+ key: 'handleEnd',
+ value: function handleEnd(event) {
+ var touchY = event.pageY || event.changedTouches[0].pageY;
+ var dir = touchY - this.touchY;
+ var direction = dir > 0 ? -1 : 1;
+ this._moveToNext(direction);
+ }
+
+ /**
+ * Datepicker touch events
+ * @param {Object} event event object
+ * @return {undefined}
+ */
+
+ }, {
+ key: 'handleContentTouch',
+ value: function handleContentTouch(event) {
+ event.preventDefault();
+ if (this.animating) return;
+ if (event.type === 'touchstart') {
+ this.handleStart(event);
+ } else if (event.type === 'touchmove') {
+ this.handleMove(event);
+ } else if (event.type === 'touchend') {
+ this.handleEnd(event);
+ }
+ }
+
+ /**
+ * Datepicker mouse events
+ * @param {Object} event event object
+ * @return {undefined}
+ */
+
+ }, {
+ key: 'handleContentMouseDown',
+ value: function handleContentMouseDown(event) {
+ if (this.animating) return;
+ this.handleStart(event);
+ document.addEventListener('mousemove', this.handleContentMouseMove);
+ document.addEventListener('mouseup', this.handleContentMouseUp);
+ }
+ }, {
+ key: 'handleContentMouseMove',
+ value: function handleContentMouseMove(event) {
+ if (this.animating) return;
+ this.handleMove(event);
+ }
+ }, {
+ key: 'handleContentMouseUp',
+ value: function handleContentMouseUp(event) {
+ if (this.animating) return;
+ this.handleEnd(event);
+ document.removeEventListener('mousemove', this.handleContentMouseMove);
+ document.removeEventListener('mouseup', this.handleContentMouseUp);
+ }
+
+ /**
+ * Render a date DOM element
+ * @param {Object} date date data
+ * @return {Object} JSX element
+ */
+
+ }, {
+ key: 'renderDatepickerItem',
+ value: function renderDatepickerItem(date, index) {
+ var className = date < this.props.min || date > this.props.max ? 'disabled' : '';
+
+ var formatDate = void 0;
+ if (isFunction(this.props.format)) {
+ formatDate = this.props.format(date);
+ } else {
+ formatDate = convertDate(date, this.props.format);
+ }
+
+ return React__default.createElement(
+ 'li',
+ {
+ key: index,
+ className: className },
+ formatDate
+ );
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ var _this4 = this;
+
+ var scrollStyle = formatCss({
+ transform: 'translateY(' + this.state.translateY + 'px)',
+ marginTop: this.state.marginTop
+ });
+
+ return React__default.createElement(
+ 'div',
+ { className: 'datepicker-col-1' },
+ React__default.createElement(
+ 'div',
+ {
+ ref: function ref(viewport) {
+ return _this4.viewport = viewport;
+ }
+ , className: 'datepicker-viewport' },
+ React__default.createElement(
+ 'div',
+ { className: 'datepicker-wheel' },
+ React__default.createElement(
+ 'ul',
+ {
+ ref: function ref(scrollEl) {
+ _this4.scrollEl = scrollEl;
+ },
+ className: 'datepicker-scroll',
+ style: scrollStyle },
+ this.state.dates.map(this.renderDatepickerItem)
+ )
+ )
+ )
+ );
+ }
+ }]);
+ return DatePickerItem;
+}(React.Component);
+
+/**
+ * Default props
+ */
+var defaultProps = {
+ isPopup: true,
+ isOpen: false,
+ theme: 'default',
+ value: new Date(),
+ min: new Date(1970, 0, 1),
+ max: new Date(2050, 0, 1),
+ showFooter: true,
+ showHeader: true,
+ showCaption: false,
+ dateConfig: {
+ 'year': {
+ format: 'YYYY',
+ caption: 'Year',
+ step: 1
+ },
+ 'month': {
+ format: 'M',
+ caption: 'Mon',
+ step: 1
+ },
+ 'date': {
+ format: 'D',
+ caption: 'Day',
+ step: 1
+ }
+ },
+ headerFormat: 'YYYY/MM/DD',
+ confirmText: 'Done',
+ cancelText: 'Cancel',
+ onChange: function onChange() {},
+ onSelect: function onSelect() {},
+ onCancel: function onCancel() {}
+};
+
+/**
+ * Date configuration
+ */
+var dateConfigMap = {
+ 'year': {
+ format: 'YYYY',
+ caption: 'Year',
+ step: 1
+ },
+ 'month': {
+ format: 'M',
+ caption: 'Mon',
+ step: 1
+ },
+ 'date': {
+ format: 'D',
+ caption: 'Day',
+ step: 1
+ },
+ 'hour': {
+ format: 'hh',
+ caption: 'Hour',
+ step: 1
+ },
+ 'minute': {
+ format: 'mm',
+ caption: 'Min',
+ step: 1
+ },
+ 'second': {
+ format: 'hh',
+ caption: 'Sec',
+ step: 1
+ }
+};
+
+/**
+ * @module DatePicker Component
+ */
+
+/**
+ * Capitalize first letter
+ * @param {String} string
+ */
+var capitalize = function capitalize(_ref) {
+ var _ref2 = toArray(_ref),
+ first = _ref2[0],
+ rest = _ref2.slice(1);
+
+ return first.toUpperCase() + rest.join('');
+};
+
+/**
+ * Check for array
+ * @param {any} val
+ */
+var isArray = function isArray(val) {
+ return Object.prototype.toString.apply(val) === '[object Array]';
+};
+
+/**
+ * Class DatePicker Component Class
+ * @extends Component
+ */
+
+var DatePicker = function (_Component) {
+ inherits(DatePicker, _Component);
+
+ function DatePicker(props) {
+ classCallCheck(this, DatePicker);
+
+ var _this = possibleConstructorReturn(this, (DatePicker.__proto__ || Object.getPrototypeOf(DatePicker)).call(this, props));
+
+ _this.state = {
+ value: nextDate(_this.props.value)
+ };
+
+ if ('dateFormat' in props) {
+ console.warn('dateFormat is deprecated, use dateConfig instead.');
+ }
+
+ if ('dateSteps' in props) {
+ console.warn('dateSteps is deprecated, use dateConfig instead.');
+ }
+
+ if ('showFormat' in props) {
+ console.warn('headerFormat is deprecated, use dateConfig instead.');
+ }
+
+ _this.handleFinishBtnClick = _this.handleFinishBtnClick.bind(_this);
+ _this.handleDateSelect = _this.handleDateSelect.bind(_this);
+ return _this;
+ }
+
+ createClass(DatePicker, [{
+ key: 'UNSAFE_componentWillReceiveProps',
+ value: function UNSAFE_componentWillReceiveProps(nextProps) {
+ // update value of state
+ var date = nextDate(nextProps.value);
+ if (date.getTime() !== this.state.value.getTime()) {
+ this.setState({ value: date });
+ }
+ }
+
+ /**
+ * When you swipe two datepickeritems at the same time.
+ * Prevent dates from going out.
+ */
+
+ }, {
+ key: 'componentDidUpdate',
+ value: function componentDidUpdate() {
+ var value = this.state.value;
+ var _props = this.props,
+ min = _props.min,
+ max = _props.max;
+
+ if (value.getTime() > max.getTime()) {
+ this.setState({ value: max });
+ }
+
+ if (value.getTime() < min.getTime()) {
+ this.setState({ value: min });
+ }
+ }
+
+ /**
+ * Optimization component, Prevents unnecessary rendering
+ * Only props or state change or value before re-rendering
+ *
+ * @param {Object} nextProps next props
+ * @param {Object} nextState next state
+ * @return {Boolean} Whether re-rendering
+ */
+
+ }, {
+ key: 'shouldComponentUpdate',
+ value: function shouldComponentUpdate(nextProps, nextState) {
+ var date = nextDate(nextState.value);
+ return date.getTime() !== this.state.value.getTime() || PureRender.shouldComponentUpdate(nextProps, nextState, this.props, this.state);
+ }
+
+ /**
+ * Finish button click handler
+ * @return {undefined}
+ */
+
+ }, {
+ key: 'handleFinishBtnClick',
+ value: function handleFinishBtnClick() {
+ this.props.onSelect(this.state.value);
+ }
+
+ /**
+ * Select next date
+ * @return {undefined}
+ */
+
+ }, {
+ key: 'handleDateSelect',
+ value: function handleDateSelect(value) {
+ var _this2 = this;
+
+ this.setState({ value: value }, function () {
+ _this2.props.onChange(value);
+ });
+ }
+
+ /**
+ * Normalize dateConfig
+ * @param {*} dataConfig dateConfig prop
+ */
+
+ }, {
+ key: 'normalizeDateConfig',
+ value: function normalizeDateConfig(dataConfig) {
+ var configList = [];
+ if (isArray(dataConfig)) {
+ for (var i = 0; i < dataConfig.length; i++) {
+ var _value = dataConfig[i];
+ if (typeof _value === 'string') {
+ var lowerCaseKey = _value.toLocaleLowerCase();
+ configList.push(_extends({}, dateConfigMap[lowerCaseKey], {
+ type: capitalize(lowerCaseKey)
+ }));
+ }
+ }
+ } else {
+ for (var key in dataConfig) {
+ if (dataConfig.hasOwnProperty(key)) {
+ var _lowerCaseKey = key.toLocaleLowerCase();
+ if (dateConfigMap.hasOwnProperty(_lowerCaseKey)) {
+ configList.push(_extends({}, dateConfigMap[_lowerCaseKey], dataConfig[key], {
+ type: capitalize(_lowerCaseKey)
+ }));
+ }
+ }
+ }
+ }
+
+ return configList;
+ }
+
+ /**
+ * render function
+ * @return {Object} JSX element
+ */
+
+ }, {
+ key: 'render',
+ value: function render() {
+ var _this3 = this;
+
+ var _props2 = this.props,
+ min = _props2.min,
+ max = _props2.max,
+ theme = _props2.theme,
+ dateConfig = _props2.dateConfig,
+ confirmText = _props2.confirmText,
+ cancelText = _props2.cancelText,
+ headerFormat = _props2.headerFormat,
+ showHeader = _props2.showHeader,
+ showFooter = _props2.showFooter,
+ customHeader = _props2.customHeader,
+ showCaption = _props2.showCaption;
+
+ var value = this.state.value;
+ var themeClassName = ['default', 'dark', 'ios', 'android', 'android-dark'].indexOf(theme) === -1 ? 'default' : theme;
+
+ var dataConfigList = this.normalizeDateConfig(dateConfig);
+
+ return React__default.createElement(
+ 'div',
+ {
+ className: 'datepicker ' + themeClassName },
+ showHeader && React__default.createElement(
+ 'div',
+ { className: 'datepicker-header' },
+ customHeader || convertDate(value, headerFormat)
+ ),
+ showCaption && React__default.createElement(
+ 'div',
+ { className: 'datepicker-caption' },
+ dataConfigList.map(function (item, index) {
+ return React__default.createElement(
+ 'div',
+ { key: index, className: 'datepicker-caption-item' },
+ item.caption
+ );
+ })
+ ),
+ React__default.createElement(
+ 'div',
+ { className: 'datepicker-content' },
+ dataConfigList.map(function (item, index) {
+ return React__default.createElement(DatePickerItem, {
+ key: index,
+ value: value,
+ min: min,
+ max: max,
+ step: item.step,
+ type: item.type,
+ format: item.format,
+ onSelect: _this3.handleDateSelect });
+ })
+ ),
+ showFooter && React__default.createElement(
+ 'div',
+ { className: 'datepicker-navbar' },
+ React__default.createElement(
+ 'a',
+ {
+ className: 'datepicker-navbar-btn',
+ onClick: this.handleFinishBtnClick },
+ confirmText
+ ),
+ React__default.createElement(
+ 'a',
+ {
+ className: 'datepicker-navbar-btn',
+ onClick: this.props.onCancel },
+ cancelText
+ )
+ )
+ );
+ }
+ }]);
+ return DatePicker;
+}(React.Component);
+
+var renderSubtreeIntoContainer = ReactDOM.unstable_renderSubtreeIntoContainer;
+
+var Modal = function (_Component) {
+ inherits(Modal, _Component);
+
+ function Modal() {
+ classCallCheck(this, Modal);
+ return possibleConstructorReturn(this, (Modal.__proto__ || Object.getPrototypeOf(Modal)).apply(this, arguments));
+ }
+
+ createClass(Modal, [{
+ key: 'componentDidMount',
+ value: function componentDidMount() {
+ this._div = document.createElement('div');
+ this._div.classList.add('Modal-Portal');
+ document.body.appendChild(this._div);
+ this.renderPortal(this.props);
+ }
+ }, {
+ key: 'UNSAFE_componentWillReceiveProps',
+ value: function UNSAFE_componentWillReceiveProps(newProps) {
+ this.renderPortal(newProps);
+ }
+ }, {
+ key: 'componentWillUnmount',
+ value: function componentWillUnmount() {
+ ReactDOM.unmountComponentAtNode(this._div);
+ this._div.parentNode.removeChild(this._div);
+ }
+ }, {
+ key: 'renderPortal',
+ value: function renderPortal(props) {
+ var portal = React__default.cloneElement(this.props.children, _extends({}, props, { key: 'portal' }), null);
+
+ this.portal = renderSubtreeIntoContainer(this, portal, this._div);
+ }
+ }, {
+ key: 'render',
+ value: function render() {
+ return React__default.createElement('noscript', null);
+ }
+ }]);
+ return Modal;
+}(React.Component);
+
+Modal.defaultProps = {
+ isOpen: false
+};
+
+function EnhanceDatePicker(_ref) {
+ var isOpen = _ref.isOpen,
+ props = objectWithoutProperties(_ref, ['isOpen']);
+
+ function onModalClose(event) {
+ if (event.target === event.currentTarget) {
+ props.onCancel();
+ }
+ }
+
+ return React__default.createElement(
+ 'div',
+ {
+ style: { display: isOpen ? '' : 'none' },
+ onClick: onModalClose,
+ className: 'datepicker-modal' },
+ React__default.createElement(DatePicker, props)
+ );
+}
+
+function ModalDatePicker(_ref2) {
+ var isPopup = _ref2.isPopup,
+ props = objectWithoutProperties(_ref2, ['isPopup']);
+
+ if (!isPopup) {
+ return React__default.createElement(DatePicker, props);
+ }
+
+ return React__default.createElement(
+ Modal,
+ props,
+ React__default.createElement(EnhanceDatePicker, null)
+ );
+}
+
+ModalDatePicker.displayName = 'MobileDatePicker';
+ModalDatePicker.defaultProps = defaultProps;
+
+return ModalDatePicker;
+
+})));
diff --git a/web/js/util/reactAutocomplete.js b/web/js/util/reactAutocomplete.js
index 3b51d9f43..6daf16049 100644
--- a/web/js/util/reactAutocomplete.js
+++ b/web/js/util/reactAutocomplete.js
@@ -1,7 +1,6 @@
/* eslint-disable */
import React from 'react';
import PropTypes from 'prop-types';
-import { findDOMNode } from 'react-dom';
import scrollIntoView from 'dom-scroll-into-view';
const IMPERATIVE_API = [
@@ -196,6 +195,15 @@ class Autocomplete extends React.Component {
isOpen: false,
highlightedIndex: null,
};
+
+ // Internal refs/state used by the legacy implementation.
+ // React 19 no longer supports `componentWillMount`/`componentWillReceiveProps`.
+ this.refs = {};
+ this._ignoreBlur = false;
+ this._ignoreFocus = false;
+ this._scrollOffset = null;
+ this._scrollTimer = null;
+
this._debugStates = [];
this.ensureHighlightedIndex = this.ensureHighlightedIndex.bind(this);
this.exposeAPI = this.exposeAPI.bind(this);
@@ -207,29 +215,11 @@ class Autocomplete extends React.Component {
this.maybeAutoCompleteText = this.maybeAutoCompleteText.bind(this);
};
- componentWillMount() {
- // this.refs is frozen, so we need to assign a new object to it
- this.refs = {};
- this._ignoreBlur = false;
- this._ignoreFocus = false;
- this._scrollOffset = null;
- this._scrollTimer = null;
- }
-
componentWillUnmount() {
clearTimeout(this._scrollTimer);
this._scrollTimer = null;
}
- componentWillReceiveProps(nextProps) {
- if (this.state.highlightedIndex !== null) {
- this.setState(this.ensureHighlightedIndex)
- }
- if (nextProps.autoHighlight && (this.props.value !== nextProps.value || this.state.highlightedIndex === null)) {
- this.setState(this.maybeAutoCompleteText)
- }
- }
-
componentDidMount() {
if (this.isOpen()) {
this.setMenuPositions();
@@ -244,6 +234,33 @@ class Autocomplete extends React.Component {
if (prevState.isOpen !== this.state.isOpen) {
this.props.onMenuVisibilityChange(this.state.isOpen);
}
+
+ const filteredItemsAffectingPropsChanged = (
+ prevProps.items !== this.props.items
+ || prevProps.shouldItemRender !== this.props.shouldItemRender
+ || prevProps.sortItems !== this.props.sortItems
+ || prevProps.value !== this.props.value
+ );
+
+ if (filteredItemsAffectingPropsChanged && this.state.highlightedIndex !== null) {
+ const ensured = this.ensureHighlightedIndex(this.state, this.props);
+ if (ensured && ensured.highlightedIndex !== this.state.highlightedIndex) {
+ this.setState(ensured);
+ return;
+ }
+ }
+
+ const autoHighlightShouldRecompute = (
+ this.props.autoHighlight
+ && (prevProps.value !== this.props.value || this.state.highlightedIndex === null)
+ );
+
+ if (autoHighlightShouldRecompute && (prevProps.value !== this.props.value || prevProps.autoHighlight !== this.props.autoHighlight)) {
+ const suggested = this.maybeAutoCompleteText(this.state, this.props);
+ if (suggested && suggested.highlightedIndex !== this.state.highlightedIndex) {
+ this.setState(suggested);
+ }
+ }
}
exposeAPI(el) {
@@ -255,11 +272,8 @@ class Autocomplete extends React.Component {
if (this.isOpen() && this.state.highlightedIndex !== null) {
const itemNode = this.refs[`item-${this.state.highlightedIndex}`];
const menuNode = this.refs.menu;
- scrollIntoView(
- findDOMNode(itemNode),
- findDOMNode(menuNode),
- { onlyScrollIfNeeded: true }
- )
+ if (!itemNode || !menuNode) return;
+ scrollIntoView(itemNode, menuNode, { onlyScrollIfNeeded: true })
}
}
diff --git a/web/scss/features/timeline.scss b/web/scss/features/timeline.scss
index d43d524e3..b80d88f85 100644
--- a/web/scss/features/timeline.scss
+++ b/web/scss/features/timeline.scss
@@ -810,6 +810,94 @@ button:focus {
position: static;
}
+.datepicker-modal .datepicker {
+ position: absolute;
+ left: 0;
+ bottom: 0;
+ width: 100%;
+ z-index: 1;
+ text-align: center;
+ user-select: none;
+ box-sizing: content-box;
+ -webkit-font-smoothing: antialiased;
+}
+
+.datepicker-modal .datepicker-header {
+ padding: 0 0.5em;
+ min-height: 2em;
+ line-height: 2em;
+ font-size: 18px;
+ font-weight: 700;
+}
+
+.datepicker-modal .datepicker-caption {
+ display: flex;
+ padding: 0.5em 0.25em;
+}
+
+.datepicker-modal .datepicker-caption-item {
+ flex: 1;
+ margin: 0 0.25em;
+ height: 40px;
+ line-height: 40px;
+ font-size: 1.2em;
+}
+
+.datepicker-modal .datepicker-content {
+ display: flex;
+ padding: 0.5em 0.25em;
+}
+
+.datepicker-modal .datepicker-col-1 {
+ flex: 1;
+ margin: 0 0.25em;
+}
+
+.datepicker-modal .datepicker-viewport {
+ display: block;
+ height: 200px;
+ position: relative;
+ overflow: hidden;
+ width: 100%;
+}
+
+.datepicker-modal .datepicker-wheel {
+ position: absolute;
+ height: 40px;
+ top: 50%;
+ margin-top: -20px;
+ width: 100%;
+}
+
+.datepicker-modal .datepicker-scroll {
+ list-style-type: none;
+ padding: 0;
+ margin: 0;
+ width: 100%;
+}
+
+.datepicker-modal .datepicker-scroll > li {
+ height: 40px;
+ line-height: 40px;
+ font-size: 1.375em;
+ cursor: pointer;
+}
+
+.datepicker-modal .datepicker-navbar {
+ padding: 0 0.5em 0.5em;
+ overflow: hidden;
+}
+
+.datepicker-modal .datepicker-navbar-btn {
+ font-size: 18px;
+ font-weight: 700;
+ height: 55px;
+ line-height: 55px;
+ float: right;
+ padding: 0 1em;
+ cursor: pointer;
+}
+
.mobile-date-picker-select-btn {
user-select: none;
position: absolute;
@@ -833,21 +921,11 @@ button:focus {
.datepicker-modal {
& div,
- li {
+ & li {
font-family: variables.$wv-monospace-font;
}
- & .datepicker-header,
- .datepicker-navbar-btn {
- font-weight: 700;
- font-size: 18px;
- }
-
- .datepicker-navbar-btn {
- height: 55px;
- }
-
- .datepicker .datepicker-navbar-btn:hover {
+ & .datepicker .datepicker-navbar-btn:hover {
background: #ccc;
color: #333;
}
diff --git a/webpack.config.js b/webpack.config.js
index f7b9890a3..b1be38aa4 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -48,15 +48,9 @@ const babelLoaderExcludes = [
/core-js/
]
// Include any modules that need to be transpiled by babel-loader
-const transpileDependencies = [
- 'react-visibility-sensor'
-]
if (devMode) {
- // Don't transpile any dependencies in /node_modules except those found
- // in transpileDependencies array
- babelLoaderExcludes.push(
- new RegExp(`node_modules(?!(/|\\\\)(${transpileDependencies.join('|')})).*`)
- )
+ // Don't transpile dependencies in /node_modules by default.
+ babelLoaderExcludes.push(/node_modules/)
}
module.exports = {