Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Make it work with components 24.7 alpha2 #3051

Merged
merged 9 commits into from
Dec 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3,354 changes: 2,145 additions & 1,209 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"@remcovaes/web-test-runner-vite-plugin": "^1.2.2",
"@types/karma": "^6.3.9",
"@types/node": "^22.10.2",
"@vaadin/react-components": "24.7.0-alpha1",
"@vaadin/react-components": "24.7.0-alpha2",
"@vitejs/plugin-react": "^4.3.4",
"@web/test-runner": "^0.19.0",
"chai-dom": "^1.12.0",
Expand Down
6 changes: 4 additions & 2 deletions packages/ts/file-router/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,14 @@
"react-router": "^7"
},
"devDependencies": {
"@esm-bundle/chai": "^4.3.4",
"@types/chai-as-promised": "^7.1.8",
"@types/chai-fs": "^2.0.5",
"@types/chai-like": "^1.1.3",
"@types/deep-equal-in-any-order": "^1.0.4",
"@types/mocha": "^10.0.10",
"@types/sinon": "^10.0.20",
"@types/sinon-chai": "^3.2.12",
"chai": "^5.1.2",
"chai-as-promised": "^7.1.2",
"chai-deep-equal-ignore-undefined": "^1.1.1",
"chai-fs": "^2.0.0",
Expand All @@ -81,10 +81,12 @@
"type-fest": "^4.30.2"
},
"dependencies": {
"@types/chai": "^5.0.1",
"@vaadin/hilla-generator-utils": "24.7.0-alpha2",
"@vaadin/hilla-react-auth": "24.7.0-alpha2",
"@vaadin/hilla-react-signals": "24.7.0-alpha2",
"react": "^18.3.1",
"c8": "^10.1.3",
"react": "^18.2.0",
"rollup": "^4.21.0",
"typescript": "5.7.2"
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiLike from 'chai-like';
import { createElement } from 'react';
import sinonChai from 'sinon-chai';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import './vaadinGlobals.js'; // eslint-disable-line import/no-unassigned-import
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiLike from 'chai-like';
import type { Writable } from 'type-fest';
import { createMenuItems, viewsSignal } from '../../src/runtime/createMenuItems.js';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/file-router/test/runtime/createRoute.spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiLike from 'chai-like';
import { createRoute, extendModule } from '../../src/runtime/createRoute.js';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { writeFile } from 'node:fs/promises';
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiAsPromised from 'chai-as-promised';
import chaiDeepEqualIgnoreUndefined from 'chai-deep-equal-ignore-undefined';
import applyLayouts from '../../src/vite-plugin/applyLayouts.js';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { appendFile } from 'fs/promises';
import { mkdir, rm } from 'node:fs/promises';
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiAsPromised from 'chai-as-promised';
import sinonChai from 'sinon-chai';
import type { Writable } from 'type-fest';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { tmpdir } from 'node:os';
import { join } from 'node:path';
import { pathToFileURL } from 'node:url';
import { expect } from '@esm-bundle/chai';
import { expect } from 'chai';
import type { RouteMeta } from '../../src/vite-plugin/collectRoutesFromFS.js';
import createRoutesFromMeta from '../../src/vite-plugin/createRoutesFromMeta.js';
import type { RuntimeFileUrls } from '../../src/vite-plugin/generateRuntimeFiles.js';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { appendFile, mkdir, rm } from 'node:fs/promises';
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiAsPromised from 'chai-as-promised';
import chaiLike from 'chai-like';
import { RouteParamType } from '../../src/shared/routeParamType.js';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { existsSync, watch } from 'node:fs';
import { rm, mkdir, writeFile, readFile } from 'node:fs/promises';
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiAsPromised from 'chai-as-promised';
import type { Logger } from 'vite';
import { generateRuntimeFiles, type RuntimeFileUrls } from '../../src/vite-plugin/generateRuntimeFiles.js';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { EventEmitter } from 'node:events';
import { existsSync, rmSync } from 'node:fs';
import { fileURLToPath } from 'node:url';
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiAsPromised from 'chai-as-promised';
import sinon from 'sinon';
import sinonChai from 'sinon-chai';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@
"lit": "^3.0.0"
},
"devDependencies": {
"@esm-bundle/chai": "^4.3.4",
"@open-wc/testing": "^3.2.2",
"@types/atmosphere.js": "^2.1.6",
"@types/chai": "^4.3.20",
Expand All @@ -82,6 +81,7 @@
"@types/sinon": "^10.0.20",
"@types/sinon-chai": "^3.2.12",
"@types/validator": "^13.12.2",
"chai": "^5.1.2",
"chai-as-promised": "^7.1.2",
"chai-dom": "^1.12.0",
"fetch-mock": "^9.11.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/frontend/test/Authentication.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiDom from 'chai-dom';
import fetchMock from 'fetch-mock';
import sinon from 'sinon';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/frontend/test/Connect.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable no-new */
import { expect, use } from '@esm-bundle/chai';
import { ConnectionState, ConnectionStateStore } from '@vaadin/common-frontend';
import { expect, use } from 'chai';
import chaiAsPromised from 'chai-as-promised';
import fetchMock from 'fetch-mock';
import sinon from 'sinon';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/frontend/test/CookieManager.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect } from '@esm-bundle/chai';
import { expect } from 'chai';
import { calculatePath } from '../src/CookieManager.js';

