From 0a786481754cc43cbefbf7df46d98039cdc5a55e Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Tue, 28 Jan 2025 14:04:35 +0100 Subject: [PATCH] add event discriminator option --- .../packages/core/entity-action/entity-action.event.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/entity-action/entity-action.event.ts b/src/Umbraco.Web.UI.Client/src/packages/core/entity-action/entity-action.event.ts index e6567e5a7c..0c0e2da1d3 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/entity-action/entity-action.event.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/entity-action/entity-action.event.ts @@ -2,7 +2,9 @@ import { UmbControllerEvent } from '@umbraco-cms/backoffice/controller-api'; import type { UmbEntityModel } from '@umbraco-cms/backoffice/entity'; // eslint-disable-next-line @typescript-eslint/no-empty-object-type -export interface UmbEntityActionEventArgs extends UmbEntityModel {} +export interface UmbEntityActionEventArgs extends UmbEntityModel { + discriminator?: string; +} export class UmbEntityActionEvent< ArgsType extends UmbEntityActionEventArgs = UmbEntityActionEventArgs, @@ -21,4 +23,8 @@ export class UmbEntityActionEvent< getUnique(): string | null { return this._args.unique; } + + getDiscriminator(): string | undefined { + return this._args.discriminator; + } }