IJodit
- Hierarchy
- Implemented by
- isJodit
- options
- history
- editor
- element
- places
- currentPlace
- value
- text
- editorDocument
- ed
- editorWindow
- ew
- createInside
- selection
- s
- mode
- editorIsActive
- isFocused
- workplace
- statusbar
- uploader
- filebrowser
- iframe
- mods
- container
- async
- ownerDocument
- od
- ownerWindow
- ow
- componentName
- uid
- isDestructed
- isInDestruct
- isReady
- componentStatus
- isView
- parent
- id
- basePath
- isLocked
- isFullSize
- buffer
- storage
- progressbar
- events
- e
- create
- c
- OPTIONS
- o
- defaultTimeout
- components
- message
- toolbar
- toolbarContainer
- registeredButtons
- getNativeEditorValue
- getEditorValue
- setEditorValue
- getElementValue
- getReadOnly
- setReadOnly
- addPlace
- setCurrentPlace
- waitForReady
- getRealMode
- getMode
- isEditorMode
- toggleMode
- focus
- fetch
- execCommand
- nativeExecCommand
- registerCommand
- registerHotkeyToCommand
- setMod
- afterSetMod
- getMod
- getElm
- getElms
- dlg
- confirm
- prompt
- alert
- destruct
- get
- className
- getFullElName
- setStatus
- hookStatus
- bindDestruct
- isLockedNotBy
- lock
- unlock
- toggleFullSize
- i18n
- getVersion
- getInstance
- registerButton
- unregisterButton
- getRegisteredButtonGroups
- setPanel
types.IJodit
Hierarchy
-
↳
IJodit
Implemented by
isJodit
Readonly
isJodit: true
Defined in
options
Readonly
options: Config
Overrides
Defined in
history
Readonly
history: IHistory
Defined in
editor
editor: HTMLElement
Defined in
element
Readonly
element: HTMLElement
Defined in
places
Readonly
places: IWorkPlace
[]
Defined in
currentPlace
Readonly
currentPlace: IWorkPlace
Defined in
value
value: string
Defined in
text
Readonly
text: string
Defined in
editorDocument
Readonly
editorDocument: HTMLDocument
Defined in
ed
Readonly
ed: HTMLDocument
Alias for this.ed
Defined in
editorWindow
editorWindow: Window
Defined in
ew
Readonly
ew: Window
Alias for this.ed
Defined in
createInside
Readonly
createInside: ICreate
Defined in
selection
Readonly
selection: ISelect
Defined in
s
Readonly
s: ISelect
Alias for this.selection
Defined in
mode
Readonly
mode: Modes
Defined in
editorIsActive
Readonly
editorIsActive: boolean
Defined in
isFocused
Readonly
isFocused: boolean
Defined in
workplace
Readonly
workplace: HTMLDivElement
workplace It contains source and wysiwyg editors
Defined in
statusbar
Readonly
statusbar: IStatusBar
Defined in
uploader
Readonly
uploader: IUploader
Defined in
filebrowser
Readonly
filebrowser: IFileBrowser
<IFileBrowserOptions
>
Defined in
iframe
Optional
iframe: void
| HTMLIFrameElement
Defined in
mods
mods: IDictionary
<ModType
>
Inherited from
Defined in
container
container: HTMLElement
Inherited from
Defined in
async
Readonly
async: IAsync
Inherited from
Defined in
ownerDocument
Readonly
ownerDocument: Document
Inherited from
IViewWithToolbar.ownerDocument
Defined in
od
Readonly
od: Document
Inherited from
Defined in
ownerWindow
Readonly
ownerWindow: Window
Inherited from
Defined in
ow
Readonly
ow: Window
Inherited from
Defined in
componentName
Readonly
componentName: string
Inherited from
IViewWithToolbar.componentName
Defined in
uid
Readonly
uid: string
Inherited from
Defined in
isDestructed
Readonly
isDestructed: boolean
Inherited from
Defined in
isInDestruct
Readonly
isInDestruct: boolean
Inherited from
Defined in
isReady
Readonly
isReady: boolean
Inherited from
Defined in
componentStatus
Readonly
componentStatus: ComponentStatus
Inherited from
IViewWithToolbar.componentStatus
Defined in
isView
Readonly
isView: true
Inherited from
Defined in
parent
Readonly
parent: Nullable
<IViewBased
<IViewOptions
>>
Inherited from
Defined in
id
Readonly
id: string
ID attribute for a source element, id add {id}_editor it's editor's id
Inherited from
Defined in
basePath
Readonly
basePath: string
Inherited from
Defined in
isLocked
Readonly
isLocked: boolean
Inherited from
Defined in
isFullSize
Readonly
isFullSize: boolean
Inherited from
Defined in
buffer
Readonly
buffer: IStorage
<StorageValueType
>
Inherited from
Defined in
storage
Readonly
storage: IStorage
<StorageValueType
>
Inherited from
Defined in
progressbar
Readonly
progressbar: IProgressBar
Inherited from
Defined in
events
Readonly
events: IEventEmitter
Inherited from
Defined in
e
Readonly
e: IEventEmitter
Inherited from
Defined in
create
Readonly
create: ICreate
Inherited from
Defined in
c
Readonly
c: ICreate
Inherited from
Defined in
OPTIONS
Readonly
OPTIONS: IViewOptions
Inherited from
Defined in
o
Readonly
o: Config
Inherited from
Defined in
defaultTimeout
Readonly
defaultTimeout: number
Inherited from
IViewWithToolbar.defaultTimeout
Defined in
components
Readonly
components: Set
<IComponent
<IViewBased
<IViewOptions
>>>
Inherited from
Defined in
message
Readonly
message: IMessages
Inherited from
Defined in
toolbar
toolbar: IToolbarCollection
Inherited from
Defined in
toolbarContainer
toolbarContainer: HTMLElement
Inherited from
IViewWithToolbar.toolbarContainer
Defined in
registeredButtons
registeredButtons: Set
<IPluginButton
>
Inherited from
IViewWithToolbar.registeredButtons
Defined in
getNativeEditorValue
getNativeEditorValue(): string
Returns
string
Defined in
getEditorValue
getEditorValue(removeSelectionMarkers?
, consumer?
): string
Parameters
Name | Type |
---|---|
removeSelectionMarkers? |
boolean |
consumer? |
string |
Returns
string
Defined in
setEditorValue
setEditorValue(value?
): void
Parameters
Name | Type |
---|---|
value? |
string |
Returns
void
Defined in
getElementValue
getElementValue(): string
Only getter
Returns
string
Defined in
getReadOnly
getReadOnly(): boolean
Returns
boolean
Defined in
setReadOnly
setReadOnly(enable
): void
Parameters
Name | Type |
---|---|
enable |
boolean |
Returns
void
Defined in
addPlace
addPlace(source
, options?
): void
Parameters
Name | Type |
---|---|
source |
string | HTMLElement |
options? |
IViewOptions |
Returns
void
Defined in
setCurrentPlace
setCurrentPlace(place
): void
Parameters
Name | Type |
---|---|
place |
IWorkPlace |
Returns
void
Defined in
waitForReady
waitForReady(): Promise
<IJodit
>
Returns
Defined in
getRealMode
getRealMode(): Modes
Return current real work mode. When editor in MODE_SOURCE or MODE_WYSIWYG it will
return them, but then editor in MODE_SPLIT it will return MODE_SOURCE if
Textarea(CodeMirror) focused or MODE_WYSIWYG otherwise
Returns
Example
var editor = Jodit.make('#editor');
console.log(editor.getRealMode());
Defined in
getMode
getMode(): Modes
Returns
Defined in
isEditorMode
isEditorMode(): boolean
Returns
boolean
Defined in
toggleMode
toggleMode(): void
Returns
void
Defined in
focus
focus(): void
Returns
void
Defined in
fetch
fetch<Response
>(url
, options?
): Promise
<IResponse
<Response
>>
Type parameters
Name | Type |
---|---|
Response |
extends object = any |
Parameters
Name | Type |
---|---|
url |
string |
options? |
Partial <AjaxOptions > |
Returns
Defined in
execCommand
execCommand(command
, showUI?
, value?
, ...args
): any
Parameters
Name | Type |
---|---|
command |
string |
showUI? |
any |
value? |
any |
...args |
unknown [] |
Returns
any
Defined in
nativeExecCommand
nativeExecCommand(command
, showUI?
, value?
): boolean
Parameters
Name | Type |
---|---|
command |
string |
showUI? |
any |
value? |
any |
Returns
boolean
Defined in
registerCommand
registerCommand<C
>(commandNameOriginal
, command
, options?
): IJodit
Type parameters
Name | Type |
---|---|
C |
extends string |
Parameters
Name | Type |
---|---|
commandNameOriginal |
C |
command |
CustomCommand <IJodit , C > |
options? |
Object |
options.stopPropagation |
boolean |
Returns
Defined in
registerHotkeyToCommand
registerHotkeyToCommand(hotkeys
, commandName
, shouldStop?
): void
Parameters
Name | Type |
---|---|
hotkeys |
string | string [] |
commandName |
string |
shouldStop? |
boolean |
Returns
void
Defined in
setMod
setMod<T
>(this
, name
, value
): T
Set/remove modification (null - remove)
Type parameters
Name | Type |
---|---|
T |
extends IComponent <IViewBased <IViewOptions >> & IContainer & IMods |
Parameters
Name | Type |
---|---|
this |
T |
name |
string |
value |
ModType |
Returns
T
Inherited from
Defined in
afterSetMod
afterSetMod(name
, value
): void
Parameters
Name | Type |
---|---|
name |
string |
value |
ModType |
Returns
void
Inherited from
Defined in
getMod
getMod(name
): ModType
Parameters
Name | Type |
---|---|
name |
string |
Returns
Inherited from
Defined in
getElm
getElm(elementName
): Nullable
<HTMLElement
>
Parameters
Name | Type |
---|---|
elementName |
string |
Returns
Inherited from
Defined in
getElms
getElms(elementName
): HTMLElement
[]
Parameters
Name | Type |
---|---|
elementName |
string |
Returns
Inherited from
Defined in
dlg
dlg(options?
): IDialog
Parameters
Name | Type |
---|---|
options? |
IDialogOptions |
Returns
Inherited from
Defined in
confirm
confirm(msg
, title
, callback?
): IDialog
Parameters
Name | Type |
---|---|
msg |
string |
title |
undefined | string | (yes : boolean ) => void |
callback? |
(yes : boolean ) => false | void |
Returns
Inherited from
Defined in
prompt
prompt(msg
, title
, callback
, placeholder?
, defaultValue?
): IDialog
Parameters
Name | Type |
---|---|
msg |
string |
title |
undefined | string | () => false | void |
callback |
(value : string ) => false | void |
placeholder? |
string |
defaultValue? |
string |
Returns
Inherited from
Defined in
alert
alert(msg
, title?
, callback?
, className?
): IDialog
Parameters
Name | Type |
---|---|
msg |
string | HTMLElement |
title? |
string | () => false | void |
callback? |
string | (dialog : IDialog ) => false | void |
className? |
string |
Returns
Inherited from
Defined in
destruct
destruct(jodit?
): any
Parameters
Name | Type |
---|---|
jodit? |
IViewBased <IViewOptions > |
Returns
any
Inherited from
Defined in
get
get<T
>(chain
, obj?
): Nullable
<T
>
Type parameters
Name |
---|
T |
Parameters
Name | Type |
---|---|
chain |
string |
obj? |
IDictionary <any , string > |
Returns
Nullable
<T
>
Inherited from
Defined in
className
className(): string
Returns
string
Inherited from
Defined in
getFullElName
getFullElName(elementName
): string
Parameters
Name | Type |
---|---|
elementName |
string |
Returns
string
Inherited from
IViewWithToolbar.getFullElName
Defined in
getFullElName(elementName
, mod
): string
Parameters
Name | Type |
---|---|
elementName |
string |
mod |
string |
Returns
string
Inherited from
IViewWithToolbar.getFullElName
Defined in
getFullElName(elementName
, mod?
, modValue?
): string
Parameters
Name | Type |
---|---|
elementName |
string |
mod? |
string |
modValue? |
string | boolean |
Returns
string
Inherited from
IViewWithToolbar.getFullElName
Defined in
setStatus
setStatus(componentStatus
): void
Parameters
Name | Type |
---|---|
componentStatus |
ComponentStatus |
Returns
void
Inherited from
Defined in
hookStatus
hookStatus(status
, callback
): void
Parameters
Name | Type |
---|---|
status |
ComponentStatus |
callback |
(component : this ) => void |
Returns
void
Inherited from
Defined in
bindDestruct
bindDestruct(component
): this
Parameters
Name | Type |
---|---|
component |
IComponent <IViewBased <IViewOptions >> |
Returns
this
Inherited from
Defined in
isLockedNotBy
isLockedNotBy(name
): boolean
Parameters
Name | Type |
---|---|
name |
string |
Returns
boolean
Inherited from
IViewWithToolbar.isLockedNotBy
Defined in
lock
lock(name?
): boolean
Parameters
Name | Type |
---|---|
name? |
string |
Returns
boolean
Inherited from
Defined in
unlock
unlock(): boolean
Returns
boolean
Inherited from
Defined in
toggleFullSize
toggleFullSize(isFullSize?
): void
Parameters
Name | Type |
---|---|
isFullSize? |
boolean |
Returns
void
Inherited from
IViewWithToolbar.toggleFullSize
Defined in
i18n
i18n(text
, ...params
): string
Parameters
Name | Type |
---|---|
text |
string |
...params |
(string | number )[] |
Returns
string
Inherited from
Defined in
getVersion
getVersion(): string
Returns
string
Inherited from
Defined in
getInstance
getInstance<T
>(module
, options?
): T
Type parameters
Name | Type |
---|---|
T |
extends IComponent <IViewBased <IViewOptions >> |
Parameters
Name | Type |
---|---|
module |
Function |
options? |
object |
Returns
T
Inherited from
Defined in
getInstance<T
>(moduleName
, options?
): T
Type parameters
Name | Type |
---|---|
T |
extends IComponent <IViewBased <IViewOptions >> |
Parameters
Name | Type |
---|---|
moduleName |
string |
options? |
object |
Returns
T
Inherited from
Defined in
registerButton
registerButton(btn
): this
Parameters
Name | Type |
---|---|
btn |
IPluginButton |
Returns
this
Inherited from
IViewWithToolbar.registerButton
Defined in
unregisterButton
unregisterButton(btn
): this
Parameters
Name | Type |
---|---|
btn |
IPluginButton |
Returns
this
Inherited from
IViewWithToolbar.unregisterButton
Defined in
getRegisteredButtonGroups
getRegisteredButtonGroups(): IDictionary
<string
[]>
Returns
IDictionary
<string
[]>
Inherited from
IViewWithToolbar.getRegisteredButtonGroups
Defined in
setPanel
setPanel(element
): void
Parameters
Name | Type |
---|---|
element |
string | HTMLElement |
Returns
void
Inherited from
Defined in
jodit/src/types/view.d.ts:164