SourceEditor.svelte view source
import SourceEditor from '@fuzdev/zzz/SourceEditor.svelte'; value
The source text.
type
string bindable
lang?
The fuz_code language to highlight as — a language registered on
syntax_styler_global, like lang_for_path returns; null disables
highlighting.
type
string | nulloptional default
nullreadonly?
type
booleanoptional default
falseplaceholder?
type
string | nulloptional
focus_key?
Focuses the textarea when pending_element_to_focus_key equals it, then clears that.
type
string | number | nulloptional
pending_element_to_focus_key?
type
string | number | nulloptional bindable
onsave?
Called with the value on Ctrl+S / Cmd+S — see save_shortcut.
type
(value: string) => voidoptional
snippet parameters
value stringsave_shortcut?
Where Ctrl+S / Cmd+S triggers onsave — see SaveShortcutScope.
type SaveShortcutScope
optional default
'focused'attrs?
Attributes for the <textarea>.
type
HTMLTextareaAttributesoptional
wrapper_attrs?
Attributes for CodeTextarea's wrapper <div>, the box the textarea fills.
type
HTMLAttributes<HTMLDivElement>optional