Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/JiHong88/suneditor
/ functions
Functions
1,891 in github.com/JiHong88/suneditor
⨍
Functions
1,891
◇
Types & classes
460
↓ 1 callers
Function
buildMockMain
* Build a default mockMain with all dependencies in place. * Individual tests may override specific sub-properties after calling this.
test/unit/plugins/modal/image/services/image.upload.spec.js:30
↓ 1 callers
Function
check
()
test/__mocks__/editorIntegration.js:214
↓ 1 callers
Function
collectRows
(parent, isHead)
src/helper/markdown.js:198
↓ 1 callers
Method
colorPickerHueSliderClose
* @optional * Executes the method called when the `HueSlider` module is closed. * @returns {void}
types/interfaces/contracts.d.ts:116
↓ 1 callers
Method
colorPickerHueSliderOpen
* @optional * Executes the method called when the `HueSlider` module is opened. * @returns {void}
types/interfaces/contracts.d.ts:110
↓ 1 callers
Method
componentDestroy
* @hook Editor.Component * @type {SunEditor.Hook.Component.Destroy}
src/plugins/modal/audio.js:250
↓ 1 callers
Method
componentDestroy
* @hook Editor.Component * @type {SunEditor.Hook.Component.Destroy}
src/plugins/modal/math.js:309
↓ 1 callers
Method
componentDestroy
* @hook Editor.Component * @type {SunEditor.Hook.Component.Destroy}
src/plugins/dropdown/table/index.js:208
↓ 1 callers
Method
componentSelect
* @hook Editor.Component * @type {SunEditor.Hook.Component.Select}
src/plugins/popup/anchor.js:67
↓ 1 callers
Method
componentSelect
* @hook Editor.Component * @type {SunEditor.Hook.Component.Select}
src/plugins/modal/image/index.js:321
↓ 1 callers
Method
containerOn
* @description Opens the menu container for the specified button. * @param {Node} button Container's button element to call
src/core/logic/panel/menu.js:201
↓ 1 callers
Method
controllerOn
* @optional * This function is called after the `controller` is opened. * @param {HTMLFormElement} form Controller form element * @param {Node|R
types/interfaces/contracts.d.ts:69
↓ 1 callers
Function
convertClassToInterface
* Converts "class" to "interface" in .d.ts content * NOTE: Only converts contracts.d.ts - plugin.d.ts must remain as class (for extends) * @param {s
scripts/ts-build/interfaces-convert.cjs:92
↓ 1 callers
Method
copy
* @description Copies the specified component node to the clipboard. * - This function is different from the one called when the user presses the `C
src/core/logic/shell/component.js:459
↓ 1 callers
Method
copyFormat
()
src/core/logic/shell/_commandExecutor.js:155
↓ 1 callers
Function
copyTagAttributes
(originEl, copyEl, blacklist)
src/helper/dom/domUtils.js:235
↓ 1 callers
Function
createElement
(elementName, attributes, inner)
src/helper/dom/domUtils.js:76
↓ 1 callers
Function
createMockClipboardData
(customProps = {})
test/__mocks__/editorMock.js:1375
↓ 1 callers
Function
createMockCommandTargets
* Creates mock command targets
test/__mocks__/editorMock.js:496
↓ 1 callers
Function
createMockDOM
* Creates a mock DOM structure for testing
test/__mocks__/editorMock.js:11
↓ 1 callers
Function
createMockDeps
* Creates a mock $ deps bag for ColorPicker
test/unit/modules/ColorPicker.spec.js:97
↓ 1 callers
Function
createMockFrameContext
* Creates a mock frame context
test/__mocks__/editorMock.js:112
↓ 1 callers
Function
createMockFrameRoots
* Creates a mock frame roots map
test/__mocks__/editorMock.js:152
↓ 1 callers
Function
createMockInst
* Creates a minimal mock inst (EventManager-like instance) with all kernel modules * needed by makePorts.
test/unit/core/event/ports.spec.js:26
↓ 1 callers
Function
createMockKeyboardEvent
(key = 'a', customProps = {})
test/__mocks__/editorMock.js:1392
↓ 1 callers
Function
createMockMouseEvent
(type = 'click', customProps = {})
test/__mocks__/editorMock.js:1425
↓ 1 callers
Function
createMockOptions
* Creates mock options
test/__mocks__/editorMock.js:159
↓ 1 callers
Function
createMockPlugins
* Creates mock plugins
test/__mocks__/editorMock.js:314
↓ 1 callers
Function
createRealElement
(tagName, attrs, html)
test/unit/modules/Browser.spec.js:10
↓ 1 callers
Function
createTestDOM
* Creates a minimal DOM structure for editor testing
test/__mocks__/editorIntegration.js:11
↓ 1 callers
Function
createTextNode
(text)
src/helper/dom/domUtils.js:101
↓ 1 callers
Function
createUIKernel
* Helper: creates a minimal mock kernel with real DOM elements so that * `new UIManager(kernel)` can be constructed without errors. * The returned o
test/unit/core/logic/shell/ui.spec.js:13
↓ 1 callers
Method
customMethod
()
test/unit/core/kernel/kernelInjector.spec.js:231
↓ 1 callers
Function
debounce
(func, wait)
src/helper/converter.js:148
↓ 1 callers
Method
doSomething
()
test/unit/core/kernel/kernelInjector.spec.js:133
↓ 1 callers
Function
drawColorWheelToContext
(context)
src/modules/contract/HueSlider.js:465
↓ 1 callers
Function
drawWheelGradient
()
src/modules/contract/HueSlider.js:456
↓ 1 callers
Function
escapeHtml
* @description Escape HTML special characters * @param {string} str * @returns {string}
src/helper/markdown.js:882
↓ 1 callers
Method
execute
* @description Execute default command of command button
src/core/logic/shell/_commandExecutor.js:61
↓ 1 callers
Method
execute
* @description Executes the default `line` creation logic. * - If no `formatName` is provided, it uses the `defaultLine` option (usually `P`). * -
src/core/event/support/defaultLineManager.js:26
↓ 1 callers
Function
extractCommandButtons
* Extract command button names from _defaultButtons function in constructor.js * @returns {string[]} Array of command button names
scripts/check/gen-button-types.cjs:40
↓ 1 callers
Function
extractLangKeys
* Extract lang object from en.js source file
scripts/ts-build/fix-langs.cjs:13
↓ 1 callers
Function
extractPluginNames
* Extract plugin names from plugins/index.js export statement * @returns {string[]} Array of plugin names
scripts/check/gen-button-types.cjs:12
↓ 1 callers
Method
findMergedCells
* @description Find merged cells * @param {HTMLTableCellElement[]} cells - Cells array
src/plugins/dropdown/table/services/table.cell.js:241
↓ 1 callers
Function
findPluginOptions
* Find all plugin option types from plugin files * @returns {Array<{name: string, typeName: string, relativePath: string}>}
scripts/check/inject-plugin-jsdoc.cjs:12
↓ 1 callers
Function
func
()
test/unit/helper/converter.spec.js:167
↓ 1 callers
Function
getCacheKey
* @param {HTMLTableCellElement} startCell * @param {HTMLTableCellElement} endCell * @returns {string}
src/plugins/dropdown/table/services/table.selection.js:9
↓ 1 callers
Method
getDeps
()
test/unit/core/kernel/kernelInjector.spec.js:245
↓ 1 callers
Method
getFormat
()
test/unit/core/kernel/kernelInjector.spec.js:164
↓ 1 callers
Method
getHistory
()
test/unit/core/kernel/kernelInjector.spec.js:172
↓ 1 callers
Method
getInputSize
* @description Gets the current width and height input values. * @returns {{w: string, h: string}}
src/plugins/modal/video/services/video.size.js:79
↓ 1 callers
Method
getJson
* @description Gets the current content to JSON data * @param {Object} [options] Options * @param {boolean} [options.withFrame=false] Gets the cur
src/core/logic/dom/html.js:1243
↓ 1 callers
Function
getListChildNodes
(element, validation, depth)
src/helper/dom/domQuery.js:178
↓ 1 callers
Function
getOptionalMembers
* Reads the original .js source file and extracts member names marked with @optional * @param {string} dtsFilePath - Path to the .d.ts file * @retur
scripts/ts-build/interfaces-convert.cjs:34
↓ 1 callers
Function
getType
(element)
src/plugins/modal/math.js:563
↓ 1 callers
Function
getTypedefImportPath
* Calculate relative path from source file to typedef.d.ts * @param {string} filePath - Path to the .d.ts file * @returns {string} - Relative import
scripts/ts-build/inject-typedef-import.cjs:12
↓ 1 callers
Function
googleTranslate
(text, from, to)
scripts/check/langs-sync.cjs:17
↓ 1 callers
Function
hasCorrectTypedefImport
* Check if file already has correct typedef import * @param {string} content - File content * @param {string} expectedPath - Expected import path *
scripts/ts-build/inject-typedef-import.cjs:30
↓ 1 callers
Function
hslToRgb
([h, s, l])
src/modules/contract/HueSlider.js:530
↓ 1 callers
Method
init
* @description Resets the ModalAnchorEditor to its initial state.
src/modules/ui/ModalAnchorEditor.js:246
↓ 1 callers
Method
init
* @description Initializes the size service state.
src/plugins/modal/video/services/video.size.js:181
↓ 1 callers
Function
injectKeys
(filePath, langCode, baseLangObj)
scripts/check/langs-sync.cjs:50
↓ 1 callers
Function
injectTypedefImport
()
scripts/ts-build/inject-typedef-import.cjs:45
↓ 1 callers
Method
insert
* @description Inserts an element and returns it. (Used for elements: table, hr, image, video) * - If `element` is `HR`, inserts and returns the new
src/core/logic/shell/component.js:126
↓ 1 callers
Function
isBreak
(node)
src/helper/dom/domCheck.js:132
↓ 1 callers
Function
isEmptyLine
(node)
src/helper/dom/domCheck.js:186
↓ 1 callers
Function
isHexColor
(str)
src/helper/converter.js:341
↓ 1 callers
Function
isImportantDisabled
(node)
src/helper/dom/domCheck.js:297
↓ 1 callers
Function
isTableCell
(node)
src/helper/dom/domCheck.js:114
↓ 1 callers
Function
main
* Main execution
scripts/check/gen-button-types.cjs:120
↓ 1 callers
Function
makeDeps
Creates the `$` (deps) argument for the ApiManager constructor.
test/unit/modules/ApiManager.spec.js:56
↓ 1 callers
Function
makeMethodsOptional
* Converts class members to optional in .d.ts content * @param {string} content - The .d.ts file content * @param {Set<string>} optionalMembers - Se
scripts/ts-build/interfaces-convert.cjs:70
↓ 1 callers
Function
mockCreateModalForm
()
test/unit/plugins/modal/drawing.spec.js:8
↓ 1 callers
Function
mockCreateXhr
()
test/unit/modules/ApiManager.spec.js:13
↓ 1 callers
Function
mockScroll
(el, props)
test/unit/core/logic/dom/offset.numerical.spec.js:146
↓ 1 callers
Method
modalInit
* @hook Modules.Modal * @type {SunEditor.Hook.Modal.Init}
src/plugins/modal/audio.js:206
↓ 1 callers
Method
modalInit
* @hook Modules.Modal * @type {SunEditor.Hook.Modal.Init}
src/plugins/modal/embed.js:375
↓ 1 callers
Method
modalInit
* @hook Modules.Modal * @type {SunEditor.Hook.Modal.Init}
src/plugins/modal/math.js:261
↓ 1 callers
Method
modalInit
* @hook Modules.Modal * @type {SunEditor.Hook.Modal.Init}
src/plugins/modal/image/index.js:293
↓ 1 callers
Method
modalInit
* @hook Modules.Modal * @type {SunEditor.Hook.Modal.Init}
src/plugins/modal/video/index.js:345
↓ 1 callers
Method
modalResize
* @optional * Modal resize callback (optional). * @returns {void}
types/interfaces/contracts.d.ts:47
↓ 1 callers
Method
on
* @impl Dropdown * @type {PluginDropdown['on']}
src/plugins/command/codeBlock.js:186
↓ 1 callers
Method
on
* @description Called when the modal is opened. Initializes inputs and ratio options. * @param {boolean} isUpdate - Indicates whether the modal is f
src/plugins/modal/video/services/video.size.js:142
↓ 1 callers
Method
onKeyUp
* @hook Editor.EventManager * @type {SunEditor.Hook.Event.OnKeyUp}
src/plugins/dropdown/table/index.js:548
↓ 1 callers
Method
onPaste
* @hook Editor.EventManager * @type {SunEditor.Hook.Event.OnPaste}
src/plugins/dropdown/table/index.js:247
↓ 1 callers
Method
onScroll
* @hook Editor.EventManager * @type {SunEditor.Hook.Event.OnScroll}
src/plugins/dropdown/table/index.js:562
↓ 1 callers
Function
parseCdnBuilder
* Parse window.SUNEDITOR properties from cdn-builder.js * Looks for: value: { ...suneditor, plugins, modules, helper, interfaces }
scripts/check/check-exports-sync.cjs:40
↓ 1 callers
Function
parseFormatIndex
* Parse exports from format-index.cjs generated output * Looks for: defaultExportModules array and other export patterns
scripts/check/check-exports-sync.cjs:59
↓ 1 callers
Function
parseSuneditor
* Parse named exports from suneditor.js * Looks for: export { plugins, modules, helper, langs, interfaces };
scripts/check/check-exports-sync.cjs:30
↓ 1 callers
Function
processInterfaces
()
scripts/ts-build/interfaces-convert.cjs:108
↓ 1 callers
Function
processTypedef
* Process typedef.d.ts
scripts/ts-build/wrap-dts.cjs:9
↓ 1 callers
Method
ready
* @description Prepares the size inputs and options when a video component is selected. * @param {import('../../../../modules/contract/Figure').Figu
src/plugins/modal/video/services/video.size.js:162
↓ 1 callers
Function
refreshRoots
* @description Clears future history and reinitializes deleted roots. * @param {Object} root Root stack object.
src/core/logic/shell/history.js:173
↓ 1 callers
Function
removeTypedefImport
* Remove any existing typedef import (correct or incorrect) * @param {string} content - File content * @returns {string} - Content without typedef i
scripts/ts-build/inject-typedef-import.cjs:41
↓ 1 callers
Method
reset
* @description Add or reset option property (Editor is reloaded) * @param {SunEditor.InitOptions} newOptions Options
src/core/config/optionProvider.js:108
↓ 1 callers
Method
reset
* @description Resets the toolbar state. * - Deactivates all buttons and clears the effect. * - Equivalent to calling `setKeyEffect([])`.
src/core/event/support/selectionState.js:162
↓ 1 callers
Method
resetFrame
* @description Add or reset frame option property (Editor is reloaded) * @param {SunEditor.FrameOptions} newOptions Options
src/core/config/optionProvider.js:304
↓ 1 callers
Function
resetRoot
* @description Resets a root frame's history stack. * @param {*} rootKey Root frame key.
src/core/logic/shell/history.js:147
↓ 1 callers
Function
rgbToHex
({ r, g, b })
src/modules/contract/HueSlider.js:559
↓ 1 callers
Function
rgbToHsl
([r, g, b])
src/modules/contract/HueSlider.js:496
← previous
next →
1,001–1,100 of 1,891, ranked by callers