You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 717f18f
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/rich-markdown-editor/find/use-markdown-find.ts
+16-11Lines changed: 16 additions & 11 deletions
Original file line number
Diff line number
Diff line change
@@ -86,9 +86,9 @@ export function useMarkdownFind({
Copy file name to clipboardExpand all lines: apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/rich-markdown-editor/menus/bubble-menu.tsx
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -221,6 +221,7 @@ export function EditorBubbleMenu({
221
221
* preventing a lost pointer release from suppressing later keyboard selections.
222
222
*/
223
223
useEffect(()=>{
224
+
if(editor.isDestroyed)return
224
225
constdom=editor.view.dom
225
226
constonPointerDown=()=>{
226
227
isPointerDownRef.current=true
@@ -255,6 +256,7 @@ export function EditorBubbleMenu({
Copy file name to clipboardExpand all lines: apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/rich-markdown-editor/menus/link-hover-card.tsx
Copy file name to clipboardExpand all lines: apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/rich-markdown-editor/menus/suggestion-list.tsx
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -64,6 +64,7 @@ export function SuggestionList<T>({
Copy file name to clipboardExpand all lines: apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/rich-markdown-editor/menus/use-bubble-menu-floating.ts
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -21,6 +21,7 @@ export function bubbleMenuAnchorRange(selection: Selection): { from: number; to:
21
21
* editor mounts so the caller skips positioning.
22
22
*/
23
23
functionselectionVirtualElement(editor: Editor){
24
+
if(editor.isDestroyed)returnnull
24
25
const{ view, state }=editor
25
26
if(!view.dom.isConnected)returnnull
26
27
const{ from, to }=bubbleMenuAnchorRange(state.selection)
@@ -53,10 +54,11 @@ export function useBubbleMenuFloating(
Copy file name to clipboardExpand all lines: apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/rich-markdown-editor/menus/use-editor-toolbar.ts
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -54,6 +54,7 @@ export function useEditorToolbar({
0 commit comments