Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into emulate-hover-command
Browse files Browse the repository at this point in the history
  • Loading branch information
vursen committed Jan 31, 2025
2 parents 23b391e + 100f4d1 commit 52b4a7c
Show file tree
Hide file tree
Showing 265 changed files with 401 additions and 632 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ packages/*/test/visual/screenshots/failed
packages/*/test/visual/*/screenshots/*/failed
packages/icons/test/visual/screenshots/failed

# Generated Lit test files
packages/*/test/*.generated.*

# Generated theme folders .ts files
packages/**/theme/**/*.d.ts

Expand Down
24 changes: 12 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"scripts": {
"analyze": "polymer analyze packages/**/vaadin-*.js > analysis.json && node scripts/prepareDocs.js && node scripts/buildWebtypes.js && node scripts/generateLumoAutoCompleteCss.js && ./scripts/buildThemeTypings.sh",
"build:ts": "tsc --build tsconfig.build.json",
"debug": "web-test-runner --watch",
"debug:it": "web-test-runner --watch --config web-test-runner-it.config.js",
"debug": "yarn test --watch",
"debug:it": "yarn test --watch --config web-test-runner-it.config.js",
"dist": "rimraf dist && yarn analyze && rollup -c rollup.config.js && cp analysis.json dist",
"docs": "yarn analyze && web-dev-server --node-resolve --open",
"icons": "lerna run icons",
Expand All @@ -18,16 +18,16 @@
"prepare": "husky",
"serve:dist": "web-dev-server --app-index dist/index.html --open",
"start": "web-dev-server --node-resolve --open /dev",
"test": "web-test-runner",
"test:firefox": "web-test-runner --config web-test-runner-firefox.config.js",
"test:it": "web-test-runner --config web-test-runner-it.config.js",
"test:lumo": "web-test-runner --config web-test-runner-lumo.config.js",
"test:material": "web-test-runner --config web-test-runner-material.config.js",
"test:snapshots": "web-test-runner --config web-test-runner-snapshots.config.js",
"test:webkit": "web-test-runner --config web-test-runner-webkit.config.js",
"update:lumo": "TEST_ENV=update web-test-runner --config web-test-runner-lumo.config.js",
"update:material": "TEST_ENV=update web-test-runner --config web-test-runner-material.config.js",
"update:snapshots": "web-test-runner --config web-test-runner-snapshots.config.js --update-snapshots"
"test": "node scripts/generateLitTests.js && web-test-runner",
"test:firefox": "yarn test --config web-test-runner-firefox.config.js",
"test:it": "yarn test --config web-test-runner-it.config.js",
"test:lumo": "yarn test --config web-test-runner-lumo.config.js",
"test:material": "yarn test --config web-test-runner-material.config.js",
"test:snapshots": "yarn test --config web-test-runner-snapshots.config.js",
"test:webkit": "yarn test --config web-test-runner-webkit.config.js",
"update:lumo": "TEST_ENV=update yarn test --config web-test-runner-lumo.config.js",
"update:material": "TEST_ENV=update yarn test --config web-test-runner-material.config.js",
"update:snapshots": "yarn test --config web-test-runner-snapshots.config.js --update-snapshots"
},
"devDependencies": {
"@fontsource/roboto": "^4.5.8",
Expand Down
1 change: 1 addition & 0 deletions packages/a11y-base/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
}
Expand Down
1 change: 1 addition & 0 deletions packages/a11y-base/src/list-mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export const ListMixin = (superClass) =>
type: Number,
reflectToAttribute: true,
notify: true,
sync: true,
},

