Comment on cmd+enter too
This commit is contained in:
parent
ce30b34480
commit
a3973b3481
|
@ -136,7 +136,7 @@ function FeedBet(props: { activityItem: any; feedType: FeedType }) {
|
||||||
placeholder="Add a comment..."
|
placeholder="Add a comment..."
|
||||||
rows={3}
|
rows={3}
|
||||||
onKeyDown={(e) => {
|
onKeyDown={(e) => {
|
||||||
if (e.key === 'Enter' && e.ctrlKey) {
|
if (e.key === 'Enter' && (e.ctrlKey || e.metaKey)) {
|
||||||
submitComment()
|
submitComment()
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
|
@ -181,7 +181,7 @@ function EditContract(props: {
|
||||||
e.target.setSelectionRange(text.length, text.length)
|
e.target.setSelectionRange(text.length, text.length)
|
||||||
}
|
}
|
||||||
onKeyDown={(e) => {
|
onKeyDown={(e) => {
|
||||||
if (e.key === 'Enter' && e.ctrlKey) {
|
if (e.key === 'Enter' && (e.ctrlKey || e.metaKey)) {
|
||||||
onSave(text)
|
onSave(text)
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user