Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions blazor-toc.html
Original file line number Diff line number Diff line change
Expand Up @@ -3030,10 +3030,8 @@
<li>How To
<ul>
<li> <a href="/blazor/drop-down-menu/how-to/change-caret-icon">Change caret icon</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/create-dropdownbutton-with-rounded-corner">Create Dropdown Menu with rounded corner</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/create-right-to-left-dropdownbutton">Create right-to-left Dropdown Menu</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/customize-icon-and-width">Customize icon and width</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/disable-a-dropdownbutton">Disable a Dropdown Menu</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/group-popups-with-listview">Group popups with listview component</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/hide-dropdown-arrow">Hide dropdown arrow</a></li>
<li> <a href="/blazor/drop-down-menu/how-to/open-a-dialog-on-popup-item-click">Open a dialog on popup item click</a></li>
Expand Down Expand Up @@ -3460,6 +3458,7 @@
<li> <a href="/blazor/in-place-editor/style">Style and Appearance</a></li>
<li> <a href="/blazor/in-place-editor/localization">Globalization</a></li>
<li> <a href="/blazor/in-place-editor/events">Events</a></li>
<li> <a href="/blazor/in-place-editor/native-events">Native Events</a></li>
<li>How To
<ul>
<li> <a href="/blazor/in-place-editor/how-to/dynamic-edit-mode">Dynamically move input to edit mode</a></li>
Expand Down
50 changes: 50 additions & 0 deletions blazor/in-place-editor/native-events.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
layout: post
title: Native Events in Blazor In-place Editor Component | Syncfusion
description: Checkout and learn here all about Native Events in Syncfusion Blazor In-place Editor component and much more.
platform: Blazor
control: In-place Editor
documentation: ug
---

# Overview on Native Events

You can define the native event using on `<event>` attribute in component. The value of attribute is treated as an event handler. The event specific data will be available in event arguments.

The different event argument types for each event are:

* Mouse Events - UIMouseEventArgs
* Keyboard Events - UIKeyboardEventArgs

## List of Native events supported

The following native events support is provided to the In-place Editor component:

| List of Native events | | | |
| --- | --- | --- | --- |
| onmousedown | onmouseup | onmouseover | onmousemove |
| onmouseout | onkeydown | onkeypress | onkeyup |

## How to bind onmousedown event to In-place Editor

The `onmousedown` attribute is used to bind the mouse down event for In-place Editor. The sample code snippets of `onmousedown` in In-place Editor to change the mode as Inline are explained as follows.

```cshtml

@using Syncfusion.Blazor.InPlaceEditor

<SfInPlaceEditor Mode="@Mode" @onmousedown="OnMouseDown" Type="InputType.Text" Value="@TextValue" SubmitOnEnter="true" />

@code {
public string TextValue = "Andrew";
public Syncfusion.Blazor.InPlaceEditor.RenderMode Mode = Syncfusion.Blazor.InPlaceEditor.RenderMode.Inline;

private void OnMouseDown(MouseEventArgs args)
{
this.Mode = this.Mode == Syncfusion.Blazor.InPlaceEditor.RenderMode.Inline ? Syncfusion.Blazor.InPlaceEditor.RenderMode.Popup : Syncfusion.Blazor.InPlaceEditor.RenderMode.Inline;
this.StateHasChanged();
}

}

```