-
Notifications
You must be signed in to change notification settings - Fork 116
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
feat(keyboard-key): create package #4136
Conversation
Run & review this pull request in StackBlitz Codeflow. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
🦋 Changeset detectedLatest commit: 7ce2925 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
🦋 Changeset detectedLatest commit: bff42f7 The changes in this PR will be included in the next version bump. This PR includes changesets to release 7 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@@ -59,11 +58,11 @@ export interface KeyboardKeyProps extends HTMLPasteProps<"div"> { | |||
* @type string | |||
* @memberof KeyboardKeyProps | |||
*/ | |||
keyText?: string; | |||
keyEvent?: string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion (non-blocking): maybe add to the description comment here that the docs have a chart of usable keyEvents? or a link to the map that you were using at one point?
slash would it make sense to limit the type of keyEvent
from string
to an actual list of usable key codes? I'm guessing no for scalability, but wanted to ask
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A really great suggestion. Pushing up the comment update. We can use the event.which
which is the code number. It's something I feel developers would be more used to but it changes based on browser as mentioned in the link to the table. It is also deprecated so browsers at some point in the future may stop returning that field.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice changes, thanks for incorporating all the feedback!
2542004
Paste Run #9047
Run Properties:
|
Project |
Paste
|
Branch Review |
create-keyboard-key
|
Run status |
Passed #9047
|
Run duration | 06m 05s |
Commit |
821bacfe54 ℹ️: Merge 7ce29252297553c34d5829940be7b4d97a564f43 into 65d60549287436daf2f752dd142d...
|
Committer | krisantrobus |
View all properties for this run ↗︎ |
Test results | |
---|---|
Failures |
0
|
Flaky |
0
|
Pending |
0
|
Skipped |
0
|
Passing |
125
|
View all changes introduced in this branch ↗︎ |
This pull request introduces a new
KeyboardKey
component. It's purpose is to display visual indicators for keyboard shortcuts available to users.