describe('@vaadin/hilla-frontend', () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/frontend/test/FluxConnection.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { expect } from '@esm-bundle/chai';
import type { ReactiveController, ReactiveControllerHost } from '@lit/reactive-element';
import { expect } from 'chai';
import sinon from 'sinon';
import { ActionOnLostSubscription, FluxConnection, FluxSubscriptionState, State } from '../src/FluxConnection.js';
import type {
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/frontend/test/SpringCsrfTestUtils.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect } from '@esm-bundle/chai';
import { expect } from 'chai';

export const TEST_SPRING_CSRF_HEADER_NAME = 'x-xsrf-token';
export const TEST_SPRING_CSRF_TOKEN_VALUE = 'spring-csrf-token';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
"type-fest": "^4.30.2"
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-plugin-backbone/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-plugin-barrel/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-plugin-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-plugin-model/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-plugin-push/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
1 change: 1 addition & 0 deletions packages/ts/generator-plugin-signals/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-plugin-subtypes/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"pino": "^8.21.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/generator-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"concurrently": "^8.2.2",
"copyfiles": "^2.4.1",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
"monocart-coverage-reports": "^2.11.5",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
"type-fest": "^4.30.2"
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -78,13 +78,13 @@
"lit": "^3.0.0"
},
"devDependencies": {
"@esm-bundle/chai": "^4.3.4",
"@types/chai": "^4.3.20",
"@types/chai-dom": "^1.11.3",
"@types/mocha": "^10.0.10",
"@types/sinon": "^10.0.20",
"@types/sinon-chai": "^3.2.12",
"@types/validator": "^13.12.2",
"chai": "^5.1.2",
"chai-dom": "^1.12.0",
"sinon": "^16.1.3",
"sinon-chai": "^3.7.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/test/Binder.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* eslint-disable sort-keys */
import { assert, expect, use } from '@esm-bundle/chai';
import { assert, expect, use } from 'chai';
import { LitElement } from 'lit';
import { customElement } from 'lit/decorators.js';
import sinon from 'sinon';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/test/Field.test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* eslint-disable no-unused-expressions, no-shadow, @typescript-eslint/unbound-method */
import { assert, expect, use } from '@esm-bundle/chai';
import { assert, expect, use } from 'chai';
import chaiDom from 'chai-dom';
import { LitElement, nothing, render } from 'lit';
import { customElement, query } from 'lit/decorators.js';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/test/Index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
* License for the specific language governing permissions and limitations under
* the License.
*/
import { assert } from '@esm-bundle/chai';
import { assert } from 'chai';
import type { VaadinWindow } from './types.js';

describe('@vaadin/hilla-lit-form', () => {
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/test/Model.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect } from '@esm-bundle/chai';
import { expect } from 'chai';
// API to test
import {
_enum,
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/test/Validation.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable no-unused-expressions, no-shadow */
import { assert, expect, use } from '@esm-bundle/chai';
import { EndpointValidationError, ValidationErrorData } from '@vaadin/hilla-frontend';
import { assert, expect, use } from 'chai';
import chaiDom from 'chai-dom';
import { css, html, LitElement } from 'lit';
import { customElement, query } from 'lit/decorators.js';
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/lit-form/test/Validators.test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assert } from '@esm-bundle/chai';
import { assert } from 'chai';
// API to test
import {
AssertFalse,
Expand Down
7 changes: 5 additions & 2 deletions packages/ts/models/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@
"@vaadin/hilla-lit-form": "24.7.0-alpha2"
},
"peerDependencies": {
"react": "^18"
"react": "^18",
"react-dom": "^18"
},
"devDependencies": {
"@esm-bundle/chai": "^4.3.4",
"@testing-library/react": "^16.1.0",
"@testing-library/user-event": "^14.5.2",
"@types/chai": "^4.3.20",
Expand All @@ -62,12 +62,15 @@
"@types/mocha": "^10.0.10",
"@types/node": "^20.17.10",
"@types/react": "^18.3.17",
"@types/react-dom": "^18",
"@types/sinon": "^10.0.20",
"@types/sinon-chai": "^3.2.12",
"@types/validator": "^13.12.2",
"c8": "^10.1.3",
"chai": "^5.1.2",
"chai-as-promised": "^7.1.2",
"chai-dom": "^1.12.0",
"chai-like": "^1.1.3",
"glob": "^10.4.5",
"mocha": "^10.8.2",
"monocart-coverage-reports": "^2.11.4",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/models/test/models.spec.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { expect, use } from '@esm-bundle/chai';
import { expect, use } from 'chai';
import chaiLike from 'chai-like';
import m, {
$defaultValue,
Expand Down
3 changes: 2 additions & 1 deletion packages/ts/react-auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,18 +54,19 @@
"react-router": "^7"
},
"devDependencies": {
"@esm-bundle/chai": "^4.3.4",
"@testing-library/dom": "^10.4.0",
"@testing-library/react": "^16.1.0",
"@testing-library/user-event": "^14.5.2",
"@types/chai": "^4.3.20",
"@types/chai-dom": "^1.11.3",
"@types/mocha": "^10.0.10",
"@types/react": "^18.3.17",
"@types/react-dom": "^18",
"@types/sinon": "^10.0.20",
"@types/sinon-chai": "^3.2.12",
"@types/validator": "^13.12.2",
"@web/test-runner": "^0.19.0",
"chai": "^5.1.2",
"chai-dom": "^1.12.0",
"react-router": "^7.0.2",
"sinon": "^16.1.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/ts/react-auth/test/ProtectedRoute.spec.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { expect } from '@esm-bundle/chai';
import { render, waitFor } from '@testing-library/react';
import { expect } from 'chai';
import { createMemoryRouter, RouterProvider } from 'react-router';
import { configureAuth, protectRoutes, type RouteObjectWithAuth } from '../src';

Expand Down
2 changes: 1 addition & 1 deletion packages/ts/react-auth/test/useAuth.spec.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { expect } from '@esm-bundle/chai';
import { renderHook, waitFor } from '@testing-library/react';
import { UnauthorizedResponseError } from '@vaadin/hilla-frontend';
import { expect } from 'chai';
import { configureAuth } from '../src';

describe('@vaadin/react-auth', () => {
Expand Down
Loading
Loading