diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/constants.ts new file mode 100644 index 0000000000..31baf82e9f --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS = 'Umb.Condition.User.AllowChangePassword'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/manifests.ts index 368f12e683..568650836e 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-change-password/manifests.ts @@ -1,8 +1,10 @@ +import { UMB_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS } from './constants.js'; + export const manifests: Array = [ { type: 'condition', name: 'User Allow Change Password Condition', - alias: 'Umb.Condition.User.AllowChangePassword', + alias: UMB_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS, api: () => import('./user-allow-change-password-action.condition.js'), }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/constants.ts new file mode 100644 index 0000000000..8183df1002 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_DELETE_CONDITION_ALIAS = 'Umb.Condition.User.AllowDeleteAction'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/manifests.ts index b25eba1462..d05317a682 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-delete/manifests.ts @@ -1,8 +1,10 @@ +import { UMB_USER_ALLOW_DELETE_CONDITION_ALIAS } from './constants.js'; + export const manifests: Array = [ { type: 'condition', name: 'User Allow Delete Action Condition', - alias: 'Umb.Condition.User.AllowDeleteAction', + alias: UMB_USER_ALLOW_DELETE_CONDITION_ALIAS, api: () => import('./user-allow-delete-action.condition.js'), }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/constants.ts new file mode 100644 index 0000000000..965922176c --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_DISABLE_CONDITION_ALIAS = 'Umb.Condition.User.AllowDisableAction'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/manifests.ts index 34ba7e7d38..a7ce9b3a1f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-disable/manifests.ts @@ -1,8 +1,10 @@ +import { UMB_USER_ALLOW_DISABLE_CONDITION_ALIAS } from './constants.js'; + export const manifests: Array = [ { type: 'condition', name: 'User Allow Disable Action Condition', - alias: 'Umb.Condition.User.AllowDisableAction', + alias: UMB_USER_ALLOW_DISABLE_CONDITION_ALIAS, api: () => import('./user-allow-disable-action.condition.js'), }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-enable/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-enable/constants.ts new file mode 100644 index 0000000000..f2221ec92a --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-enable/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_ENABLE_CONDITION_ALIAS = 'Umb.Condition.User.AllowEnableAction'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/constants.ts new file mode 100644 index 0000000000..8b7e01c6c1 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_EXTERNAL_LOGIN_CONDITION_ALIAS = 'Umb.Condition.User.AllowExternalLoginAction'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/manifests.ts index 966f5aa137..4ff36ca25c 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-external-login/manifests.ts @@ -1,8 +1,10 @@ +import { UMB_USER_ALLOW_EXTERNAL_LOGIN_CONDITION_ALIAS } from './constants.js'; + export const manifests: Array = [ { type: 'condition', name: 'User Allow ExternalLogin Action Condition', - alias: 'Umb.Condition.User.AllowExternalLoginAction', + alias: UMB_USER_ALLOW_EXTERNAL_LOGIN_CONDITION_ALIAS, api: () => import('./user-allow-external-login-action.condition.js'), }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/constants.ts new file mode 100644 index 0000000000..872ba596a7 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_MFA_CONDITION_ALIAS = 'Umb.Condition.User.AllowMfaAction'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/manifests.ts index a9cb89568d..c25c206618 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-mfa/manifests.ts @@ -1,8 +1,10 @@ +import { UMB_USER_ALLOW_MFA_CONDITION_ALIAS } from './constants.js'; + export const manifests: Array = [ { type: 'condition', name: 'User Allow Mfa Action Condition', - alias: 'Umb.Condition.User.AllowMfaAction', + alias: UMB_USER_ALLOW_MFA_CONDITION_ALIAS, api: () => import('./user-allow-mfa-action.condition.js'), }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/constants.ts new file mode 100644 index 0000000000..8e29b48475 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/constants.ts @@ -0,0 +1 @@ +export const UMB_USER_ALLOW_UNLOCK_CONDITION_ALIAS = 'Umb.Condition.User.AllowUnlockAction'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/manifests.ts index 9fafc5d5be..69c89702a8 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/allow-unlock/manifests.ts @@ -1,8 +1,10 @@ +import { UMB_USER_ALLOW_UNLOCK_CONDITION_ALIAS } from './constants.js'; + export const manifests: Array = [ { type: 'condition', name: 'User Allow Unlock Action Condition', - alias: 'Umb.Condition.User.AllowUnlockAction', + alias: UMB_USER_ALLOW_UNLOCK_CONDITION_ALIAS, api: () => import('./user-allow-unlock-action.condition.js'), }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/types.ts b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/types.ts new file mode 100644 index 0000000000..006ccf837d --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/user/user/conditions/types.ts @@ -0,0 +1,23 @@ +import type { UMB_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS } from './allow-change-password/constants.js'; +import type { UMB_USER_ALLOW_DELETE_CONDITION_ALIAS } from './allow-delete/constants.js'; +import type { UMB_USER_ALLOW_DISABLE_CONDITION_ALIAS } from './allow-disable/constants.js'; +import type { UMB_USER_ALLOW_ENABLE_CONDITION_ALIAS } from './allow-enable/constants.js'; +import type { UMB_USER_ALLOW_EXTERNAL_LOGIN_CONDITION_ALIAS } from './allow-external-login/constants.js'; +import type { UMB_USER_ALLOW_MFA_CONDITION_ALIAS } from './allow-mfa/constants.js'; +import type { UMB_USER_ALLOW_UNLOCK_CONDITION_ALIAS } from './allow-unlock/constants.js'; +import type { UmbConditionConfigBase } from '@umbraco-cms/backoffice/extension-api'; + +type UmbUserConditionConfigs = + | UmbConditionConfigBase + | UmbConditionConfigBase + | UmbConditionConfigBase + | UmbConditionConfigBase + | UmbConditionConfigBase + | UmbConditionConfigBase + | UmbConditionConfigBase; + +declare global { + interface UmbExtensionConditionConfigMap { + UmbUserConditionConfigs: UmbUserConditionConfigs; + } +}