/**
Expand Down
4 changes: 1 addition & 3 deletions packages/a11y-base/test/focus-trap-controller.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,7 @@ async function tab() {
}

async function shiftTab() {
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });
return document.activeElement;
}

Expand Down
2 changes: 0 additions & 2 deletions packages/a11y-base/test/list-mixin.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,6 @@ const runTests = (defineHelper, baseMixin) => {

it('should reset previously selected item when listbox and items are disabled', async () => {
list.selected = 3;
await nextUpdate(list);
expect(items[3].selected).to.be.true;

list.disabled = true;
Expand All @@ -788,7 +787,6 @@ const runTests = (defineHelper, baseMixin) => {

it('should restore previously selected item when listbox becomes re-enabled', async () => {
list.selected = 3;
await nextUpdate(list);

list.disabled = true;
items.forEach((item) => {
Expand Down
1 change: 1 addition & 0 deletions packages/accordion/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/app-layout/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
4 changes: 1 addition & 3 deletions packages/app-layout/test/helpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,5 @@ export async function tab() {
}

export async function shiftTab() {
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });
}
1 change: 1 addition & 0 deletions packages/avatar-group/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/avatar/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/board/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/button/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/icon": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
Expand Down
2 changes: 0 additions & 2 deletions packages/button/test/button-lit.test.ts

This file was deleted.

2 changes: 0 additions & 2 deletions packages/button/test/button-polymer.test.ts

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { expect } from '@vaadin/chai-plugins';
import { resetMouse, sendKeys, sendMouseToElement } from '@vaadin/test-runner-commands';
import { fire, fixtureSync, nextRender, nextUpdate } from '@vaadin/testing-helpers';
import sinon from 'sinon';
import '../vaadin-button.js';
import type { Button } from '../vaadin-button.js';

describe('vaadin-button', () => {
Expand Down
1 change: 1 addition & 0 deletions packages/card/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/charts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/checkbox-group/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
4 changes: 1 addition & 3 deletions packages/checkbox-group/test/checkbox-group.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -287,9 +287,7 @@ describe('vaadin-checkbox-group', () => {
await sendKeys({ press: 'Tab' });

// Move focus out of the checkbox group.
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });

expect(checkboxes[0].hasAttribute('focused')).to.be.false;
expect(group.hasAttribute('focused')).to.be.false;
Expand Down
8 changes: 2 additions & 6 deletions packages/checkbox-group/test/validation.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,7 @@ describe('validation', () => {
expect(validateSpy.called).to.be.false;

// Move focus out of the checkbox group.
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });
expect(validateSpy.calledOnce).to.be.true;
});

Expand Down Expand Up @@ -132,9 +130,7 @@ describe('validation', () => {
await sendKeys({ press: 'Tab' });

// Move focus out of the checkbox group.
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });

expect(validateSpy.called).to.be.false;
});
Expand Down
1 change: 1 addition & 0 deletions packages/checkbox/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
4 changes: 1 addition & 3 deletions packages/checkbox/test/validation.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,7 @@ describe('validation', () => {
await sendKeys({ press: 'Tab' });

// Blur the checkbox.
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });

expect(validateSpy.called).to.be.false;
});
Expand Down
1 change: 1 addition & 0 deletions packages/combo-box/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"@vaadin/text-field": "24.7.0-alpha7",
"sinon": "^18.0.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/combo-box/test/visual/lumo/combo-box.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { sendKeys, sendMouse } from '@vaadin/test-runner-commands';
import { fixtureSync, mousedown, nextFrame } from '@vaadin/testing-helpers';
import { visualDiff } from '@web/test-runner-visual-regression';
import '../common.js';
import '../../../theme/lumo/vaadin-combo-box.js';
import '../../not-animated-styles.js';
import '../../../theme/lumo/vaadin-combo-box.js';

describe('combo-box', () => {
let div, element;
Expand Down
2 changes: 1 addition & 1 deletion packages/combo-box/test/visual/material/combo-box.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { sendKeys } from '@vaadin/test-runner-commands';
import { fixtureSync } from '@vaadin/testing-helpers/dist/fixture.js';
import { visualDiff } from '@web/test-runner-visual-regression';
import '../common.js';
import '../../../theme/material/vaadin-combo-box.js';
import '../../not-animated-styles.js';
import '../../../theme/material/vaadin-combo-box.js';

describe('combo-box', () => {
let div, element;
Expand Down
1 change: 1 addition & 0 deletions packages/component-base/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,7 @@ describe('reorder elements', () => {
// Tab upwards
for (let i = tabToIndex - 1; i >= 0; i--) {
await nextFrame();
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });
await nextFrame();
expect(document.activeElement.id).to.equal(`item-${i}`);
}
Expand Down
1 change: 1 addition & 0 deletions packages/confirm-dialog/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
"devDependencies": {
"@vaadin/a11y-base": "24.7.0-alpha7",
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/context-menu/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
4 changes: 1 addition & 3 deletions packages/context-menu/test/a11y.common.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,7 @@ describe('a11y', () => {
it('should move focus to the prev element outside the menu on Shift+Tab pressed inside', async () => {
contextMenuButton.click();
await nextRender();
await sendKeys({ down: 'Shift' });
await sendKeys({ press: 'Tab' });
await sendKeys({ up: 'Shift' });
await sendKeys({ press: 'Shift+Tab' });
expect(getDeepActiveElement()).to.equal(firstGlobalFocusable);
});

Expand Down
1 change: 1 addition & 0 deletions packages/cookie-consent/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0"
},
"cvdlName": "vaadin-cookie-consent",
Expand Down
1 change: 1 addition & 0 deletions packages/crud/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0",
"sinon": "^18.0.0"
},
Expand Down
1 change: 1 addition & 0 deletions packages/custom-field/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/combo-box": "24.7.0-alpha7",
"@vaadin/date-picker": "24.7.0-alpha7",
"@vaadin/email-field": "24.7.0-alpha7",
Expand Down
1 change: 1 addition & 0 deletions packages/dashboard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
},
"devDependencies": {
"@vaadin/chai-plugins": "24.7.0-alpha7",
"@vaadin/test-runner-commands": "24.7.0-alpha7",
"@vaadin/testing-helpers": "^1.1.0"
},
"cvdlName": "vaadin-dashboard",
Expand Down
Loading

0 comments on commit 52b4a7c

Please sign in to comment.