diff --git a/.npmignore b/.npmignore index 73848995..8552c973 100644 --- a/.npmignore +++ b/.npmignore @@ -5,6 +5,7 @@ **/tsconfig.webpack.json **/node_modules downstream_projects +integration logo src scripts diff --git a/downstream_projects.json b/downstream_projects.json index 78c1b442..d21a7b74 100644 --- a/downstream_projects.json +++ b/downstream_projects.json @@ -1,3 +1,8 @@ { - "sample-app-react": "https://github.com/ui-router/sample-app-react.git" + "sample-app-react": "https://github.com/ui-router/sample-app-react.git", + "react-versions": { + "react17": "./integration/react17", + "react18": "./integration/react18", + "react19": "./integration/react19" + } } diff --git a/integration/react17/__tests__/sanity.test.tsx b/integration/react17/__tests__/sanity.test.tsx new file mode 100644 index 00000000..f2caed6f --- /dev/null +++ b/integration/react17/__tests__/sanity.test.tsx @@ -0,0 +1,70 @@ +/** + * Sanity test for @uirouter/react with React 17 + * This test verifies basic functionality works with React 17 + */ +import { describe, it, expect } from 'vitest'; +import * as React from 'react'; +import { render, screen, waitFor } from '@testing-library/react'; +import { UIRouter, UIView, UISref, pushStateLocationPlugin } from '@uirouter/react'; +import { memoryLocationPlugin } from '@uirouter/core'; + +const Home = () =>
Home Page
; +const About = () =>
About Page
; + +const states = [ + { name: 'home', url: '/home', component: Home }, + { name: 'about', url: '/about', component: About }, +]; + +describe('@uirouter/react with React 17', () => { + it('renders UIRouter and UIView', async () => { + render( + + + + ); + + // Should render without crashing + expect(document.body).toBeDefined(); + }); + + it('navigates to a state and renders the component', async () => { + const { container } = render( + +
+ + +
+
+ ); + + // Click home link + screen.getByTestId('home-link').click(); + + await waitFor(() => { + expect(screen.getByTestId('home')).toBeDefined(); + }); + }); + + it('UISref generates correct href', async () => { + render( + + + About + + + ); + + await waitFor(() => { + const link = screen.getByTestId('link'); + expect(link.getAttribute('href')).toContain('/about'); + }); + }); +}); diff --git a/integration/react17/e2e/sanity.spec.ts b/integration/react17/e2e/sanity.spec.ts new file mode 100644 index 00000000..f82e48f7 --- /dev/null +++ b/integration/react17/e2e/sanity.spec.ts @@ -0,0 +1,23 @@ +import { test, expect } from '@playwright/test'; + +test.describe('UI-Router React 17 Sample App', () => { + test('loads and navigates between states', async ({ page }) => { + await page.goto('/'); + + // Should have navigation links + await expect(page.getByTestId('home-link')).toBeVisible(); + await expect(page.getByTestId('about-link')).toBeVisible(); + + // Navigate to home + await page.getByTestId('home-link').click(); + await expect(page.getByTestId('home-title')).toHaveText('Home Page'); + + // Navigate to about + await page.getByTestId('about-link').click(); + await expect(page.getByTestId('about-title')).toHaveText('About Page'); + + // Navigate back to home + await page.getByTestId('home-link').click(); + await expect(page.getByTestId('home-title')).toHaveText('Home Page'); + }); +}); diff --git a/integration/react17/index.html b/integration/react17/index.html new file mode 100644 index 00000000..6291e9d3 --- /dev/null +++ b/integration/react17/index.html @@ -0,0 +1,12 @@ + + + + + + UI-Router React 17 Sample App + + +
+ + + diff --git a/integration/react17/package.json b/integration/react17/package.json new file mode 100644 index 00000000..f8d5c99a --- /dev/null +++ b/integration/react17/package.json @@ -0,0 +1,27 @@ +{ + "name": "integration-test-react17", + "version": "1.0.0", + "private": true, + "description": "Integration tests for @uirouter/react with React 17", + "scripts": { + "dev": "vite", + "build": "vite build", + "preview": "vite preview", + "test": "vitest run && npm run build && npx playwright install chromium && npx playwright test" + }, + "dependencies": { + "react": "^17.0.2", + "react-dom": "^17.0.2" + }, + "devDependencies": { + "@playwright/test": "^1.49.1", + "@testing-library/react": "^12.1.5", + "@types/react": "^17.0.80", + "@types/react-dom": "^17.0.25", + "@vitejs/plugin-react": "^4.3.4", + "jsdom": "^27.4.0", + "typescript": "^5.9.3", + "vite": "^6.0.7", + "vitest": "^4.0.16" + } +} diff --git a/integration/react17/playwright.config.ts b/integration/react17/playwright.config.ts new file mode 100644 index 00000000..ddf5ac79 --- /dev/null +++ b/integration/react17/playwright.config.ts @@ -0,0 +1,14 @@ +import { defineConfig } from '@playwright/test'; + +export default defineConfig({ + testDir: './e2e', + timeout: 30000, + use: { + baseURL: 'http://localhost:4173', + }, + webServer: { + command: 'npm run preview', + port: 4173, + reuseExistingServer: !process.env.CI, + }, +}); diff --git a/integration/react17/src/App.tsx b/integration/react17/src/App.tsx new file mode 100644 index 00000000..bba1f553 --- /dev/null +++ b/integration/react17/src/App.tsx @@ -0,0 +1,41 @@ +import React from 'react'; +import { UIRouter, UIView, UISref, hashLocationPlugin } from '@uirouter/react'; + +const Home = () => ( +
+

Home Page

+

Welcome to the UI-Router React 17 sample app!

+
+); + +const About = () => ( +
+

About Page

+

This is a simple sample application.

+
+); + +const states = [ + { name: 'home', url: '/home', component: Home }, + { name: 'about', url: '/about', component: About }, +]; + +const App = () => ( + +
+ +
+ +
+
+); + +export default App; diff --git a/integration/react17/src/main.tsx b/integration/react17/src/main.tsx new file mode 100644 index 00000000..c1f31c5f --- /dev/null +++ b/integration/react17/src/main.tsx @@ -0,0 +1,10 @@ +import React from 'react'; +import ReactDOM from 'react-dom'; +import App from './App'; + +ReactDOM.render( + + + , + document.getElementById('root') +); diff --git a/integration/react17/tsconfig.json b/integration/react17/tsconfig.json new file mode 100644 index 00000000..9973b069 --- /dev/null +++ b/integration/react17/tsconfig.json @@ -0,0 +1,18 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "module": "ESNext", + "skipLibCheck": true, + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + "strict": true, + "esModuleInterop": true + }, + "include": ["src", "e2e", "__tests__"] +} diff --git a/integration/react17/vite.config.ts b/integration/react17/vite.config.ts new file mode 100644 index 00000000..0466183a --- /dev/null +++ b/integration/react17/vite.config.ts @@ -0,0 +1,6 @@ +import { defineConfig } from 'vite'; +import react from '@vitejs/plugin-react'; + +export default defineConfig({ + plugins: [react()], +}); diff --git a/integration/react17/vitest.config.ts b/integration/react17/vitest.config.ts new file mode 100644 index 00000000..a927f1ea --- /dev/null +++ b/integration/react17/vitest.config.ts @@ -0,0 +1,9 @@ +import { defineConfig } from 'vitest/config'; + +export default defineConfig({ + test: { + environment: 'jsdom', + include: ['**/*.test.ts', '**/*.test.tsx'], + exclude: ['e2e/**', 'node_modules/**'], + }, +}); diff --git a/integration/react18/__tests__/sanity.test.tsx b/integration/react18/__tests__/sanity.test.tsx new file mode 100644 index 00000000..5be89813 --- /dev/null +++ b/integration/react18/__tests__/sanity.test.tsx @@ -0,0 +1,70 @@ +/** + * Sanity test for @uirouter/react with React 18 + * This test verifies basic functionality works with React 18 + */ +import { describe, it, expect } from 'vitest'; +import * as React from 'react'; +import { render, screen, waitFor } from '@testing-library/react'; +import { UIRouter, UIView, UISref, pushStateLocationPlugin } from '@uirouter/react'; +import { memoryLocationPlugin } from '@uirouter/core'; + +const Home = () =>
Home Page
; +const About = () =>
About Page
; + +const states = [ + { name: 'home', url: '/home', component: Home }, + { name: 'about', url: '/about', component: About }, +]; + +describe('@uirouter/react with React 18', () => { + it('renders UIRouter and UIView', async () => { + render( + + + + ); + + // Should render without crashing + expect(document.body).toBeDefined(); + }); + + it('navigates to a state and renders the component', async () => { + const { container } = render( + +
+ + +
+
+ ); + + // Click home link + screen.getByTestId('home-link').click(); + + await waitFor(() => { + expect(screen.getByTestId('home')).toBeDefined(); + }); + }); + + it('UISref generates correct href', async () => { + render( + + + About + + + ); + + await waitFor(() => { + const link = screen.getByTestId('link'); + expect(link.getAttribute('href')).toContain('/about'); + }); + }); +}); diff --git a/integration/react18/e2e/sanity.spec.ts b/integration/react18/e2e/sanity.spec.ts new file mode 100644 index 00000000..db68ad1e --- /dev/null +++ b/integration/react18/e2e/sanity.spec.ts @@ -0,0 +1,23 @@ +import { test, expect } from '@playwright/test'; + +test.describe('UI-Router React 18 Sample App', () => { + test('loads and navigates between states', async ({ page }) => { + await page.goto('/'); + + // Should have navigation links + await expect(page.getByTestId('home-link')).toBeVisible(); + await expect(page.getByTestId('about-link')).toBeVisible(); + + // Navigate to home + await page.getByTestId('home-link').click(); + await expect(page.getByTestId('home-title')).toHaveText('Home Page'); + + // Navigate to about + await page.getByTestId('about-link').click(); + await expect(page.getByTestId('about-title')).toHaveText('About Page'); + + // Navigate back to home + await page.getByTestId('home-link').click(); + await expect(page.getByTestId('home-title')).toHaveText('Home Page'); + }); +}); diff --git a/integration/react18/index.html b/integration/react18/index.html new file mode 100644 index 00000000..c9bcfd39 --- /dev/null +++ b/integration/react18/index.html @@ -0,0 +1,12 @@ + + + + + + UI-Router React 18 Sample App + + +
+ + + diff --git a/integration/react18/package.json b/integration/react18/package.json new file mode 100644 index 00000000..73c4324b --- /dev/null +++ b/integration/react18/package.json @@ -0,0 +1,27 @@ +{ + "name": "integration-test-react18", + "version": "1.0.0", + "private": true, + "description": "Integration tests for @uirouter/react with React 18", + "scripts": { + "dev": "vite", + "build": "vite build", + "preview": "vite preview", + "test": "vitest run && npm run build && npx playwright install chromium && npx playwright test" + }, + "dependencies": { + "react": "^18.3.1", + "react-dom": "^18.3.1" + }, + "devDependencies": { + "@playwright/test": "^1.49.1", + "@testing-library/react": "^14.3.1", + "@types/react": "^18.3.18", + "@types/react-dom": "^18.3.5", + "@vitejs/plugin-react": "^4.3.4", + "jsdom": "^27.4.0", + "typescript": "^5.9.3", + "vite": "^6.0.7", + "vitest": "^4.0.16" + } +} diff --git a/integration/react18/playwright.config.ts b/integration/react18/playwright.config.ts new file mode 100644 index 00000000..ddf5ac79 --- /dev/null +++ b/integration/react18/playwright.config.ts @@ -0,0 +1,14 @@ +import { defineConfig } from '@playwright/test'; + +export default defineConfig({ + testDir: './e2e', + timeout: 30000, + use: { + baseURL: 'http://localhost:4173', + }, + webServer: { + command: 'npm run preview', + port: 4173, + reuseExistingServer: !process.env.CI, + }, +}); diff --git a/integration/react18/src/App.tsx b/integration/react18/src/App.tsx new file mode 100644 index 00000000..fefe50e5 --- /dev/null +++ b/integration/react18/src/App.tsx @@ -0,0 +1,40 @@ +import { UIRouter, UIView, UISref, hashLocationPlugin } from '@uirouter/react'; + +const Home = () => ( +
+

Home Page

+

Welcome to the UI-Router React 18 sample app!

+
+); + +const About = () => ( +
+

About Page

+

This is a simple sample application.

+
+); + +const states = [ + { name: 'home', url: '/home', component: Home }, + { name: 'about', url: '/about', component: About }, +]; + +const App = () => ( + +
+ +
+ +
+
+); + +export default App; diff --git a/integration/react18/src/main.tsx b/integration/react18/src/main.tsx new file mode 100644 index 00000000..b31fb6bc --- /dev/null +++ b/integration/react18/src/main.tsx @@ -0,0 +1,9 @@ +import { StrictMode } from 'react'; +import { createRoot } from 'react-dom/client'; +import App from './App'; + +createRoot(document.getElementById('root')!).render( + + + +); diff --git a/integration/react18/tsconfig.json b/integration/react18/tsconfig.json new file mode 100644 index 00000000..9973b069 --- /dev/null +++ b/integration/react18/tsconfig.json @@ -0,0 +1,18 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "module": "ESNext", + "skipLibCheck": true, + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + "strict": true, + "esModuleInterop": true + }, + "include": ["src", "e2e", "__tests__"] +} diff --git a/integration/react18/vite.config.ts b/integration/react18/vite.config.ts new file mode 100644 index 00000000..0466183a --- /dev/null +++ b/integration/react18/vite.config.ts @@ -0,0 +1,6 @@ +import { defineConfig } from 'vite'; +import react from '@vitejs/plugin-react'; + +export default defineConfig({ + plugins: [react()], +}); diff --git a/integration/react18/vitest.config.ts b/integration/react18/vitest.config.ts new file mode 100644 index 00000000..a927f1ea --- /dev/null +++ b/integration/react18/vitest.config.ts @@ -0,0 +1,9 @@ +import { defineConfig } from 'vitest/config'; + +export default defineConfig({ + test: { + environment: 'jsdom', + include: ['**/*.test.ts', '**/*.test.tsx'], + exclude: ['e2e/**', 'node_modules/**'], + }, +}); diff --git a/integration/react19/__tests__/sanity.test.tsx b/integration/react19/__tests__/sanity.test.tsx new file mode 100644 index 00000000..3960b33a --- /dev/null +++ b/integration/react19/__tests__/sanity.test.tsx @@ -0,0 +1,70 @@ +/** + * Sanity test for @uirouter/react with React 19 + * This test verifies basic functionality works with React 19 + */ +import { describe, it, expect } from 'vitest'; +import * as React from 'react'; +import { render, screen, waitFor } from '@testing-library/react'; +import { UIRouter, UIView, UISref, pushStateLocationPlugin } from '@uirouter/react'; +import { memoryLocationPlugin } from '@uirouter/core'; + +const Home = () =>
Home Page
; +const About = () =>
About Page
; + +const states = [ + { name: 'home', url: '/home', component: Home }, + { name: 'about', url: '/about', component: About }, +]; + +describe('@uirouter/react with React 19', () => { + it('renders UIRouter and UIView', async () => { + render( + + + + ); + + // Should render without crashing + expect(document.body).toBeDefined(); + }); + + it('navigates to a state and renders the component', async () => { + const { container } = render( + +
+ + +
+
+ ); + + // Click home link + screen.getByTestId('home-link').click(); + + await waitFor(() => { + expect(screen.getByTestId('home')).toBeDefined(); + }); + }); + + it('UISref generates correct href', async () => { + render( + + + About + + + ); + + await waitFor(() => { + const link = screen.getByTestId('link'); + expect(link.getAttribute('href')).toContain('/about'); + }); + }); +}); diff --git a/integration/react19/e2e/sanity.spec.ts b/integration/react19/e2e/sanity.spec.ts new file mode 100644 index 00000000..05a5a535 --- /dev/null +++ b/integration/react19/e2e/sanity.spec.ts @@ -0,0 +1,23 @@ +import { test, expect } from '@playwright/test'; + +test.describe('UI-Router React 19 Sample App', () => { + test('loads and navigates between states', async ({ page }) => { + await page.goto('/'); + + // Should have navigation links + await expect(page.getByTestId('home-link')).toBeVisible(); + await expect(page.getByTestId('about-link')).toBeVisible(); + + // Navigate to home + await page.getByTestId('home-link').click(); + await expect(page.getByTestId('home-title')).toHaveText('Home Page'); + + // Navigate to about + await page.getByTestId('about-link').click(); + await expect(page.getByTestId('about-title')).toHaveText('About Page'); + + // Navigate back to home + await page.getByTestId('home-link').click(); + await expect(page.getByTestId('home-title')).toHaveText('Home Page'); + }); +}); diff --git a/integration/react19/index.html b/integration/react19/index.html new file mode 100644 index 00000000..3dd79c1a --- /dev/null +++ b/integration/react19/index.html @@ -0,0 +1,12 @@ + + + + + + UI-Router React 19 Sample App + + +
+ + + diff --git a/integration/react19/package.json b/integration/react19/package.json new file mode 100644 index 00000000..b61017d9 --- /dev/null +++ b/integration/react19/package.json @@ -0,0 +1,27 @@ +{ + "name": "integration-test-react19", + "version": "1.0.0", + "private": true, + "description": "Integration tests for @uirouter/react with React 19", + "scripts": { + "dev": "vite", + "build": "vite build", + "preview": "vite preview", + "test": "vitest run && npm run build && npx playwright install chromium && npx playwright test" + }, + "dependencies": { + "react": "^19.0.0", + "react-dom": "^19.0.0" + }, + "devDependencies": { + "@playwright/test": "^1.49.1", + "@testing-library/react": "^16.2.0", + "@types/react": "^19.0.7", + "@types/react-dom": "^19.0.3", + "@vitejs/plugin-react": "^4.3.4", + "jsdom": "^27.4.0", + "typescript": "^5.9.3", + "vite": "^6.0.7", + "vitest": "^4.0.16" + } +} diff --git a/integration/react19/playwright.config.ts b/integration/react19/playwright.config.ts new file mode 100644 index 00000000..ddf5ac79 --- /dev/null +++ b/integration/react19/playwright.config.ts @@ -0,0 +1,14 @@ +import { defineConfig } from '@playwright/test'; + +export default defineConfig({ + testDir: './e2e', + timeout: 30000, + use: { + baseURL: 'http://localhost:4173', + }, + webServer: { + command: 'npm run preview', + port: 4173, + reuseExistingServer: !process.env.CI, + }, +}); diff --git a/integration/react19/src/App.tsx b/integration/react19/src/App.tsx new file mode 100644 index 00000000..9341fb35 --- /dev/null +++ b/integration/react19/src/App.tsx @@ -0,0 +1,40 @@ +import { UIRouter, UIView, UISref, hashLocationPlugin } from '@uirouter/react'; + +const Home = () => ( +
+

Home Page

+

Welcome to the UI-Router React 19 sample app!

+
+); + +const About = () => ( +
+

About Page

+

This is a simple sample application.

+
+); + +const states = [ + { name: 'home', url: '/home', component: Home }, + { name: 'about', url: '/about', component: About }, +]; + +const App = () => ( + +
+ +
+ +
+
+); + +export default App; diff --git a/integration/react19/src/main.tsx b/integration/react19/src/main.tsx new file mode 100644 index 00000000..b31fb6bc --- /dev/null +++ b/integration/react19/src/main.tsx @@ -0,0 +1,9 @@ +import { StrictMode } from 'react'; +import { createRoot } from 'react-dom/client'; +import App from './App'; + +createRoot(document.getElementById('root')!).render( + + + +); diff --git a/integration/react19/tsconfig.json b/integration/react19/tsconfig.json new file mode 100644 index 00000000..9973b069 --- /dev/null +++ b/integration/react19/tsconfig.json @@ -0,0 +1,18 @@ +{ + "compilerOptions": { + "target": "ES2020", + "useDefineForClassFields": true, + "lib": ["ES2020", "DOM", "DOM.Iterable"], + "module": "ESNext", + "skipLibCheck": true, + "moduleResolution": "bundler", + "allowImportingTsExtensions": true, + "resolveJsonModule": true, + "isolatedModules": true, + "noEmit": true, + "jsx": "react-jsx", + "strict": true, + "esModuleInterop": true + }, + "include": ["src", "e2e", "__tests__"] +} diff --git a/integration/react19/vite.config.ts b/integration/react19/vite.config.ts new file mode 100644 index 00000000..0466183a --- /dev/null +++ b/integration/react19/vite.config.ts @@ -0,0 +1,6 @@ +import { defineConfig } from 'vite'; +import react from '@vitejs/plugin-react'; + +export default defineConfig({ + plugins: [react()], +}); diff --git a/integration/react19/vitest.config.ts b/integration/react19/vitest.config.ts new file mode 100644 index 00000000..a927f1ea --- /dev/null +++ b/integration/react19/vitest.config.ts @@ -0,0 +1,9 @@ +import { defineConfig } from 'vitest/config'; + +export default defineConfig({ + test: { + environment: 'jsdom', + include: ['**/*.test.ts', '**/*.test.tsx'], + exclude: ['e2e/**', 'node_modules/**'], + }, +}); diff --git a/package.json b/package.json index 04f60e3c..60e47347 100644 --- a/package.json +++ b/package.json @@ -11,6 +11,7 @@ "test:watch": "vitest", "test:ui": "vitest --ui", "test:downstream": "npm run build && test_downstream_projects", + "test:integration": "npm run build && test_downstream_projects --group=react-versions", "start": "cross-env NODE_ENV=development webpack-dev-server --host 0.0.0.0 --port 8000 --config ./examples/typescript/webpack.config.js --history-api-fallback", "clean": "shx rm -rf _bundles lib lib-esm build _doc", "compile": "npm run clean && tsc && tsc -m es6 --outDir lib-esm", @@ -49,14 +50,15 @@ "prop-types": "^15.8.1" }, "peerDependencies": { - "react": ">=16.8.0" + "react": "^17.0.0 || ^18.0.0 || ^19.0.0" }, "devDependencies": { + "@testing-library/dom": "^10", "@testing-library/jest-dom": "^6.9.1", - "@testing-library/react": "^12.0.0", + "@testing-library/react": "^16", "@types/prop-types": "^15.7.15", - "@types/react": "17.0.14", - "@types/react-dom": "17.0.9", + "@types/react": "^19", + "@types/react-dom": "^19", "@uirouter/publish-scripts": "^2.7.0", "@vitest/ui": "^4.0.16", "cross-env": "^10.1.0", @@ -64,8 +66,8 @@ "jsdom": "^27.4.0", "prettier": "^3.7.4", "pretty-quick": "^4.2.2", - "react": "^17.0.2", - "react-dom": "^17.0.2", + "react": "^19", + "react-dom": "^19", "ts-loader": "^9.5.4", "tsconfig-paths-webpack-plugin": "^4.2.0", "typescript": "^5.9.3", diff --git a/src/__tests__/util.tsx b/src/__tests__/util.tsx index a3c9ed7e..b8c7daa0 100644 --- a/src/__tests__/util.tsx +++ b/src/__tests__/util.tsx @@ -1,8 +1,8 @@ import * as React from 'react'; +import { act } from 'react'; import { describe, expect, it, vi } from 'vitest'; import { TransitionOptions, RawParams, StateOrName, TransitionPromise, memoryLocationPlugin } from '@uirouter/core'; import { render } from '@testing-library/react'; -import { act } from 'react-dom/test-utils'; import { UIRouterReact } from '../core'; import { servicesPlugin, UIRouter } from '../index'; import { ReactStateDeclaration } from '../interface'; diff --git a/src/components/UIRouter.tsx b/src/components/UIRouter.tsx index ae31a370..46c270b9 100644 --- a/src/components/UIRouter.tsx +++ b/src/components/UIRouter.tsx @@ -132,7 +132,7 @@ export const InstanceOrPluginsMissingError = `Router instance or plugins missing * ``` */ export function UIRouter(props: UIRouterProps) { - const uiRouter = useRef(); + const uiRouter = useRef(undefined); const [started, setStarted] = useState(false); useEffect(() => { diff --git a/src/components/UISref.tsx b/src/components/UISref.tsx index 2969b506..f3597d6c 100644 --- a/src/components/UISref.tsx +++ b/src/components/UISref.tsx @@ -50,7 +50,7 @@ export interface UISrefProps { * - the underlying tag (e.g.: anchor tag) has a 'target' attribute, such as `Open in new window` * - preventDefault has been called on the event, e.g.: ` e.preventDefault()}>no-op` */ -export const UISref: React.FC = ({ children, className, options, params, to }) => { +export const UISref: React.FC = ({ children, className = null, options = {}, params = {}, to }) => { const { onClick, href } = useSref(to, params, options); const childrenProps = children.props; @@ -88,9 +88,3 @@ UISref.propTypes = { options: PropTypes.object, className: PropTypes.string, }; - -UISref.defaultProps = { - params: {}, - options: {}, - className: null, -}; diff --git a/src/components/UIView.tsx b/src/components/UIView.tsx index 03ee04d4..2b0a7cf4 100644 --- a/src/components/UIView.tsx +++ b/src/components/UIView.tsx @@ -2,8 +2,8 @@ import * as PropTypes from 'prop-types'; import * as React from 'react'; import { ComponentType, + FunctionComponent, ReactNode, - ValidationMap, cloneElement, createContext, createElement, @@ -15,6 +15,7 @@ import { forwardRef, useImperativeHandle, useRef, + JSX, } from 'react'; import { ActiveUIView, @@ -129,7 +130,7 @@ function useRoutedComponentProps( router: UIRouter, stateName: string, viewConfig: ViewConfig, - component: React.FunctionComponent | React.ComponentClass | React.ClassicComponentClass, + component: FunctionComponent | React.ComponentClass, resolves: TypedMap | {}, className: string, style: Object, @@ -190,7 +191,7 @@ function useReactHybridApi(ref: React.Ref, uiViewData: ActiveUIView, ui */ function useUiCanExitClassComponentHook(router: UIRouter, stateName: string, maybeComponentClass: any) { // Use refs and run the callback outside of any render pass - const componentInstanceRef = useRef(); + const componentInstanceRef = useRef(undefined); const deregisterRef = useRef(() => undefined); function callbackRef(componentInstance) { @@ -278,7 +279,7 @@ View.propTypes = { className: PropTypes.string, style: PropTypes.object, render: PropTypes.func, -} as ValidationMap; +}; /** * UIView Viewport diff --git a/src/components/__tests__/UIRouter.test.tsx b/src/components/__tests__/UIRouter.test.tsx index 426f668b..a3121b66 100644 --- a/src/components/__tests__/UIRouter.test.tsx +++ b/src/components/__tests__/UIRouter.test.tsx @@ -8,7 +8,7 @@ import { memoryLocationPlugin } from '../../index'; import { muteConsoleErrors } from '../../__tests__/util'; class Child extends React.Component { - static propTypes: React.ValidationMap = { + static propTypes = { router: PropTypes.object, }; render() { diff --git a/src/components/__tests__/UIView.test.tsx b/src/components/__tests__/UIView.test.tsx index fe963a3e..ef907fd1 100644 --- a/src/components/__tests__/UIView.test.tsx +++ b/src/components/__tests__/UIView.test.tsx @@ -1,7 +1,7 @@ import { beforeEach, describe, expect, it, vi } from 'vitest'; import { render } from '@testing-library/react'; import * as React from 'react'; -import { act } from 'react-dom/test-utils'; +import { act } from 'react'; import { Transition } from '@uirouter/core'; import { makeTestRouter, muteConsoleErrors } from '../../__tests__/util'; @@ -90,7 +90,7 @@ describe('', () => { }); describe('injects the right props:', () => { - let lastProps = undefined; + let lastProps: any = undefined; const Comp = (props) => { lastProps = props; return component; diff --git a/src/hooks/__tests__/useSref.test.tsx b/src/hooks/__tests__/useSref.test.tsx index ffbac6a6..02da2edf 100644 --- a/src/hooks/__tests__/useSref.test.tsx +++ b/src/hooks/__tests__/useSref.test.tsx @@ -1,7 +1,7 @@ import { beforeEach, describe, expect, it, vi } from 'vitest'; import { fireEvent, render } from '@testing-library/react'; import * as React from 'react'; -import { act } from 'react-dom/test-utils'; +import { act } from 'react'; import { makeTestRouter, muteConsoleErrors } from '../../__tests__/util'; import { UIRouter, UIView } from '../../components'; import { UISrefActive, UISrefActiveContext } from '../../components/UISrefActive'; diff --git a/src/interface.tsx b/src/interface.tsx index 20912f44..e2687ce5 100644 --- a/src/interface.tsx +++ b/src/interface.tsx @@ -1,4 +1,4 @@ -import { StatelessComponent, ComponentClass, ClassicComponentClass } from 'react'; +import { FunctionComponent, ComponentClass } from 'react'; import { StateDeclaration, _ViewDeclaration, Transition } from '@uirouter/core'; /** @@ -169,7 +169,7 @@ export interface ReactViewDeclaration extends _ViewDeclaration { * } * ``` */ - component?: StatelessComponent | ComponentClass | ClassicComponentClass; + component?: FunctionComponent | ComponentClass; /** * @hidden diff --git a/yarn.lock b/yarn.lock index f471da35..ac6dbdcf 100644 --- a/yarn.lock +++ b/yarn.lock @@ -47,31 +47,24 @@ "@babel/highlight" "^7.8.3" "@babel/code-frame@^7.10.4": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.14.5.tgz#23b08d740e83f49c5e59945fbf1b43e80bbf4edb" - integrity sha512-9pzDqyc6OLDaqe+zbACgFkb6fKMNG6CObKpnYXChRsvYGyEdc7CA2BaqeOM+vOtCS5ndmJicPJhKAwYRI6UfFw== + version "7.27.1" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.27.1.tgz#200f715e66d52a23b221a9435534a91cc13ad5be" + integrity sha512-cjQ7ZlQ0Mv3b47hABuTevyTuYN4i+loJKGeV9flcCgIK37cCXRh+L1bd3iBHlynerhQ7BhCkn2BPbQUL+rGqFg== dependencies: - "@babel/highlight" "^7.14.5" + "@babel/helper-validator-identifier" "^7.27.1" + js-tokens "^4.0.0" + picocolors "^1.1.1" -"@babel/helper-validator-identifier@^7.14.5": - version "7.14.8" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.14.8.tgz#32be33a756f29e278a0d644fa08a2c9e0f88a34c" - integrity sha512-ZGy6/XQjllhYQrNw/3zfWRwZCTVSiBLZ9DHVZxn9n2gip/7ab8mv2TWlKPIBk26RwedCBoWdjLmn+t9na2Gcow== +"@babel/helper-validator-identifier@^7.27.1": + version "7.28.5" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz#010b6938fab7cb7df74aa2bbc06aa503b8fe5fb4" + integrity sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q== "@babel/helper-validator-identifier@^7.9.0": version "7.9.5" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.5.tgz#90977a8e6fbf6b431a7dc31752eee233bf052d80" integrity sha512-/8arLKUFq882w4tWGj9JYzRpAlZgiWUJ+dtteNTDqrRBz9Iguck9Rn3ykuBDoUwh2TO4tSAJlrxDUOXWklJe4g== -"@babel/highlight@^7.14.5": - version "7.14.5" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.14.5.tgz#6861a52f03966405001f6aa534a01a24d99e8cd9" - integrity sha512-qf9u2WFWVV0MppaL877j2dBtQIDgmidgjGk5VIMw3OadXvYaXn66U1BFlH2t4+t3i+8PhedppRv+i40ABzd+gg== - dependencies: - "@babel/helper-validator-identifier" "^7.14.5" - chalk "^2.0.0" - js-tokens "^4.0.0" - "@babel/highlight@^7.8.3": version "7.9.0" resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.9.0.tgz#4e9b45ccb82b79607271b2979ad82c7b68163079" @@ -81,15 +74,7 @@ chalk "^2.0.0" js-tokens "^4.0.0" -"@babel/runtime-corejs3@^7.10.2": - version "7.14.8" - resolved "https://registry.yarnpkg.com/@babel/runtime-corejs3/-/runtime-corejs3-7.14.8.tgz#68539e0129f13eb1ed9a9aa273d3542b93c88384" - integrity sha512-4dMD5QRBkumn45oweR0SxoNtt15oz3BUBAQ8cIx7HJqZTtE8zjpM0My8aHJHVnyf4XfRg6DNzaE1080WLBiC1w== - dependencies: - core-js-pure "^3.15.0" - regenerator-runtime "^0.13.4" - -"@babel/runtime@^7.10.2", "@babel/runtime@^7.12.5": +"@babel/runtime@^7.12.5": version "7.14.8" resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.14.8.tgz#7119a56f421018852694290b9f9148097391b446" integrity sha512-twj3L8Og5SaCRCErB4x4ajbvBIVV77CGeFglHpeg5WC5FF8TZzBWXtTJ4MqaD9QszLYTtr+IsaAL2rEUevb+eg== @@ -274,17 +259,6 @@ resolved "https://registry.yarnpkg.com/@exodus/bytes/-/bytes-1.8.0.tgz#8382835f71db8377cf634a4ef5a71806e86ba9c7" integrity sha512-8JPn18Bcp8Uo1T82gR8lh2guEOa5KKU/IEKvvdp0sgmi7coPBWf1Doi1EXsGZb2ehc8ym/StJCjffYV+ne7sXQ== -"@jest/types@^27.0.6": - version "27.0.6" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-27.0.6.tgz#9a992bc517e0c49f035938b8549719c2de40706b" - integrity sha512-aSquT1qa9Pik26JK5/3rvnYb4bGtm1VFNesHKmNTwmPIgOrixvhL2ghIvFRNEpzy3gU+rUgjIF/KodbkFAl++g== - dependencies: - "@types/istanbul-lib-coverage" "^2.0.0" - "@types/istanbul-reports" "^3.0.0" - "@types/node" "*" - "@types/yargs" "^16.0.0" - chalk "^4.0.0" - "@jridgewell/gen-mapping@^0.3.5": version "0.3.13" resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz#6342a19f44347518c93e43b1ac69deb3c4656a1f" @@ -508,18 +482,18 @@ resolved "https://registry.yarnpkg.com/@standard-schema/spec/-/spec-1.1.0.tgz#a79b55dbaf8604812f52d140b2c9ab41bc150bb8" integrity sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w== -"@testing-library/dom@^8.0.0": - version "8.1.0" - resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-8.1.0.tgz#f8358b1883844ea569ba76b7e94582168df5370d" - integrity sha512-kmW9alndr19qd6DABzQ978zKQ+J65gU2Rzkl8hriIetPnwpesRaK4//jEQyYh8fEALmGhomD/LBQqt+o+DL95Q== +"@testing-library/dom@^10": + version "10.4.1" + resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-10.4.1.tgz#d444f8a889e9a46e9a3b4f3b88e0fcb3efb6cf95" + integrity sha512-o4PXJQidqJl82ckFaXUeoAW+XysPLauYI43Abki5hABd853iMhitooc6znOnczgbTYmEP6U6/y1ZyKAIsvMKGg== dependencies: "@babel/code-frame" "^7.10.4" "@babel/runtime" "^7.12.5" - "@types/aria-query" "^4.2.0" - aria-query "^4.2.2" - chalk "^4.1.0" - dom-accessibility-api "^0.5.6" - lz-string "^1.4.4" + "@types/aria-query" "^5.0.1" + aria-query "5.3.0" + dom-accessibility-api "^0.5.9" + lz-string "^1.5.0" + picocolors "1.1.1" pretty-format "^27.0.2" "@testing-library/jest-dom@^6.9.1": @@ -534,18 +508,17 @@ picocolors "^1.1.1" redent "^3.0.0" -"@testing-library/react@^12.0.0": - version "12.0.0" - resolved "https://registry.yarnpkg.com/@testing-library/react/-/react-12.0.0.tgz#9aeb2264521522ab9b68f519eaf15136148f164a" - integrity sha512-sh3jhFgEshFyJ/0IxGltRhwZv2kFKfJ3fN1vTZ6hhMXzz9ZbbcTgmDYM4e+zJv+oiVKKEWZPyqPAh4MQBI65gA== +"@testing-library/react@^16": + version "16.3.1" + resolved "https://registry.yarnpkg.com/@testing-library/react/-/react-16.3.1.tgz#60a9f1f6a930399d9e41b506a8bf68dbf4831fe8" + integrity sha512-gr4KtAWqIOQoucWYD/f6ki+j5chXfcPc74Col/6poTyqTmn7zRmodWahWRCp8tYd+GMqBonw6hstNzqjbs6gjw== dependencies: "@babel/runtime" "^7.12.5" - "@testing-library/dom" "^8.0.0" -"@types/aria-query@^4.2.0": - version "4.2.2" - resolved "https://registry.yarnpkg.com/@types/aria-query/-/aria-query-4.2.2.tgz#ed4e0ad92306a704f9fb132a0cfcf77486dbe2bc" - integrity sha512-HnYpAE1Y6kRyKM/XkEuiRQhTHvkzMBurTHnpFLYLBGPIylZNPs9jJcuOOYWxPLJCSEtmZT0Y8rHDokKN7rRTig== +"@types/aria-query@^5.0.1": + version "5.0.4" + resolved "https://registry.yarnpkg.com/@types/aria-query/-/aria-query-5.0.4.tgz#1a31c3d378850d2778dabb6374d036dcba4ba708" + integrity sha512-rfT93uj5s0PRL7EzccGMs3brplhcrghnDoV26NqKhCAS1hVo+WdNsPvE/yb6ilfr5hi2MEk6d5EWJTKdxg8jVw== "@types/body-parser@*": version "1.19.6" @@ -672,25 +645,6 @@ dependencies: "@types/node" "*" -"@types/istanbul-lib-coverage@*", "@types/istanbul-lib-coverage@^2.0.0": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#42995b446db9a48a11a07ec083499a860e9138ff" - integrity sha512-hRJD2ahnnpLgsj6KWMYSrmXkM3rm2Dl1qkx6IOFD5FnuNPXJIG5L0dhgKXCYTRMGzU4n0wImQ/xfmRc4POUFlg== - -"@types/istanbul-lib-report@*": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz#c14c24f18ea8190c118ee7562b7ff99a36552686" - integrity sha512-plGgXAPfVKFoYfa9NpYDAkseG+g6Jr294RqeqcqDixSbU34MZVJRi/P+7Y8GDpzkEwLaGZZOpKIEmeVZNtKsrg== - dependencies: - "@types/istanbul-lib-coverage" "*" - -"@types/istanbul-reports@^3.0.0": - version "3.0.0" - resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-3.0.0.tgz#508b13aa344fa4976234e75dddcc34925737d821" - integrity sha512-nwKNbvnwJ2/mndE9ItP/zc2TCzw6uuodnF4EHYWD+gCQDVBuRQL5UzbZD0/ezy1iKsFU2ZQiDqg4M9dN4+wZgA== - dependencies: - "@types/istanbul-lib-report" "*" - "@types/json-schema@*": version "7.0.8" resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.8.tgz#edf1bf1dbf4e04413ca8e5b17b3b7d7d54b59818" @@ -728,11 +682,6 @@ resolved "https://registry.yarnpkg.com/@types/normalize-package-data/-/normalize-package-data-2.4.0.tgz#e486d0d97396d79beedd0a6e33f4534ff6b4973e" integrity sha512-f5j5b/Gf71L+dbqxIpQ4Z2WlmI/mPJ0fOkGGmFgtb6sAu97EPczzbS3/tJKxmcYDj55OX6ssqwDAWOHIYDRDGA== -"@types/prop-types@*": - version "15.7.3" - resolved "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.3.tgz#2ab0d5da2e5815f94b0b9d4b95d1e5f243ab2ca7" - integrity sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw== - "@types/prop-types@^15.7.15": version "15.7.15" resolved "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.15.tgz#e6e5a86d602beaca71ce5163fadf5f95d70931c7" @@ -748,40 +697,23 @@ resolved "https://registry.yarnpkg.com/@types/range-parser/-/range-parser-1.2.7.tgz#50ae4353eaaddc04044279812f52c8c65857dbcb" integrity sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ== -"@types/react-dom@17.0.9": - version "17.0.9" - resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-17.0.9.tgz#441a981da9d7be117042e1a6fd3dac4b30f55add" - integrity sha512-wIvGxLfgpVDSAMH5utdL9Ngm5Owu0VsGmldro3ORLXV8CShrL8awVj06NuEXFQ5xyaYfdca7Sgbk/50Ri1GdPg== - dependencies: - "@types/react" "*" - -"@types/react@*": - version "16.9.35" - resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.35.tgz#a0830d172e8aadd9bd41709ba2281a3124bbd368" - integrity sha512-q0n0SsWcGc8nDqH2GJfWQWUOmZSJhXV64CjVN5SvcNti3TdEaA3AH0D8DwNmMdzjMAC/78tB8nAZIlV8yTz+zQ== - dependencies: - "@types/prop-types" "*" - csstype "^2.2.0" +"@types/react-dom@^19": + version "19.2.3" + resolved "https://registry.yarnpkg.com/@types/react-dom/-/react-dom-19.2.3.tgz#c1e305d15a52a3e508d54dca770d202cb63abf2c" + integrity sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ== -"@types/react@17.0.14": - version "17.0.14" - resolved "https://registry.yarnpkg.com/@types/react/-/react-17.0.14.tgz#f0629761ca02945c4e8fea99b8177f4c5c61fb0f" - integrity sha512-0WwKHUbWuQWOce61UexYuWTGuGY/8JvtUe/dtQ6lR4sZ3UiylHotJeWpf3ArP9+DSGUoLY3wbU59VyMrJps5VQ== +"@types/react@^19": + version "19.2.7" + resolved "https://registry.yarnpkg.com/@types/react/-/react-19.2.7.tgz#84e62c0f23e8e4e5ac2cadcea1ffeacccae7f62f" + integrity sha512-MWtvHrGZLFttgeEj28VXHxpmwYbor/ATPYbBfSFZEIRK0ecCFLl2Qo55z52Hss+UV9CRN7trSeq1zbgx7YDWWg== dependencies: - "@types/prop-types" "*" - "@types/scheduler" "*" - csstype "^3.0.2" + csstype "^3.2.2" "@types/retry@0.12.2": version "0.12.2" resolved "https://registry.yarnpkg.com/@types/retry/-/retry-0.12.2.tgz#ed279a64fa438bb69f2480eda44937912bb7480a" integrity sha512-XISRgDJ2Tc5q4TRqvgJtzsRkFYNJzZrhTdtMoGVBttwzzQJkPnS3WWTFc7kuDRoPtPakl+T+OfdEUjYJj7Jbow== -"@types/scheduler@*": - version "0.16.2" - resolved "https://registry.yarnpkg.com/@types/scheduler/-/scheduler-0.16.2.tgz#1a62f89525723dde24ba1b01b092bf5df8ad4d39" - integrity sha512-hppQEBDmlwhFAXKJX2KnWLYu5yMfi91yazPb2l+lbJiwW+wdo1gNeRA+3RgNSO39WYX2euey41KEwnqesU2Jew== - "@types/send@*": version "0.17.5" resolved "https://registry.yarnpkg.com/@types/send/-/send-0.17.5.tgz#d991d4f2b16f2b1ef497131f00a9114290791e74" @@ -820,18 +752,6 @@ dependencies: "@types/node" "*" -"@types/yargs-parser@*": - version "15.0.0" - resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-15.0.0.tgz#cb3f9f741869e20cce330ffbeb9271590483882d" - integrity sha512-FA/BWv8t8ZWJ+gEOnLLd8ygxH/2UFbAvgEonyfN6yWGLKc7zVjbpl2Y4CTjid9h2RfgPP6SEt6uHwEOply00yw== - -"@types/yargs@^16.0.0": - version "16.0.4" - resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-16.0.4.tgz#26aad98dd2c2a38e421086ea9ad42b9e51642977" - integrity sha512-T8Yc9wt/5LbJyCaLiHPReJa0kApcIgJ7Bn735GjItUfh08Z1pJvu8QZqb9s+mMvKV6WUQRV7K2R46YbjMXTTJw== - dependencies: - "@types/yargs-parser" "*" - "@uirouter/core@6.1.2": version "6.1.2" resolved "https://registry.yarnpkg.com/@uirouter/core/-/core-6.1.2.tgz#2ccfe68488dede2e2afad8d7cf49e5652e512d96" @@ -1187,13 +1107,12 @@ anymatch@~3.1.2: normalize-path "^3.0.0" picomatch "^2.0.4" -aria-query@^4.2.2: - version "4.2.2" - resolved "https://registry.yarnpkg.com/aria-query/-/aria-query-4.2.2.tgz#0d2ca6c9aceb56b8977e9fed6aed7e15bbd2f83b" - integrity sha512-o/HelwhuKpTj/frsOsbNLNgnNGVIFsVP/SW2BSF14gVl7kAfMOJ6/8wUAUvG1R1NHKrfG+2sHZTu0yauT1qBrA== +aria-query@5.3.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/aria-query/-/aria-query-5.3.0.tgz#650c569e41ad90b51b3d7df5e5eed1c7549c103e" + integrity sha512-b0P0sZPKtyu8HkeRAfCq0IfURZK+SuwMjY1UXGBU27wpAiTwQAIlq56IbIO+ytk/JjS1fMR14ee5WBBfKi5J6A== dependencies: - "@babel/runtime" "^7.10.2" - "@babel/runtime-corejs3" "^7.10.2" + dequal "^2.0.3" aria-query@^5.0.0: version "5.3.2" @@ -1417,7 +1336,7 @@ chalk@^2.0.0, chalk@^2.4.1: escape-string-regexp "^1.0.5" supports-color "^5.3.0" -chalk@^4.0.0, chalk@^4.1.0: +chalk@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.1.tgz#c80b3fab28bf6371e6863325eee67e618b77e6ad" integrity sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg== @@ -1766,11 +1685,6 @@ cookie@0.7.1: resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.7.1.tgz#2f73c42142d5d5cf71310a74fc4ae61670e5dbc9" integrity sha512-6DnInpx7SJ2AK3+CTUE/ZM0vWTUboZCegxhC2xiIydHR9jNuTAASBrfEpHhiGOZw/nX51bHt6YQl8jsGo4y/0w== -core-js-pure@^3.15.0: - version "3.15.2" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.15.2.tgz#c8e0874822705f3385d3197af9348f7c9ae2e3ce" - integrity sha512-D42L7RYh1J2grW8ttxoY1+17Y4wXZeKe7uyplAI3FkNQyI5OgBIAjUfFiTPfL1rs0qLpxaabITNbjKl1Sp82tA== - core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" @@ -1836,15 +1750,10 @@ cssstyle@^5.3.4: css-tree "^3.1.0" lru-cache "^11.2.4" -csstype@^2.2.0: - version "2.6.10" - resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.10.tgz#e63af50e66d7c266edb6b32909cfd0aabe03928b" - integrity sha512-D34BqZU4cIlMCY93rZHbrq9pjTAQJ3U8S8rfBqjwHxkGPThWFjzZDQpgMJY0QViLxth6ZKYiwFBo14RdN44U/w== - -csstype@^3.0.2: - version "3.0.5" - resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.0.5.tgz#7fdec6a28a67ae18647c51668a9ff95bb2fa7bb8" - integrity sha512-uVDi8LpBUKQj6sdxNaTetL6FpeCqTjOvAQuQUa/qAqq8oOd4ivkbhgnqayl0dnPal8Tb/yB1tF+gOvCBiicaiQ== +csstype@^3.2.2: + version "3.2.3" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.2.3.tgz#ec48c0f3e993e50648c86da559e2610995cf989a" + integrity sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ== currently-unhandled@^0.4.1: version "0.4.1" @@ -1959,6 +1868,11 @@ depd@~1.1.2: resolved "https://registry.yarnpkg.com/depd/-/depd-1.1.2.tgz#9bcd52e14c097763e749b274c4346ed2e560b5a9" integrity sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak= +dequal@^2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/dequal/-/dequal-2.0.3.tgz#2644214f1997d39ed0ee0ece72335490a7ac67be" + integrity sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA== + destroy@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.2.0.tgz#4803735509ad8be552934c67df614f94e66fa015" @@ -1981,10 +1895,10 @@ dns-packet@^5.2.2: dependencies: "@leichtgewicht/ip-codec" "^2.0.1" -dom-accessibility-api@^0.5.6: - version "0.5.6" - resolved "https://registry.yarnpkg.com/dom-accessibility-api/-/dom-accessibility-api-0.5.6.tgz#3f5d43b52c7a3bd68b5fb63fa47b4e4c1fdf65a9" - integrity sha512-DplGLZd8L1lN64jlT27N9TVSESFR5STaEJvX+thCby7fuCHonfPpAlodYc3vuUYbDuDec5w8AMP7oCM5TWFsqw== +dom-accessibility-api@^0.5.9: + version "0.5.16" + resolved "https://registry.yarnpkg.com/dom-accessibility-api/-/dom-accessibility-api-0.5.16.tgz#5a7429e6066eb3664d911e33fb0e45de8eb08453" + integrity sha512-X7BJ2yElsnOJ30pZF4uIIDfBEVgF4XEBxL9Bxhy6dnrm5hkzqmsWHGTiHqRiITNhMyFLyAiWndIJP7Z1NTteDg== dom-accessibility-api@^0.6.3: version "0.6.3" @@ -3159,7 +3073,7 @@ lodash@^4.17.15, lodash@^4.17.21: resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== -loose-envify@^1.1.0, loose-envify@^1.4.0: +loose-envify@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf" integrity sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q== @@ -3186,10 +3100,10 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" -lz-string@^1.4.4: - version "1.4.4" - resolved "https://registry.yarnpkg.com/lz-string/-/lz-string-1.4.4.tgz#c0d8eaf36059f705796e1e344811cf4c498d3a26" - integrity sha1-wNjq82BZ9wV5bh40SBHPTEmNOiY= +lz-string@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/lz-string/-/lz-string-1.5.0.tgz#c1ab50f77887b712621201ba9fd4e3a6ed099941" + integrity sha512-h5bgJWpxJNswbU7qCrV0tIKQCaS3blPDrqKWx+QxzuzL1zGUzij9XCWLrSLsJPu5t+eWA/ycetzYAO5IOMcWAQ== magic-string@^0.30.21: version "0.30.21" @@ -3784,7 +3698,7 @@ pathe@^2.0.3: resolved "https://registry.yarnpkg.com/pathe/-/pathe-2.0.3.tgz#3ecbec55421685b70a9da872b2cff3e1cbed1716" integrity sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w== -picocolors@^1.1.1: +picocolors@1.1.1, picocolors@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== @@ -3853,12 +3767,11 @@ prettier@^3.7.4: integrity sha512-v6UNi1+3hSlVvv8fSaoUbggEM5VErKmmpGA7Pl3HF8V6uKY7rvClBOJlH6yNwQtfTueNkGVpOv/mtWL9L4bgRA== pretty-format@^27.0.2: - version "27.0.6" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-27.0.6.tgz#ab770c47b2c6f893a21aefc57b75da63ef49a11f" - integrity sha512-8tGD7gBIENgzqA+UBzObyWqQ5B778VIFZA/S66cclyd5YkFLYs2Js7gxDKf0MXtTc9zcS7t1xhdfcElJ3YIvkQ== + version "27.5.1" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-27.5.1.tgz#2181879fdea51a7a5851fb39d920faa63f01d88e" + integrity sha512-Qb1gy5OrP5+zDf2Bvnzdl3jsTf1qXVMazbvCoKhtKqVs4/YK4ozX4gKQJJVyNe+cajNPn0KoC0MC3FUmaHWEmQ== dependencies: - "@jest/types" "^27.0.6" - ansi-regex "^5.0.0" + ansi-regex "^5.0.1" ansi-styles "^5.0.0" react-is "^17.0.1" @@ -3946,14 +3859,12 @@ raw-body@2.5.2: iconv-lite "0.4.24" unpipe "1.0.0" -react-dom@^17.0.2: - version "17.0.2" - resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-17.0.2.tgz#ecffb6845e3ad8dbfcdc498f0d0a939736502c23" - integrity sha512-s4h96KtLDUQlsENhMn1ar8t2bEa+q/YAtj8pPPdIjPDGBDIVNsrD9aXNWqspUe6AzKCIG0C1HZZLqLV7qpOBGA== +react-dom@^19: + version "19.2.3" + resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-19.2.3.tgz#f0b61d7e5c4a86773889fcc1853af3ed5f215b17" + integrity sha512-yELu4WmLPw5Mr/lmeEpox5rw3RETacE++JgHqQzd2dg+YbJuat3jH4ingc+WPZhxaoFzdv9y33G+F7Nl5O0GBg== dependencies: - loose-envify "^1.1.0" - object-assign "^4.1.1" - scheduler "^0.20.2" + scheduler "^0.27.0" react-is@^16.13.1: version "16.13.1" @@ -3961,17 +3872,14 @@ react-is@^16.13.1: integrity sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ== react-is@^17.0.1: - version "17.0.1" - resolved "https://registry.yarnpkg.com/react-is/-/react-is-17.0.1.tgz#5b3531bd76a645a4c9fb6e693ed36419e3301339" - integrity sha512-NAnt2iGDXohE5LI7uBnLnqvLQMtzhkiAOLXTmv+qnF9Ky7xAPcX8Up/xWIhxvLVGJvuLiNc4xQLtuqDRzb4fSA== - -react@^17.0.2: version "17.0.2" - resolved "https://registry.yarnpkg.com/react/-/react-17.0.2.tgz#d0b5cc516d29eb3eee383f75b62864cfb6800037" - integrity sha512-gnhPt75i/dq/z3/6q/0asP78D0u592D5L1pd7M8P+dck6Fu/jJeL6iVVK23fptSUZj8Vjf++7wXA8UNclGQcbA== - dependencies: - loose-envify "^1.1.0" - object-assign "^4.1.1" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-17.0.2.tgz#e691d4a8e9c789365655539ab372762b0efb54f0" + integrity sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w== + +react@^19: + version "19.2.3" + resolved "https://registry.yarnpkg.com/react/-/react-19.2.3.tgz#d83e5e8e7a258cf6b4fe28640515f99b87cd19b8" + integrity sha512-Ku/hhYbVjOQnXDZFv2+RibmLFGwFdeeKHFcOTlrt7xplBnya5OGn/hIRDsqDiSUcfORsDC7MPxwork8jBwsIWA== read-pkg-up@^1.0.1: version "1.0.1" @@ -4243,13 +4151,10 @@ saxes@^6.0.0: dependencies: xmlchars "^2.2.0" -scheduler@^0.20.2: - version "0.20.2" - resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.20.2.tgz#4baee39436e34aa93b4874bddcbf0fe8b8b50e91" - integrity sha512-2eWfGgAqqWFGqtdMmcL5zCMK1U8KlXv8SQFGglL3CEtd0aDVDWgeF/YoCmvln55m5zSk3J/20hTaSBeSObsQDQ== - dependencies: - loose-envify "^1.1.0" - object-assign "^4.1.1" +scheduler@^0.27.0: + version "0.27.0" + resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.27.0.tgz#0c4ef82d67d1e5c1e359e8fc76d3a87f045fe5bd" + integrity sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q== schema-utils@^4.0.0, schema-utils@^4.2.0, schema-utils@^4.3.0: version "4.3.2"