You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+10-10Lines changed: 10 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,9 +8,9 @@
8
8
# Blazor Grid - Customize Context Menu
9
9
10
10
This example enables, customizes, and implements context menus in Blazor Grid and Toolbar components. It demonstrates the following tasks:
11
-
*Enable built-in context menus for DxGrid's predefined areas: header, footer, data row, group panel, group row, and group footer.
12
-
*Customize context menu items for header, footer, and data rows using DxGrid APIs.
13
-
*Define custom context menus for areas that do not include built-in context menus.
11
+
*Enables built-in context menus for predefined Grid areas: header, footer, data row, group panel, group row, and group footer.
12
+
*Customizes context menu items for header, footer, and data rows using Grid APIs.
13
+
*Defines custom context menus for areas that do not include built-in context menus.
14
14
15
15

16
16
@@ -31,7 +31,7 @@ Set the [ContextMenus](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGr
31
31
32
32
The `DxGrid` component includes built-in APIs used to customize context menu items. This scenario affects the following Grid areas: header, footer, and data rows.
33
33
34
-
In the Grid's [CustomizeContextMenu](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGrid.CustomizeContextMenu) event handler, call the helper method defined in the [GridContextMenuHelper.cs](./CS/GridWithContextMenu/Data/GridContextMenuHelper.cs#L298-L365) class to customize the built-in context menu items.
34
+
In the [CustomizeContextMenu](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGrid.CustomizeContextMenu) event handler, call the helper method defined in the [GridContextMenuHelper.cs](./CS/GridWithContextMenu/Data/GridContextMenuHelper.cs#L298-L365) class to customize built-in context menu items.
35
35
36
36
```
37
37
<DxGrid @ref="Grid"
@@ -50,19 +50,19 @@ In the Grid's [CustomizeContextMenu](https://docs.devexpress.com/Blazor/DevExpre
50
50
51
51
### Add Custom Context Menus
52
52
53
-
Follow the steps below to display custom context menus for the toolbar component, Grid's edit row, and Grid's pager:
53
+
To display custom context menus for the toolbar component, Grid's edit row and pager, you must:
54
54
55
-
1. In the [GridContextMenuContainer](./CS/GridWithContextMenu/Pages/GridContextMenuContainer.razor#L4-L28) component, define the context menu components.
56
-
2. In the [GridContextMenuHelper](./CS/GridWithContextMenu/Data/GridContextMenuHelper.cs#L31-L59) class, implement context menu item generation, state management, and click handlers. The Blazor [Grid API](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGrid._methods)uses them to execute commands.
55
+
1. In the [GridContextMenuContainer](./CS/GridWithContextMenu/Pages/GridContextMenuContainer.razor#L4-L28) component, define context menu components.
56
+
2. In the [GridContextMenuHelper](./CS/GridWithContextMenu/Data/GridContextMenuHelper.cs#L31-L59) class, implement context menu item generation, state management, and click handlers. The Blazor [Grid API](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGrid._methods)calls these helper methods to execute commands.
57
57
3. Add the [oncontextmenu:preventDefault](./CS/GridWithContextMenu/Pages/Index.razor#L14) directive to disable the standard browser context menu.
58
-
4. In the Grid's [CustomizeElement](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGrid.CustomizeElement) event handler, subscribe to the **contextmenu** event to display the custom context menu.
58
+
4. In the [CustomizeElement](https://docs.devexpress.com/Blazor/DevExpress.Blazor.DxGrid.CustomizeElement) event handler, subscribe to the **contextmenu** event to display a custom context menu.
0 commit comments