Skip to content

Commit 56f2a5c

Browse files
committed
refactor: comment issues about ts
1 parent 4e7673c commit 56f2a5c

File tree

5 files changed

+9
-8
lines changed

5 files changed

+9
-8
lines changed

plugins/text-editor-resources/src/components/EmojiPopup.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
import { createEventDispatcher } from 'svelte'
2020
import emojiReplaceDict from './extension/emojiIdMap.json'
2121
22-
export let query: string = ''
22+
export let query = ''
2323
2424
let items = Object.entries(emojiReplaceDict)
2525

plugins/text-editor-resources/src/components/MentionList.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import MentionPopup from './MentionPopup.svelte'
1818
import Popup from './Popup.svelte'
1919
20-
export let query: string = ''
20+
export let query = ''
2121
export let clientRect: () => ClientRect
2222
export let command: (props: any) => void
2323
export let close: () => void

plugins/text-editor-resources/src/components/MentionPopup.svelte

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
import { Label, ListView, resizeObserver } from '@hcengineering/ui'
2020
import { createEventDispatcher } from 'svelte'
2121
22-
export let query: string = ''
22+
export let query = ''
2323
2424
let items: SearchItem[] = []
2525
@@ -29,15 +29,15 @@
2929
let scrollContainer: HTMLElement
3030
let selection = 0
3131
32-
function dispatchItem (item: SearchResultDoc): void {
32+
function dispatchItem(item: SearchResultDoc): void {
3333
dispatch('close', {
3434
id: item.id,
3535
label: item.shortTitle ?? item.title,
3636
objectclass: item.doc._class
3737
})
3838
}
3939
40-
export function onKeyDown (key: KeyboardEvent): boolean {
40+
export function onKeyDown(key: KeyboardEvent): boolean {
4141
if (key.key === 'ArrowDown') {
4242
key.stopPropagation()
4343
key.preventDefault()

plugins/text-editor-resources/src/components/Popup.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
import { onDestroy, onMount } from 'svelte'
1919
import DummyPopup from './DummyPopup.svelte'
2020
21-
export let query: string = ''
21+
export let query = ''
2222
export let clientRect: () => ClientRect
2323
export let command: (props: any) => void
2424
export let close: () => void

plugins/text-editor-resources/tsconfig.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"compilerOptions": {
55
"rootDir": "./src",
66
"outDir": "./lib",
7-
"declarationDir": "./types"
7+
"declarationDir": "./types",
8+
"resolveJsonModule": true
89
}
9-
}
10+
}

0 commit comments

Comments
 (0)