Angular HtmlEditor - toolbar.items.commands
An array of AI commands.
Type:
options
Command options.
Type: any
Only the following commands include predefined options:
- "formal"
- "informal"
- "technical"
- "business"
- "creative"
- "journalistic"
- "academic"
- "persuasive"
- "narrative"
- "expository"
- "descriptive"
- "conversational"
- "professional"
- "casual"
- "straightforward"
- "confident"
- "friendly"
- "Arabic"
- "Chinese"
- "English"
- "French"
- "German"
- "Japanese"
- "Spanish"
If you use these commands without declaring the options array, all predefined options are available. You can assign only specific options or add custom options:
app.component.html
app.component.ts
- <dx-html-editor
- [aiIntegration]="aiIntegration"
- >
- <dxo-html-editor-toolbar>
- <dxi-html-editor-toolbar-item name="ai">
- <dxi-html-editor-command name="translate" [options]="translateOptions"></dxi-html-editor-command>
- </dxi-html-editor-toolbar-item>
- </dxo-html-editor-toolbar>
- </dx-html-editor>
- export class AppComponent {
- // ...
- translateOptions = ['English', 'German', 'Chinese', 'Lithuanian'];
- }
The "custom" command can also include custom options.