1.0.48 • Published 6 years ago

@singleware/ui-editor v1.0.48

Weekly downloads
12
License
MIT
Repository
github
Last release
6 years ago

UI-Editor

Custom HTML element to be used as a WYSIWYG editor, this custom element provides a simple way to edit rich texts using the latest browser technologies.

State Attributes

NameDescription
emptyAutomatically assigned when there is content into the editor
invalidAutomatically assigned when the editor content is required but there is no content

Properties

NameDescription
emptyGet the empty state from the editor
nameGet and set the editor name
valueGet and set the editor content
defaultValueGet and set tje editor default value
requiredGet and set the required state
readOnlyGet and set the readOnly state
disabledGet and set the disabled state
preserveSelectionGet and set the preserve selection state.
paragraphTypeGet and set the paragraph tag name
deniedTagsGet and set the denied tag list
orientationGet and set the editor orientation mode. Use: row or column value
selectedRangeGet the current selection range
selectedTextGet the current selection text
selectedHTMLGet the current selection HTML
selectedStylesGet the current selection styles

Methods

NameDescription
setRemovalStateChange the removal state of an element.
setRenderingStateChange the rendering state of an element.
clearSelectionRemoves any active selection in the editor content
focusMove the focus to the content child into the editor
resetReset the content child into the editor to its initial value
checkValidityCheck whether the editor content is valid
formatActionFormats the specified tag for the selection or insertion point
fontNameActionChange the font name for the selection or at the insertion point
fontSizeActionChange the font size for the selection or at the insertion point
fontColorActionChange the font color for the selection or at the insertion point
lineHeightActionChange line height for the selection or at the insertion point
undoActionUndoes the last executed command
redoActionRedoes the previous undo command
boldActionToggles bold on/off for the selection or at the insertion point
italicActionToggles italics on/off for the selection or at the insertion point
underlineActionToggles underline on/off for the selection or at the insertion point
strikeThroughActionToggles strikeThrough on/off for the selection or at the insertion point
unorderedListActionCreates a bulleted unordered list for the selection or at the insertion point
orderedListActionCreates a numbered ordered list for the selection or at the insertion point
alignLeftActionJustifies the selection or insertion point to the left
alignCenterActionJustifies the selection or insertion point to the center
alignRightActionJustifies the selection or insertion point to the right
alignJustifyActionJustifies the selection or insertion point
outdentActionOutdents the line containing the selection or insertion point
indentActionIndents the line containing the selection or insertion point
cutActionRemoves the current selection and copies it to the clipboard
copyActionCopies the current selection to the clipboard
pasteActionPastes the clipboard contents at the insertion point

Slots

NameDescription
toolbarElement to contain all toolbar controls
contentElement to contain all editor data (rich text, html, etc)

Events

NameDescription
changeDispatched when the content into the editor is changed

Install

Using npm:

npm i @singleware/ui-editor

License

MIT © Silas B. Domingos

1.0.48

6 years ago

1.0.47

6 years ago

1.0.46

6 years ago

1.0.45

6 years ago

1.0.44

6 years ago

1.0.43

6 years ago

1.0.42

6 years ago

1.0.41

6 years ago

1.0.40

6 years ago

1.0.39

6 years ago

1.0.38

6 years ago

1.0.37

6 years ago

1.0.36

6 years ago

1.0.35

6 years ago

1.0.34

6 years ago

1.0.32

6 years ago

1.0.31

6 years ago

1.0.30

6 years ago

1.0.29

6 years ago

1.0.28

6 years ago

1.0.27

6 years ago

1.0.26

6 years ago

1.0.25

6 years ago

1.0.23

6 years ago

1.0.22

6 years ago

1.0.21

6 years ago

1.0.20

7 years ago

1.0.19

7 years ago

1.0.18

7 years ago

1.0.17

7 years ago

1.0.16

7 years ago

1.0.15

7 years ago

1.0.14

7 years ago

1.0.13

7 years ago

1.0.12

7 years ago

1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

7 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago