froala / angular-froala-wysiwyg

Angular 4, 5, 6, 7, 8 and 9 plugin for Froala WYSIWYG HTML Rich Text Editor.
https://froala.com/wysiwyg-editor
734 stars 201 forks source link

transition from 2.9.X to 3.0.X issues #337

Open dolphinsd opened 5 years ago

dolphinsd commented 5 years ago

Luck of documentation creates questions. Here is our transition pain, we cannot find answers:

  1. We used to be able to cal this:1 this.editor('events.enableBlur'); What do we call now to enableBlur on the editor in angular ?

  2. We used to call this: if (this.editor('codeView.isActive')) { this.innerValue = this.editor('codeView.get'); this.onChangeCallback(this.innerValue); } What do we call now in angular?

  3. We used to define custom icon with fa5 like this: $.FroalaEditor.DefineIcon('insertContent', { FA5NAME: 'magic', NAME: 'magic'}); How do we define custom icon, we do not want to use one of your predefined svgs.

dolphinsd commented 5 years ago

For #2 to work add to config

        angularIgnoreAttrs: ['style', 'ng-reflect-froala-editor', 'ng-reflect-froala-model'],
        immediateAngularModelUpdate: true,

and use this.editor.codeView.isActive

for #3 to work download svg image from https://fontawesome.com/icons/magic?style=solid use iloveimg.com to resize it to 24x24 svg

1 we did not find a solution