|
| 1 | +--- |
| 2 | +layout: post |
| 3 | +title: Built-in Context Menu in React PDF Viewer | Syncfusion |
| 4 | +description: Explore the default context menu items in the React PDF Viewer, including options for text selection, annotations, and form fields. |
| 5 | +control: PDF Viewer |
| 6 | +platform: document-processing |
| 7 | +documentation: ug |
| 8 | +domainurl: ##DomainURL## |
| 9 | +--- |
| 10 | + |
| 11 | +# Built-in Context Menu Items in React PDF Viewer |
| 12 | + |
| 13 | +The React PDF Viewer includes a context-sensitive menu that updates dynamically based on the right-clicked element within the document. This page lists the default menu items available for different document elements. |
| 14 | + |
| 15 | +## Context Menu Scenarios |
| 16 | + |
| 17 | +Menu items vary depending on the target element: |
| 18 | + |
| 19 | +* **Text**: Displays options to annotate and copy selected text. |
| 20 | + |
| 21 | +  |
| 22 | + |
| 23 | +* **Annotations**: Provides options to copy, cut, paste, or remove annotations, and add comments. |
| 24 | + |
| 25 | +  |
| 26 | + |
| 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 | + |
| 29 | +  |
| 30 | + |
| 31 | +* **Empty Space**: Displays the option to paste a previously copied annotation or form field. |
| 32 | + |
| 33 | +  |
| 34 | + |
| 35 | +## Default Item Reference |
| 36 | + |
| 37 | +### Text Menu Items |
| 38 | + |
| 39 | +The following table describes the default items available when right-clicking selected text: |
| 40 | + |
| 41 | +| Item | Description | |
| 42 | +| :--- | :--- | |
| 43 | +| **Copy** | Copies selected text to the clipboard. | |
| 44 | +| **Highlight** | Highlights selected text using the default highlight color. | |
| 45 | +| **Underline** | Applies an underline to the selected text. | |
| 46 | +| **Strikethrough** | Applies a strikethrough to the selected text. | |
| 47 | +| **Squiggly** | Applies a squiggly underline to the selected text. | |
| 48 | +| **Redact Text** | Redacts the selected text. | |
| 49 | + |
| 50 | +### Annotation Menu Items |
| 51 | + |
| 52 | +The following items are available when interacting with annotations: |
| 53 | + |
| 54 | +| Item | Description | |
| 55 | +| :--- | :--- | |
| 56 | +| **Copy** | Copies the selected annotation for pasting within the same page. | |
| 57 | +| **Cut** | Removes the selected annotation and copies it to the clipboard. | |
| 58 | +| **Paste** | Pastes a previously copied or cut annotation. | |
| 59 | +| **Delete** | Permanently removes the selected annotation. | |
| 60 | +| **Comments** | Opens the comment panel to manage discussions on the annotation. | |
| 61 | + |
| 62 | +### Form Field Menu Items |
| 63 | + |
| 64 | +These items appear when the viewer is in designer mode and a form field is selected: |
| 65 | + |
| 66 | +| Item | Description | |
| 67 | +| :--- | :--- | |
| 68 | +| **Copy** | Copies the selected form field for duplication. | |
| 69 | +| **Cut** | Removes the selected form field for relocation. | |
| 70 | +| **Paste** | Pastes a copied or cut form field. | |
| 71 | +| **Delete** | Removes the selected form field from the document. | |
| 72 | +| **Properties** | Launches the properties dialog for the specific form field. | |
| 73 | + |
| 74 | +N> The availability of the context menu is a client-side feature and is independent of server configurations. |
0 commit comments