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

Add list of keyboard shortcuts to document settings #447

Merged
merged 10 commits into from
Apr 11, 2024

Conversation

shueja
Copy link
Collaborator

@shueja shueja commented Apr 9, 2024

Closes #373

Ctrl/Command key is shown depending on the user's detected OS

image
image
image
image

src/components/config/KeyboardShortcutsPanel.tsx Outdated Show resolved Hide resolved
Space: "Start/stop path playback",
Escape: "Clear sidebar and navbar selection"
},
"Field View": {
Copy link
Collaborator

Choose a reason for hiding this comment

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

why are some keys with quotes and some without? Are we trying to keep single words without quotes? Is there a purpose between differentiating?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The Prettier formatter unquoted the ones with single words. IDK if it's worth figuring out how to ignore it here

Copy link
Collaborator

Choose a reason for hiding this comment

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

then thats fine.

E: "Rotates 1/32 turn clockwise",
Q: "Rotates 1/32 turn counterclockwise",
"Shift + Rotation Key": "Rotate by 1/8 turn instead of 1/32 turn",
W: "Translate 0.1 m up (+Y)",
Copy link
Collaborator

Choose a reason for hiding this comment

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

Doesn't this decrease y value?

Copy link
Collaborator

Choose a reason for hiding this comment

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

(Line 57)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

No

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I don't know what you're seeing but upwards on the screen is increasing Y

@@ -68,17 +69,28 @@ class SettingsModal extends Component<Props, State> {
<Tab label="Robot Config" />
<Tab label="Export Config" />
<Tab label="Betas" />
<Tab label="Controls" />
Copy link
Collaborator

Choose a reason for hiding this comment

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

should controls go before betas?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Sure

src/components/config/SettingsModal.tsx Outdated Show resolved Hide resolved
isMac = (type == "Darwin");
})
// These default to the Mac ⌘ key because it's easier to replace with Ctrl than vice versa
let shortcuts = {
Copy link
Collaborator

Choose a reason for hiding this comment

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

all of these should be flipped. I see people looking for what is the generate key to find the shortcut. not, oh i forgot what command G does?

tldr should be descriptions on left and the shortcut on right (flipped).

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Done

>
{Object.entries(shortcuts).map((entry) => (
<>
<Accordion>
Copy link
Collaborator

Choose a reason for hiding this comment

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

What is this gap doing here?

98105

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Fixed

Copy link
Collaborator

@Awesomeplayer165 Awesomeplayer165 left a comment

Choose a reason for hiding this comment

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

lgtm

@shueja shueja merged commit f2bf795 into main Apr 11, 2024
26 checks passed
@shueja shueja deleted the feature/controls-settings-page branch April 11, 2024 17:59
spacey-sooty pushed a commit to spacey-sooty/Choreo that referenced this pull request Jun 23, 2024
idk why but my ide is acting up so there are probably errors that ill fix later. Anyway, I added a static field in Choreo.java which stores the current trajectory that the robot is on. Calling choreoSwerveCommand() will update this to the trajectory it is given, and then, when finished, put it back to an empty trajectory. There is also now a new static event() method in Choreo.java which returns a trigger for if the robot is currently on a trajectory given as an argument.

holy guacamole i forgot a semicolon

imported trigger

i mightve jumped the gun but i was bored so heres another event function. is this good

more methodsgit add .! more

le fixes

Add list of keyboard shortcuts to document settings (SleipnirGroup#447)

Co-authored-by: Jacob Trentini <[email protected]>

Feature: Context Menu (SleipnirGroup#448)

* add context menu with popover

* format

* silence error with conflicting mouseevent

* format

* works but only if you hot reload (fixing with next commit)

* step 1 out of predicted 2: migrate local state to uiState

* step 2/2: move d3 callback to overlaywaypoint

* format

* format and refactorings

* address @calcmogul's concerns

Upgrade TrajoptLib to use larger solver tolerance (SleipnirGroup#451)

organization and comments

renaming

cleanup java impl

fix docs

format
spacey-sooty pushed a commit to spacey-sooty/Choreo that referenced this pull request Jun 23, 2024
idk why but my ide is acting up so there are probably errors that ill fix later. Anyway, I added a static field in Choreo.java which stores the current trajectory that the robot is on. Calling choreoSwerveCommand() will update this to the trajectory it is given, and then, when finished, put it back to an empty trajectory. There is also now a new static event() method in Choreo.java which returns a trigger for if the robot is currently on a trajectory given as an argument.

holy guacamole i forgot a semicolon

imported trigger

i mightve jumped the gun but i was bored so heres another event function. is this good

more methodsgit add .! more

le fixes

Add list of keyboard shortcuts to document settings (SleipnirGroup#447)

Co-authored-by: Jacob Trentini <[email protected]>

Feature: Context Menu (SleipnirGroup#448)

* add context menu with popover

* format

* silence error with conflicting mouseevent

* format

* works but only if you hot reload (fixing with next commit)

* step 1 out of predicted 2: migrate local state to uiState

* step 2/2: move d3 callback to overlaywaypoint

* format

* format and refactorings

* address @calcmogul's concerns

Upgrade TrajoptLib to use larger solver tolerance (SleipnirGroup#451)

organization and comments

renaming

cleanup java impl

fix docs

format
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add keyboard shortcuts tab to document settings
2 participants