logo

/repo|v3.10.0

Class

new Ui(element, options, actions)ui.jsline 48

Default UI Class

PARAMETERS
NameTypeDescription

element

stringHTMLElement

Wrapper's element or selector

options

[ Object ]

Ui setting options

PROPERTIES
NameTypeDescription

loadImage

number

Init default load image

initMenu

number

Init start menu

menuBarPosition

Boolean = bottom

Let

applyCropSelectionStyle

Boolean = false

Let

usageStatistics

Boolean = false

Use statistics or not

uiSize

[ Object ]

ui size of editor

PROPERTIES
NameTypeDescription

width

string

width of ui

height

string

height of ui

actions

Object

ui action instance

Instance Methods

destroy()ui.jsline 75

Destroys the instance.

resizeEditor(resizeInfo)ui.jsline 126

Change editor size

PARAMETERS
NameTypeDescription

resizeInfo

Object = {}

ui & image size info

PROPERTIES
NameTypeDescription

uiSize

[ Object ]

image size dimension

PROPERTIES
NameTypeDescription

width

string

ui width

height

string

ui height

imageSize

[ Object ] = this.imageSize

image size dimension

PROPERTIES
NameTypeDescription

oldWidth

Number

old width

oldHeight

Number

old height

newWidth

Number

new width

newHeight

Number

new height

EXAMPLES
// Change the image size and ui size, and change the affected ui state together.
imageEditor.ui.resizeEditor({
    imageSize: {oldWidth: 100, oldHeight: 100, newWidth: 700, newHeight: 700},
    uiSize: {width: 1000, height: 1000}
});
// Apply the ui state while preserving the previous attribute (for example, if responsive UI)
imageEditor.ui.resizeEditor();
Resizable