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

Enable keyboard control for 3d canvases #2163

Merged
merged 4 commits into from
May 11, 2024
Merged

Enable keyboard control for 3d canvases #2163

merged 4 commits into from
May 11, 2024

Conversation

Floppy
Copy link
Collaborator

@Floppy Floppy commented May 11, 2024

Not great controls yet, just the defaults, but they do work as expected and are minimally usable. Resolves #2105

@Floppy Floppy added improvement Refactors and behind-the-scenes improvements accessibility Accessibility issues & tasks labels May 11, 2024
@Floppy Floppy enabled auto-merge May 11, 2024 10:02
Copy link

codeclimate bot commented May 11, 2024

Code Climate has analyzed commit 245c924 and detected 2 issues on this pull request.

Here's the issue category breakdown:

Category Count
Duplication 2

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 87.1% (0.0% change).

View more on Code Climate.

]
eventHandlers.forEach((eventName) => {
const pointerEvents = ['pointerdown', 'pointermove', 'pointerup']
pointerEvents.forEach((eventName) => {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar blocks of code found in 2 locations. Consider refactoring.

this.canvas.addEventListener(eventName, this.onPointerEvent.bind(this))
})
const keyEvents = ['keydown', 'keyup']
keyEvents.forEach((eventName) => {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar blocks of code found in 2 locations. Consider refactoring.

@Floppy Floppy merged commit 267068a into main May 11, 2024
10 checks passed
@Floppy Floppy deleted the keyboard-controls branch May 11, 2024 10:05
@Floppy Floppy added feature User-facing features and product enhancements and removed improvement Refactors and behind-the-scenes improvements labels May 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accessibility Accessibility issues & tasks feature User-facing features and product enhancements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't reach 3d models via keyboard navigation
1 participant