Welcome to the Angular feedback portal. We’re happy you’re here! If you have feedback on how to improve the Angular, we’d love to hear it!

  • Check out the features or bugs others have reported and vote on your favorites. Feedback will be prioritized based on popularity.
  • If you have feedback that’s not listed yet, submit your own.

Thanks for joining our community and helping improve Syncfusion products!

1
Vote

Some case when i call 'container.documentEditor.importFormData(...)', the console log shown me some exceptions at the lines of code in ej2-document.es2015.js belows:

4521 => text.indexOf is not a function

9340 => element.text.replace is not a function

17327 => text.match is not a function


I did a workaround (see attach) in the source code for now, it's working again

i'm on package : 

 "@syncfusion/ej2-angular-documenteditor": "^20.1.51",


#Toolbar Issue:

in reInitToolbarItems(items) method

Line 100892 => 

this.restrictDropDwn.destroy()

this.breakDropDwn.destroy()

this.formFieldDropDown.destroy()


=> destroy 

is not a function of undefined


I'm using custom toolbar items in this case. So it threw out those exceptions and the toolbar cannot render its items.


i did a workaround in the attach so.

#My case is:
- Step1: Initiate the DocumentEditor with default toolbar items
Html:

<ejs-documenteditorcontainer [toolbarItems]="toolbarItems"  ..... >
TS:
toolbarItems :any[] = ['Find'];

- Step 2: after that base on current our application user account, we load appropriate items for the toolbar
TS:
setTimeout(()=>{
     switch(permission){
          case 'Editor':
              this.toolbarItems = [

        'Undo', 'Redo','Separator', 'Image', 'Table', 'Hyperlink', 'Bookmark', 'TableOfContents','Separator', 'Header', 'Footer', 'PageSetup', 'PageNumber', 'Break','Separator', 'Comments'

                   ];
      break;
case 'PartitalEditor':
         this.toolbarItems=[
              
 'Undo', 'Redo','Separator', 'Image', 'Table', 'Hyperlink', 'Bookmark', 'TableOfContents','Separator', 'Header', 'Footer', 'PageSetup', 'PageNumber', 'Break','Separator', 'Comments'

, 'TrackChanges'

         ];
break;
     }
},500)

Issue: the toolbar cannot load items
=> F12 to open the webdev tool of chrome / Console:

   i see the error message as
#Toolbar Issue