2 Popconfirm
Byron edited this page 2026-10-02 23:43:09 +02:00

Note

This component uses the built-in Popover API.

Warning

Popconfirms will open and close as expected in the Static rendering mode, but the OkClicked callback only fires when in the Interactive rendering mode.

Basic

<CleanButton popovertarget="popconfirm" popovertargetaction="toggle">
	Default
</CleanButton>
<CleanButton popovertarget="popconfirm-right" popovertargetaction="toggle">
	Right
</CleanButton>
<CleanButton popovertarget="popconfirm-bottom" popovertargetaction="toggle">
	Bottom
</CleanButton>
<CleanButton popovertarget="popconfirm-left" popovertargetaction="toggle">
	Left
</CleanButton>

<CleanPopconfirm id="popconfirm" OkClicked="@(OnOkAsync)">
	Are you sure you want to run this action?
</CleanPopconfirm>
<CleanPopconfirm id="popconfirm-right" OkClicked="@(OnOkAsync)" Position="@(CleanPopoverPosition.Right)">
	Are you sure you want to run this action?
</CleanPopconfirm>
<CleanPopconfirm id="popconfirm-bottom" OkClicked="@(OnOkAsync)" Position="@(CleanPopoverPosition.Bottom)">
	Are you sure you want to run this action?
</CleanPopconfirm>
<CleanPopconfirm id="popconfirm-left" OkClicked="@(OnOkAsync)" Position="@(CleanPopoverPosition.Left)">
	Are you sure you want to run this action?
</CleanPopconfirm>

@code {

	private Task OnOkAsync() =>
		Task.CompletedTask.

}