Represents react Document Editor Component
<DocumentEditorComponent></DocumentEditorComponent>
boolean
Gets or sets a value indicating whether tab key can be accepted as input or not.
Defaults to false
boolean
Gets or sets a value indicating whether to start automatic resize with the specified time interval and iteration count.
- Resize action triggers automatically for the specified number of iterations, or till the parent element’s height and width is non-zero.
- If the parent element’s height and width is zero even in the last iteration, then the default height and width (200) is allocated for the Document editor.
Defaults to false
EmitType<XmlHttpRequestEventArgs>
Triggers before a server request is started, allows you to modify the XMLHttpRequest object (setting additional headers, if needed).
Gets or sets the Collaborative editing module.
Gets or sets the Collaborative editing module.
Gets the context menu object of the document editor.
string
Gets or sets the current user.
Defaults to ”
Gets or sets the default Paste Formatting Options
Defaults to KeepSourceFormatting
Defines the settings for DocumentEditor customization.
Defaults to {}
EmitType<DocumentLoadFailedEventArgs>
Triggers when SFDT is failed to load in the document editor
string
Gets or sets the name of the document.
Defaults to ”
Gets the settings and properties of the document that is opened in Document editor component.
Defaults to {}
Gets the editor object of the document editor.
Gets the editor history object of the document editor.
boolean
Gets or sets a value indicating whether the automatic focus behavior is enabled for Document editor or not.
By default, the Document editor gets focused automatically when the page loads. If you want the Document editor not to be focused automatically, then set this property to false.
Defaults to true
boolean
Gets or sets a value indicating whether bookmark dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether borders and shading dialog is enabled or not.
Defaults to false
boolean
Enable collaborative editing in document editor.
Defaults to false
boolean
Gets or sets a value indicating whether margin dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether comment is enabled or not
Defaults to false
boolean
Gets or sets a value indicating whether context menu is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether to enable cursor in document editor on read only state or not. The default value is false.
Defaults to false
boolean
Gets or sets a value indicating whether editor needs to be enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether editor history needs to be enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether font dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether notes dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether form fields is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether hyperlink dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether image resizer is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether list dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether local paste needs to be enabled or not.
Defaults to false
boolean
Enables the partial lock and edit module.
Defaults to false
boolean
Gets or sets a value indicating whether options pane is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether font dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether paragraph dialog is enabled or not.
Defaults to false
boolean
Enable or disable persisting component’s state between page reloads.
Defaults to false
boolean
Gets or sets a value indicating whether print needs to be enabled or not.
Defaults to false
boolean
Enable or disable rendering component in right to left direction.
Defaults to false
boolean
Gets or sets a value indicating whether search module is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether selection needs to be enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether Sfdt export needs to be enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether editor need to be spell checked.
Defaults to false
boolean
Gets or sets a value indicating whether font dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether table dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether table of contents dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether table options dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether table properties dialog is enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether text export needs to be enabled or not.
Defaults to false
boolean
Gets or sets a value indicating whether track changes is enabled or not
Defaults to false
boolean
Gets or sets a value indicating whether word export needs to be enabled or not.
Defaults to false
object[]
Adds the custom headers to XMLHttpRequest.
Defaults to []
string
Defines the height of the DocumentEditor component.
Defaults to ‘200px’
boolean
Describes whether Document contains any content or not
Defaults to false
boolean
Gets or sets a value indicating whether the document editor is in read only state or not.
Defaults to true
Gets or sets the Layout Type.
Defaults to Pages
string
Overrides the global culture and localization value for this component. Default global culture is ‘en-US’.
Defaults to ”
number
Gets the total number of pages.
number
Gets or sets the page gap value in document editor.
Defaults to 20
string
Gets or sets the page outline color.
Defaults to ‘#000000’
Gets the revision collection which contains information about changes made from original document
Gets the search object of the document editor.
Gets the selection object of the document editor.
Defaults to undefined
Defines the settings of the DocumentEditor services
string
Gets or sets the Sfdt Service URL.
Defaults to ”
boolean
Shows the comment in the document.
Defaults to false
boolean
Shows the revision changes in the document.
Defaults to false
Gets the spell check dialog object of the document editor.
Gets the spell check object of the document editor.
boolean
Gets or sets a value indicating whether holding Ctrl key is required to follow hyperlink on click. The default value is true.
Defaults to true
string
Gets or sets the color used for highlighting the editable ranges or regions of the currentUser
in Document Editor. The default value is “#FFFF00”.
If the visibility of text affected due this highlight color matching with random color applied for the track changes, then modify the color value of this property to resolve text visibility problem.
Defaults to ‘#FFFF00’
string
Defines the width of the DocumentEditor component.
Defaults to ‘100%’
number
Specifies the z-order for rendering that determines whether the dialog is displayed in front or behind of another component.
Defaults to 2000
number
Gets or sets the zoom factor in document editor.
Defaults to 1
Destroys all managed resources used by this object.
Returns void
Enables all the modules.
Returns void
Exports the specified page as image.
Parameter | Type | Description |
---|---|---|
pageNumber | number |
Specifies the page number starts from index 1 . |
format | ImageFormat |
Specifies the image format. |
Returns HTMLImageElement
Exports the content control values.
Returns ContentControlInfo[]
Exports the form field values.
Returns FormFieldData[]
Fits the page based on given fit type.
Parameter | Type | Description |
---|---|---|
pageFitType (optional) | PageFitType |
The default value of ‘pageFitType’ parameter is ‘None’ |
Returns void
Shifts the focus to the document.
Returns void
Gets the bookmarks.
Returns string[]
Gets the entire document’s comment information.
Returns CommentInfo[]
Gets the form field by name
Parameter | Type | Description |
---|---|---|
name | string |
The form field name. |
Returns TextFormFieldInfo | CheckBoxFormFieldInfo | DropDownFormFieldInfo
Gets all the form field names in current document.
Returns string[]
Gets the style names based on given style type.
Parameter | Type | Description |
---|---|---|
styleType (optional) | StyleType |
Specifies the style type. |
Returns string[]
Gets the style objects on given style type.
Parameter | Type | Description |
---|---|---|
styleType (optional) | StyleType |
Specifies the style type. |
Returns Object[]
Imports content control data and returns the processed content control information.
Parameter | Type | Description |
---|---|---|
contentControlInfo | ContentControlInfo[] |
The array of content control information to be imported. |
Returns ContentControlInfo[]
Imports the form field values.
Parameter | Type | Description |
---|---|---|
formData | FormFieldData[] |
Specifies the form field values. |
Returns void
Opens the given sfdt text or base 64 string or url.
Returns void
Opens the given sfdt text or base 64 string or url.
Returns void
Opens a blank document.
Returns void
Prints the document.
Parameter | Type | Description |
---|---|---|
printWindow (optional) | Window |
Default value of ‘printWindow’ parameter is undefined. |
Returns void
Resets the content control data.
Parameter | Type | Description |
---|---|---|
contentControInfo | ContentControlInfo[] |
The array of content control information to be reset. |
Returns void
Resets the form field value to default with the specified form field name.
Parameter | Type | Description |
---|---|---|
name (optional) | string |
Specifies the form field name |
Returns void
Resizes the component and its sub elements based on given size or container size.
Parameter | Type | Description |
---|---|---|
width (optional) | number |
Specifies the width |
height (optional) | number |
Specifies the hight |
Returns void
Saves the document.
Parameter | Type | Description |
---|---|---|
fileName | string |
Specifies the file name. |
formatType (optional) | FormatType |
Specifies the format type. |
Returns void
Saves the document as blob.
Parameter | Type | Description |
---|---|---|
formatType (optional) | FormatType |
Specifies the format type. |
Returns Promise
Scrolls view to start of the given page number if exists.
Parameter | Type | Description |
---|---|---|
pageNumber | number |
Specifies the page number. |
Returns boolean
Serializes the data to JSON string.
Returns string
Sets custom fonts in the document editor.
Parameter | Type | Description |
---|---|---|
fonts | string | object[] |
A stringified JSON array or an array of objects, where each object defines: - fontFamily : The name of the font family.- src : A URL or relative path pointing to the font file.Example usage: // Using a stringified JSON array documentEditor.setCustomFonts(’[{fontFamily: “Algerian”, src: “url(‘/fonts/myfont.ttf’) format(‘ttf’)”}, {fontFamily: “Arial”, src: “url(‘https://example.com/font2.ttf’) format(‘ttf’)”}, {fontFamily: “Arial”, src: “url(‘data:font/ttf;base64,d09GRgABAAAAAA…’) format(‘ttf’)“}]’); // Using an array of objects documentEditor.setCustomFonts([ {fontFamily: “Algerian”, src: “url(‘/fonts/myfont.ttf’) format(‘ttf’)”}, {fontFamily: “Arial”, src: “url(‘https://example.com/font2.ttf’) format(‘ttf’)”}, {fontFamily: “Arial”, src: “url(‘data:font/ttf;base64,d09GRgABAAAAAA…’) format(‘ttf’)“} ]); |
Returns void
Sets the default character format for document editor
Parameter | Type | Description |
---|---|---|
characterFormat | CharacterFormatProperties |
Specifies the character format. |
Returns void
Sets the default paragraph format for document editor
Parameter | Type | Description |
---|---|---|
paragraphFormat | ParagraphFormatProperties |
Specifies the paragraph format. |
Returns void
Sets the default section format for document editor
Parameter | Type | Description |
---|---|---|
sectionFormat | SectionFormatProperties |
Specifies the section format. |
Returns void
Sets the form field info with the specified name.
Parameter | Type | Description |
---|---|---|
name | string |
Specifies the form field name |
formFieldInfo | TextFormFieldInfo | CheckBoxFormFieldInfo | DropDownFormFieldInfo |
Form Field info. |
Returns void
Shows the dialog.
Parameter | Type | Description |
---|---|---|
dialogType | DialogType |
Specifies the dialog type. |
Returns void
Shows the options pane.
Returns void
Shows the restrict editing pane.
Parameter | Type | Description |
---|---|---|
show (optional) | boolean |
Specifies to show or hide restrict editing pane. |
Returns void
Shows the Xml pane.
Returns void
Updates the fields in the current document. Currently cross reference field only supported.
Returns void
EmitType<CollaborativeEditingEventArgs>
Triggers when the document editor collaborative actions (such as LockContent, SaveContent, UnlockContent) gets completed.
EmitType<FormFieldFillEventArgs>
Triggers after the form field fill.
EmitType<RevisionActionEventArgs>
Triggers before accepting or rejecting changes.
EmitType<CommentActionEventArgs>
Triggers on comment actions(Post, edit, reply, resolve, reopen).
Triggers before a file is opened.
EmitType<FormFieldFillEventArgs>
Triggers before the form field fill.
EmitType<BeforePaneSwitchEventArgs>
Triggers before opening the comment pane.
EmitType<Object>
Triggers after inserting the comment.
EmitType<CommentDeleteEventArgs>
Triggers after deleting the comment.
EmitType<Object>
Triggers after posting the comment.
EmitType<ContentChangeEventArgs>
Triggers whenever the content changes in the document editor.
EmitType<Object>
Triggers when user interaction prevented in content control.
EmitType<Object>
Triggers when the component is created.
EmitType<BeforeOpenCloseCustomContentMenuEventArgs>
Triggers before opening the custom context-menu option.
EmitType<CustomContentMenuEventArgs>
Triggers while selecting the custom context-menu option.
EmitType<Object>
Triggers when the component is destroyed.
EmitType<DocumentChangeEventArgs>
Triggers whenever the document changes in the document editor.
EmitType<DocumentEditorKeyDownEventArgs>
Triggers whenever the key is pressed in the document editor.
EmitType<RequestNavigateEventArgs>
Triggers whenever the hyperlink is clicked or tapped in the document editor.
EmitType<SearchResultsChangeEventArgs>
Triggers whenever search results changes in the document editor.
EmitType<SelectionChangeEventArgs>
Triggers whenever the selection changes in the document editor.
Triggers when the server side action fails.
EmitType<TrackChangeEventArgs>
Triggers when the trackChanges enabled / disabled.
Triggers whenever the container view changes in the document editor.
EmitType<ZoomFactorChangeEventArgs>
Triggers whenever the zoom factor changes in the document editor.