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: Document-Processing/PDF/PDF-Viewer/react/context-menu/builtin-context-menu.md
+8-1Lines changed: 8 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,12 +17,19 @@ The React PDF Viewer includes a context-sensitive menu that updates dynamically
17
17
Menu items vary depending on the target element:
18
18
19
19
***Text**: Displays options to annotate and copy selected text.
20
+
20
21

22
+
21
23
***Annotations**: Provides options to copy, cut, paste, or remove annotations, and add comments.
24
+
22
25

26
+
23
27
***Form Fields**: Shows standard form field interactions, such as modifying properties. The context menu for form fields appears only when the viewer is in **designer mode**.
28
+
24
29

30
+
25
31
***Empty Space**: Displays the option to paste a previously copied annotation or form field.
32
+
26
33

27
34
28
35
## Default Item Reference
@@ -57,7 +64,7 @@ The following items are available when interacting with annotations:
57
64
These items appear when the viewer is in designer mode and a form field is selected:
58
65
59
66
| Item | Description |
60
-
| :--- | : :--- |
67
+
| :--- | :--- |
61
68
|**Copy**| Copies the selected form field for duplication. |
62
69
|**Cut**| Removes the selected form field for relocation. |
Copy file name to clipboardExpand all lines: Document-Processing/PDF/PDF-Viewer/react/context-menu/custom-context-menu.md
+14-6Lines changed: 14 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,12 +14,12 @@ The PDF Viewer supports extensive customization of the context menu, including r
14
14
15
15
## Add Custom Context Menu Items
16
16
17
-
You can add custom options to the context menu using the [addCustomMenu()](https://ej2.syncfusion.com/react/documentation/api/pdfviewer#addcustommenu) method. This is typically implemented during the `documentLoad` event.
17
+
You can add custom options to the context menu using the [addCustomMenu()](https://ej2.syncfusion.com/react/documentation/api/pdfviewer#addcustommenu) method. This is typically implemented during the [`documentLoad`](https://ej2.syncfusion.com/react/documentation/api/pdfviewer#documentload) event.
18
18
19
19
### Implementation Guide
20
20
21
21
1. Define the menu items as an array of objects.
22
-
2. Call the `addCustomMenu` method within the `documentLoad` event handler.
22
+
2. Call the [`addCustomMenu`](https://ej2.syncfusion.com/react/documentation/api/pdfviewer#addcustommenu) method within the [`documentLoad`](https://ej2.syncfusion.com/react/documentation/api/pdfviewer#documentload) event handler.
23
23
24
24
```jsx
25
25
exportfunctionApp() {
@@ -314,12 +314,20 @@ root.render(<App />);
314
314
315
315
## Disable the Context Menu Entirely
316
316
317
-
The context menu in the PDF Viewer can be fully disabled by setting the `enableContextMenu` property to `false`.
317
+
The context menu in the PDF Viewer can be fully disabled by setting the [`contextMenuOption`](https://ej2.syncfusion.com/react/documentation/api/pdfviewer#contextmenuoption) property to `None`.
0 commit comments