-
Notifications
You must be signed in to change notification settings - Fork 60
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2281 from umbraco/v15/feature/user-sidebar-menu
Feature: User sidebar menu
- Loading branch information
Showing
63 changed files
with
576 additions
and
409 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import { UMB_USER_MANAGEMENT_SECTION_ALIAS } from './constants.js'; | ||
import { manifests as sectionSidebarAppManifests } from './sidebar-app/manifests.js'; | ||
import { manifests as menuManifests } from './menu/manifests.js'; | ||
import type { | ||
ManifestSection, | ||
ManifestTypes, | ||
UmbBackofficeManifestKind, | ||
} from '@umbraco-cms/backoffice/extension-registry'; | ||
|
||
const section: ManifestSection = { | ||
type: 'section', | ||
alias: UMB_USER_MANAGEMENT_SECTION_ALIAS, | ||
name: 'User Management Section', | ||
weight: 600, | ||
meta: { | ||
label: '#sections_users', | ||
pathname: 'user-management', | ||
}, | ||
conditions: [ | ||
{ | ||
alias: 'Umb.Condition.SectionUserPermission', | ||
match: UMB_USER_MANAGEMENT_SECTION_ALIAS, | ||
}, | ||
], | ||
}; | ||
|
||
export const manifests: Array<ManifestTypes | UmbBackofficeManifestKind> = [ | ||
section, | ||
...sectionSidebarAppManifests, | ||
...menuManifests, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export const UMB_USER_MANAGEMENT_MENU_ALIAS = 'Umb.Menu.UserManagement'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from './constants.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import { UMB_USER_MANAGEMENT_MENU_ALIAS } from './constants.js'; | ||
|
||
export const manifests = [ | ||
{ | ||
type: 'menu', | ||
alias: UMB_USER_MANAGEMENT_MENU_ALIAS, | ||
name: 'User Management Menu', | ||
}, | ||
]; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from '../constants.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { UMB_USER_MANAGEMENT_SECTION_ALIAS } from '../constants.js'; | ||
import { UMB_USER_MANAGEMENT_MENU_ALIAS } from '../menu/index.js'; | ||
import type { ManifestTypes, UmbBackofficeManifestKind } from '@umbraco-cms/backoffice/extension-registry'; | ||
|
||
export const manifests: Array<ManifestTypes | UmbBackofficeManifestKind> = [ | ||
{ | ||
type: 'sectionSidebarApp', | ||
kind: 'menu', | ||
alias: 'Umb.SectionSidebarApp.Menu.UserManagement', | ||
name: 'User Management Menu Sidebar App', | ||
weight: 100, | ||
meta: { | ||
label: '#treeHeaders_users', | ||
menu: UMB_USER_MANAGEMENT_MENU_ALIAS, | ||
}, | ||
conditions: [ | ||
{ | ||
alias: 'Umb.Condition.SectionAlias', | ||
match: UMB_USER_MANAGEMENT_SECTION_ALIAS, | ||
}, | ||
], | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
export const UMB_USER_GROUP_ENTITY_TYPE = 'user-group'; | ||
export const UMB_USER_GROUP_ROOT_ENTITY_TYPE = 'user-group-root'; | ||
|
||
export type UmbUserGroupEntityType = typeof UMB_USER_GROUP_ENTITY_TYPE; | ||
export type UmbUserGroupRootEntityType = typeof UMB_USER_GROUP_ROOT_ENTITY_TYPE; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,21 @@ | ||
import { manifests as collectionManifests } from './collection/manifests.js'; | ||
import { manifests as repositoryManifests } from './repository/manifests.js'; | ||
import { manifests as workspaceManifests } from './workspace/manifests.js'; | ||
import { manifests as modalManifests } from './modals/manifests.js'; | ||
import { manifests as sectionViewManifests } from './section-view/manifests.js'; | ||
import { manifests as entityActionManifests } from './entity-actions/manifests.js'; | ||
import { manifests as entityBulkActionManifests } from './entity-bulk-actions/manifests.js'; | ||
import type { ManifestTypes } from '@umbraco-cms/backoffice/extension-registry'; | ||
import { manifests as menuItemManifests } from './menu-item/manifests.js'; | ||
import { manifests as modalManifests } from './modals/manifests.js'; | ||
import { manifests as repositoryManifests } from './repository/manifests.js'; | ||
import { manifests as sectionViewManifests } from './workspace/user-group-root/manifests.js'; | ||
import { manifests as workspaceManifests } from './workspace/manifests.js'; | ||
|
||
export const manifests: Array<ManifestTypes> = [ | ||
import type { ManifestTypes, UmbBackofficeManifestKind } from '@umbraco-cms/backoffice/extension-registry'; | ||
|
||
export const manifests: Array<ManifestTypes | UmbBackofficeManifestKind> = [ | ||
...collectionManifests, | ||
...repositoryManifests, | ||
...workspaceManifests, | ||
...modalManifests, | ||
...sectionViewManifests, | ||
...entityActionManifests, | ||
...entityBulkActionManifests, | ||
...menuItemManifests, | ||
...modalManifests, | ||
...repositoryManifests, | ||
...sectionViewManifests, | ||
...workspaceManifests, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { UMB_USER_MANAGEMENT_MENU_ALIAS } from '../../section/menu/constants.js'; | ||
import { UMB_USER_GROUP_ROOT_ENTITY_TYPE } from '../entity.js'; | ||
import type { ManifestTypes } from '@umbraco-cms/backoffice/extension-registry'; | ||
|
||
export const manifests: Array<ManifestTypes> = [ | ||
{ | ||
type: 'menuItem', | ||
alias: 'Umb.MenuItem.UserGroups', | ||
name: 'User Groups Menu Item', | ||
weight: 100, | ||
meta: { | ||
label: '#user_usergroups', | ||
icon: 'icon-users', | ||
entityType: UMB_USER_GROUP_ROOT_ENTITY_TYPE, | ||
menus: [UMB_USER_MANAGEMENT_MENU_ALIAS], | ||
}, | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,13 @@ | ||
import { UMB_USER_SECTION_PATHNAME } from '../user-section/paths.js'; | ||
import { UMB_USER_GROUP_ENTITY_TYPE } from './entity.js'; | ||
import { UMB_USER_SECTION_PATHNAME } from '../section/paths.js'; | ||
import { UMB_USER_GROUP_ENTITY_TYPE, UMB_USER_GROUP_ROOT_ENTITY_TYPE } from './entity.js'; | ||
import { UMB_WORKSPACE_PATH_PATTERN } from '@umbraco-cms/backoffice/workspace'; | ||
|
||
export const UMB_USER_GROUP_WORKSPACE_PATH = UMB_WORKSPACE_PATH_PATTERN.generateAbsolute({ | ||
sectionName: UMB_USER_SECTION_PATHNAME, | ||
entityType: UMB_USER_GROUP_ENTITY_TYPE, | ||
}); | ||
|
||
export const UMB_USER_GROUP_ROOT_WORKSPACE_PATH = UMB_WORKSPACE_PATH_PATTERN.generateAbsolute({ | ||
sectionName: UMB_USER_SECTION_PATHNAME, | ||
entityType: UMB_USER_GROUP_ROOT_ENTITY_TYPE, | ||
}); |
This file was deleted.
Oops, something went wrong.
63 changes: 0 additions & 63 deletions
63
src/packages/user/user-group/section-view/user-group-section-view.element.ts
This file was deleted.
Oops, something went wrong.
52 changes: 0 additions & 52 deletions
52
src/packages/user/user-group/workspace/actions/workspace-action-user-group-save.element.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1,4 @@ | ||
import type { | ||
ManifestWorkspaces, | ||
ManifestWorkspaceActions, | ||
ManifestWorkspaceView, | ||
ManifestTypes, | ||
} from '@umbraco-cms/backoffice/extension-registry'; | ||
import { UmbSubmitWorkspaceAction } from '@umbraco-cms/backoffice/workspace'; | ||
import { manifests as userGroupManifests } from './user-group/manifests.js'; | ||
import type { ManifestTypes, UmbBackofficeManifestKind } from '@umbraco-cms/backoffice/extension-registry'; | ||
|
||
const workspace: ManifestWorkspaces = { | ||
type: 'workspace', | ||
kind: 'routable', | ||
alias: 'Umb.Workspace.UserGroup', | ||
name: 'User Group Workspace', | ||
api: () => import('./user-group-workspace.context.js'), | ||
meta: { | ||
entityType: 'user-group', | ||
}, | ||
}; | ||
|
||
const workspaceViews: Array<ManifestWorkspaceView> = []; | ||
const workspaceActions: Array<ManifestWorkspaceActions> = [ | ||
{ | ||
type: 'workspaceAction', | ||
kind: 'default', | ||
alias: 'Umb.WorkspaceAction.UserGroup.Save', | ||
name: 'Save User Group Workspace Action', | ||
api: UmbSubmitWorkspaceAction, | ||
meta: { | ||
label: '#buttons_save', | ||
look: 'primary', | ||
color: 'positive', | ||
}, | ||
conditions: [ | ||
{ | ||
alias: 'Umb.Condition.WorkspaceAlias', | ||
match: workspace.alias, | ||
}, | ||
], | ||
}, | ||
]; | ||
|
||
export const manifests: Array<ManifestTypes> = [workspace, ...workspaceViews, ...workspaceActions]; | ||
export const manifests: Array<ManifestTypes | UmbBackofficeManifestKind> = [...userGroupManifests]; |
14 changes: 14 additions & 0 deletions
14
src/packages/user/user-group/workspace/user-group-root/manifests.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { UMB_USER_GROUP_ROOT_ENTITY_TYPE } from '../../entity.js'; | ||
import type { ManifestTypes, UmbBackofficeManifestKind } from '@umbraco-cms/backoffice/extension-registry'; | ||
|
||
export const manifests: Array<ManifestTypes | UmbBackofficeManifestKind> = [ | ||
{ | ||
type: 'workspace', | ||
alias: 'Umb.Workspace.UserGroupRoot', | ||
name: 'User Group Root Workspace View', | ||
element: () => import('./user-group-root-workspace.element.js'), | ||
meta: { | ||
entityType: UMB_USER_GROUP_ROOT_ENTITY_TYPE, | ||
}, | ||
}, | ||
]; |
Oops, something went wrong.