UNPKG

@progress/kendo-angular-common

Version:

Kendo UI for Angular - Utility Package

23 lines (22 loc) 865 B
/**----------------------------------------------------------------------------------------- * Copyright © 2025 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the project root for more information *-------------------------------------------------------------------------------------------*/ export class PreventableEvent { prevented = false; /** * Prevents the default action for the event. * The source component suppresses the built-in behavior that follows the event. */ preventDefault() { this.prevented = true; } /** * Returns `true` if you or any subscriber prevented the default action. * * @returns `true` if the default action was prevented, otherwise, `false`. */ isDefaultPrevented() { return this.prevented; } }