i wann to show one menu at left side and another is in right side.
Please provide the solution
|
<div id="defaultSample" class="control-section">
<div class="menu-control1">
<ejs-menu [items]='menuItems'></ejs-menu>
</div>
<div class="menu-control2">
<ejs-menu [items]='menuItems'></ejs-menu>
</div>
</div>
|
|
.menu-control2 {
position: absolute;
right: 10px;
}
.control-section {
display: flex;
}
|
Thanks for your effort
actually requirement is like i want to implement 2 sidebars one is left side another is right side.
Below image is showing the left side menu only ,i want both menu(left and right) simultaneously.user can open left side bar menu or right sidebar menu or both together
|
[app.component.html]
<!-- Left sidebar element declaration -->
<ejs-sidebar
id="sidebar-treeview"
class="dock-menu"
#leftSidebar
[width]="width"
[mediaQuery]="mediaQuery"
[target]="target"
[enableDock]="enableDock"
[dockSize]="dockSize"
>
…
</ejs-sidebar>
<!-- end of sidebar element -->
<!-- Right sidebar element declaration -->
<ejs-sidebar
id="sidebar-treeview"
class="dock-menu"
#rightSidebar
[width]="width"
[mediaQuery]="mediaQuery"
[position]="position"
[target]="target"
[enableDock]="enableDock"
[dockSize]="dockSize"
>
…
</ejs-sidebar>
<!-- end of sidebar element -->
[app.component.ts]
target: string = '.main-content';
public position: string = 'Right';
public enableDock: boolean = true;
public dockSize: string = '44px'; |
Thanks
this is wha i m looking for,but facing one issue,if i divide the menu in 2 components like upper click button is in header componenet and rest sidebar in another component then its not working,pls help
|
leftToggle() {
let left = document.getElementById('left-sidebar').ej2_instances[0];
left.toggle();
}
rightToggle() {
let right = document.getElementById('right-sidebar').ej2_instances[0];
right.toggle();
} |
Hello Indhumathy,
Sample: https://stackblitz.com/edit/sidebar-with-multiple-component?file=app/app.component.ts
this link you shared is not showing any menu .Please look .