mirror of
https://github.com/stablyai/orca
synced 2026-04-21 14:17:16 +00:00
fix: address auto-review findings (#703)
This commit is contained in:
parent
250dd77414
commit
bb53c4a7b6
1 changed files with 1 additions and 4 deletions
|
|
@ -204,13 +204,10 @@ export default function MarkdownPreview({
|
|||
|
||||
const target = event.target
|
||||
const targetInsidePreview = target instanceof Node && root.contains(target)
|
||||
const targetIsEditable =
|
||||
target instanceof HTMLElement &&
|
||||
(target.isContentEditable || target.closest('input, textarea, select') !== null)
|
||||
|
||||
if (
|
||||
isMarkdownPreviewFindShortcut(event, navigator.userAgent.includes('Mac')) &&
|
||||
(isSearchOpen || targetInsidePreview || !targetIsEditable)
|
||||
targetInsidePreview
|
||||
) {
|
||||
event.preventDefault()
|
||||
event.stopPropagation()
|
||||
|
|
|
|||
Loading…
Reference in a new issue