mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-02 01:49:51 +08:00
refactor(editor): cleanup ts-expect-error (#9369)
This commit is contained in:
@@ -482,7 +482,7 @@ export const LatexExtension = InlineMarkdownExtension({
|
||||
if (!latexBlock || latexBlock.flavour !== 'affine:latex') return;
|
||||
|
||||
//FIXME(@Flrande): wait for refactor
|
||||
// @ts-expect-error FIXME: ts error
|
||||
// @ts-expect-error BS-2241
|
||||
latexBlock.toggleEditor();
|
||||
})
|
||||
.catch(console.error);
|
||||
|
||||
+3
-6
@@ -58,10 +58,7 @@ export class AffineLatexNode extends SignalWatcher(
|
||||
gap: 10px;
|
||||
|
||||
border-radius: 4px;
|
||||
background: ${
|
||||
// @ts-expect-error FIXME: ts error
|
||||
unsafeCSSVarV2('label/red')
|
||||
};
|
||||
background: ${unsafeCSSVarV2('chip/label/red')};
|
||||
|
||||
color: ${unsafeCSSVarV2('text/highlight/fg/red')};
|
||||
font-family: Inter;
|
||||
@@ -126,7 +123,7 @@ export class AffineLatexNode extends SignalWatcher(
|
||||
if (!latexContainer) return;
|
||||
|
||||
latexContainer.replaceChildren();
|
||||
// @ts-expect-error FIXME: ts error
|
||||
// @ts-expect-error lit hack won't fix
|
||||
delete latexContainer['_$litPart$'];
|
||||
|
||||
if (latex.length === 0) {
|
||||
@@ -142,7 +139,7 @@ export class AffineLatexNode extends SignalWatcher(
|
||||
});
|
||||
} catch {
|
||||
latexContainer.replaceChildren();
|
||||
// @ts-expect-error FIXME: ts error
|
||||
// @ts-expect-error lit hack won't fix
|
||||
delete latexContainer['_$litPart$'];
|
||||
render(
|
||||
html`<span class="error-placeholder">Error equation</span>`,
|
||||
|
||||
Reference in New Issue
Block a user