update dependencies

This commit is contained in:
Luck
2024-08-24 11:05:21 +01:00
parent 776a1c5def
commit fb40855a9a
4 changed files with 100 additions and 96 deletions

View File

@@ -19,6 +19,11 @@ import type { editor } from 'monaco-editor';
import { ResetFunction } from './Editor';
import { logLanguage } from '../util/log-language';
import * as monaco from 'monaco-editor';
import { loader } from '@monaco-editor/react';
loader.config({ monaco });
export interface EditorTextAreaProps {
forcedContent: string;
actualContent: string;
@@ -261,13 +266,13 @@ function useLineNumberMagic(
}
const handler = (click: MouseEvent) => {
const target = click?.target as HTMLElement;
const element = document.elementFromPoint(click.x, click.y);
if (
target &&
target.classList.contains('line-numbers') &&
target.textContent
element &&
element.classList.contains('line-numbers') &&
element.textContent
) {
toggleSelected(parseInt(target.textContent), click);
toggleSelected(parseInt(element.textContent), click);
}
};