Type inputs
This commit is contained in:
parent
973f6e6ae8
commit
22d2eb2ff7
|
@ -10,6 +10,7 @@
|
||||||
closeBracketsKeymap,
|
closeBracketsKeymap,
|
||||||
acceptCompletion,
|
acceptCompletion,
|
||||||
completionStatus,
|
completionStatus,
|
||||||
|
CompletionContext,
|
||||||
} from "@codemirror/autocomplete"
|
} from "@codemirror/autocomplete"
|
||||||
import {
|
import {
|
||||||
lineNumbers,
|
lineNumbers,
|
||||||
|
@ -44,11 +45,15 @@
|
||||||
import { javascript } from "@codemirror/lang-javascript"
|
import { javascript } from "@codemirror/lang-javascript"
|
||||||
import { EditorModes } from "./"
|
import { EditorModes } from "./"
|
||||||
import { themeStore } from "@/stores/portal"
|
import { themeStore } from "@/stores/portal"
|
||||||
import type { EditorMode } from "@budibase/types"
|
import type { BindingCompletion, EditorMode } from "@budibase/types"
|
||||||
|
|
||||||
export let label: string | undefined = undefined
|
export let label: string | undefined = undefined
|
||||||
// TODO: work out what best type fits this
|
// TODO: work out what best type fits this
|
||||||
export let completions: any[] = []
|
export let completions: ((context: CompletionContext) => Promise<{
|
||||||
|
from: number
|
||||||
|
filter: boolean
|
||||||
|
options: BindingCompletion[]
|
||||||
|
} | null>)[] = []
|
||||||
export let mode: EditorMode = EditorModes.Handlebars
|
export let mode: EditorMode = EditorModes.Handlebars
|
||||||
export let value: string | null = ""
|
export let value: string | null = ""
|
||||||
export let placeholder: string | null = null
|
export let placeholder: string | null = null
|
||||||
|
|
Loading…
Reference in New Issue