mirror of
https://github.com/TriliumNext/Notes.git
synced 2025-07-27 18:12:29 +08:00
test(ckeditor5-mermaid): fix imports
This commit is contained in:
parent
c3f9f3696e
commit
abc8e2279c
@ -1,4 +1,8 @@
|
||||
import { ClassicEditor, Paragraph, _setModelData as setModelData, _getModelData as getModelData } from 'ckeditor5';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import MermaidEditing from '../../dist/mermaidediting';
|
||||
import InsertMermaidCommand from '../../dist/commands/insertMermaidCommand';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
@ -2,6 +2,8 @@ import { ClassicEditor, Paragraph, _setModelData as setModelData, _getModelData
|
||||
|
||||
import MermaidPreviewCommand from '../../src/commands/mermaidPreviewCommand.js';
|
||||
import MermaidEditing from '../../src/mermaidediting.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
@ -2,6 +2,8 @@ import { ClassicEditor, Paragraph, _setModelData as setModelData, _getModelData
|
||||
|
||||
import MermaidSourceViewCommand from '../../src/commands/mermaidSourceViewCommand.js';
|
||||
import MermaidEditing from '../../src/mermaidediting.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
@ -2,6 +2,8 @@ import { ClassicEditor, Paragraph, _setModelData as setModelData, _getModelData
|
||||
|
||||
import MermaidSplitViewCommand from '../../src/commands/mermaidSplitViewCommand.js';
|
||||
import MermaidEditing from '../../src/mermaidediting.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
@ -6,6 +6,8 @@ import insertMermaidIcon from './../theme/icons/insert.svg';
|
||||
import previewModeIcon from './../theme/icons/preview-mode.svg';
|
||||
import splitModeIcon from './../theme/icons/split-mode.svg';
|
||||
import sourceModeIcon from './../theme/icons/source-mode.svg';
|
||||
import { describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
describe( 'CKEditor5 Mermaid DLL', () => {
|
||||
it( 'exports MermaidWidget', () => {
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
/* globals console, window, document */
|
||||
|
||||
import { ClassicEditor, Typing, Paragraph, Undo, Enter, Clipboard, Link, Bold, Italic, CodeBlock } from '@ckeditor/ckeditor5-editor-classic';
|
||||
import { ClassicEditor, Typing, Paragraph, Undo, Enter, Clipboard, Link, Bold, Italic, CodeBlock } from 'ckeditor5';
|
||||
|
||||
import Mermaid from '../../src/mermaid.js';
|
||||
|
||||
|
@ -1,6 +1,8 @@
|
||||
import { ClassicEditor, Essentials, Paragraph, Heading, _setModelData as setModelData } from 'ckeditor5';
|
||||
|
||||
import Mermaid from '../src/mermaid.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
import { ClassicEditor, Essentials, Paragraph, Heading, CodeBlockEditing, _setModelData as setModelData, _getModelData as getModelData, _getViewData as getViewData } from 'ckeditor5';
|
||||
import MermaidEditing from '../src/mermaidediting.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
import { vi } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
@ -240,7 +243,7 @@ describe( 'MermaidEditing', () => {
|
||||
} );
|
||||
|
||||
expect( renderMermaidStub.callCount ).to.equal( 1 );
|
||||
sinon.assert.calledWithExactly( renderMermaidStub, domPreviewContainer );
|
||||
expect(renderMermaidStub).toBeCalledWith(domPreviewContainer);
|
||||
} );
|
||||
} );
|
||||
} );
|
||||
|
@ -1,6 +1,8 @@
|
||||
import { ClassicEditor as ClassicTestEditor, Essentials, Paragraph, WidgetToolbarRepository, _setModelData as setData } from 'ckeditor5';
|
||||
|
||||
import Mermaid from '../src/mermaid.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
@ -2,6 +2,8 @@ import { ClassicEditor, _setModelData as setModelData } from 'ckeditor5';
|
||||
|
||||
import Mermaid from '../src/mermaid.js';
|
||||
import MermaidUI from '../src/mermaidui.js';
|
||||
import { afterEach, beforeEach, describe, it } from 'vitest';
|
||||
import { expect } from 'vitest';
|
||||
|
||||
/* global document */
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user