Having trouble getting help?
Contact Support
Contact Support
Create right to left dropdownbutton in Angular Drop down button component
27 Apr 20242 minutes to read
DropDownButton component has RTL support. This can be achieved by setting enableRtl
as true.
The following example illustrates how to enable right-to-left support in DropDownButton component.
import { NgModule } from '@angular/core'
import { BrowserModule } from '@angular/platform-browser'
import { DropDownButtonModule } from '@syncfusion/ej2-angular-splitbuttons'
import { enableRipple } from '@syncfusion/ej2-base'
import { Component } from '@angular/core';
import { ItemModel } from '@syncfusion/ej2-angular-splitbuttons';
@Component({
imports: [
DropDownButtonModule
],
standalone: true,
selector: 'app-root',
template: `<div class="e-section-control">
<!-- To render DropDownButton. -->
<button ejs-dropdownbutton [items]='items' content='Message' iconCss='ddb-icons e-message' enableRtl='true'></button>
</div>`
})
export class AppComponent {
// Initialize action items.
public items: ItemModel[] = [
{
text: 'Edit'
},
{
text: 'Delete'
},
{
text: 'Mark as Read'
},
{
text: 'Like Message'
}];
}
import { bootstrapApplication } from '@angular/platform-browser';
import { AppComponent } from './app.component';
import 'zone.js';
bootstrapApplication(AppComponent).catch((err) => console.error(err));