From 04f7da81ec3f4403de297dbcd02f0aff1df4a8e9 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 15:07:54 +0100 Subject: [PATCH 01/20] register links and history as info apps --- ...ument-history-workspace-info-app.element.ts} | 17 +++++++++-------- .../documents/audit-log/info-app/manifests.ts | 9 +++++++++ .../views/info => audit-log/info-app}/utils.ts | 11 +---------- .../documents/documents/audit-log/manifests.ts | 4 ++++ .../packages/documents/documents/constants.ts | 1 + .../src/packages/documents/documents/index.ts | 5 +++-- .../packages/documents/documents/manifests.ts | 4 ++++ .../documents/documents/repository/constants.ts | 1 - .../documents/documents/repository/index.ts | 1 - .../documents/documents/repository/manifests.ts | 3 +-- .../documents/documents/url/constants.ts | 1 + .../packages/documents/documents/url/index.ts | 3 +++ ...ocument-links-workspace-info-app.element.ts} | 16 ++++++++-------- .../documents/url/info-app/manifests.ts | 9 +++++++++ .../documents/documents/url/manifests.ts | 4 ++++ .../url => url/repository}/constants.ts | 0 .../repository}/document-url.repository.ts | 0 .../document-url.server.data-source.ts | 0 .../document-url.store.context-token.ts | 0 .../repository}/document-url.store.ts | 0 .../{repository/url => url/repository}/index.ts | 0 .../url => url/repository}/manifests.ts | 0 .../{repository/url => url/repository}/types.ts | 0 .../src/packages/documents/documents/utils.ts | 9 +++++++++ .../documents/documents/workspace/index.ts | 1 + .../document-workspace-view-info.element.ts | 7 ++----- 26 files changed, 69 insertions(+), 37 deletions(-) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{workspace/views/info/document-workspace-view-info-history.element.ts => audit-log/info-app/document-history-workspace-info-app.element.ts} (89%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{workspace/views/info => audit-log/info-app}/utils.ts (95%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/manifests.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/constants.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/index.ts rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{workspace/views/info/document-workspace-view-info-links.element.ts => url/info-app/document-links-workspace-info-app.element.ts} (92%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/manifests.ts rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/constants.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/document-url.repository.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/document-url.server.data-source.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/document-url.store.context-token.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/document-url.store.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/index.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/manifests.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{repository/url => url/repository}/types.ts (100%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/index.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-history.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts similarity index 89% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-history.element.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts index cfa0bc151aac..ec900a351dd1 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-history.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts @@ -1,7 +1,8 @@ -import type { UmbDocumentAuditLogModel } from '../../../audit-log/types.js'; -import { UmbDocumentAuditLogRepository } from '../../../audit-log/index.js'; -import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../document-workspace.context-token.js'; -import { getDocumentHistoryTagStyleAndText, TimeOptions } from './utils.js'; +import { UmbDocumentAuditLogRepository } from '../repository/index.js'; +import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../workspace/constants.js'; +import type { UmbDocumentAuditLogModel } from '../types.js'; +import { TimeOptions } from '../../utils.js'; +import { getDocumentHistoryTagStyleAndText } from './utils.js'; import { css, customElement, html, nothing, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbPaginationManager } from '@umbraco-cms/backoffice/utils'; @@ -13,8 +14,8 @@ import type { ManifestEntityAction } from '@umbraco-cms/backoffice/entity-action import type { UmbUserItemModel } from '@umbraco-cms/backoffice/user'; import type { UUIPaginationEvent } from '@umbraco-cms/backoffice/external/uui'; -@customElement('umb-document-workspace-view-info-history') -export class UmbDocumentWorkspaceViewInfoHistoryElement extends UmbLitElement { +@customElement('umb-document-history-workspace-info-app') +export class UmbDocumentHistoryWorkspaceInfoAppElement extends UmbLitElement { #allowedActions = new Set(['Umb.EntityAction.Document.Rollback']); #auditLogRepository = new UmbDocumentAuditLogRepository(this); @@ -183,10 +184,10 @@ export class UmbDocumentWorkspaceViewInfoHistoryElement extends UmbLitElement { ]; } -export default UmbDocumentWorkspaceViewInfoHistoryElement; +export default UmbDocumentHistoryWorkspaceInfoAppElement; declare global { interface HTMLElementTagNameMap { - 'umb-document-workspace-view-info-history': UmbDocumentWorkspaceViewInfoHistoryElement; + 'umb-document-history-workspace-info-app': UmbDocumentHistoryWorkspaceInfoAppElement; } } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts new file mode 100644 index 000000000000..61e712b68949 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts @@ -0,0 +1,9 @@ +export const manifests: Array = [ + { + type: 'workspaceInfoApp', + name: 'Document History Workspace Info App', + alias: 'Umb.WorkspaceInfoApp.Document.History', + element: () => import('./document-history-workspace-info-app.element.js'), + weight: 90, + }, +]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/utils.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/utils.ts similarity index 95% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/utils.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/utils.ts index 5dc112913f52..fcf0124809a3 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/utils.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/utils.ts @@ -1,4 +1,4 @@ -import { UmbDocumentAuditLog, type UmbDocumentAuditLogType } from '../../../audit-log/utils/index.js'; +import { UmbDocumentAuditLog, type UmbDocumentAuditLogType } from '../utils/index.js'; interface HistoryStyleMap { look: 'default' | 'primary' | 'secondary' | 'outline' | 'placeholder'; @@ -137,12 +137,3 @@ export function getDocumentHistoryTagStyleAndText(type: UmbDocumentAuditLogType) }; } } - -export const TimeOptions: Intl.DateTimeFormatOptions = { - year: 'numeric', - month: 'long', - day: 'numeric', - hour: 'numeric', - minute: 'numeric', - second: 'numeric', -}; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/manifests.ts new file mode 100644 index 000000000000..9680516a9b4a --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/manifests.ts @@ -0,0 +1,4 @@ +import { manifests as infoAppManifests } from './info-app/manifests.js'; +import type { UmbExtensionManifestKind } from '@umbraco-cms/backoffice/extension-registry'; + +export const manifests: Array = [...infoAppManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/constants.ts index b51328d5925e..456994bdd613 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/constants.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/constants.ts @@ -12,5 +12,6 @@ export * from './reference/constants.js'; export * from './repository/constants.js'; export * from './rollback/constants.js'; export * from './search/constants.js'; +export * from './url/constants.js'; export * from './user-permissions/constants.js'; export * from './workspace/constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/index.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/index.ts index b172085015d5..fcc6565ced8d 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/index.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/index.ts @@ -1,9 +1,9 @@ import './components/index.js'; -export { UmbDocumentAuditLogRepository } from './audit-log/index.js'; +export * from './audit-log/index.js'; export * from './components/index.js'; -export * from './entity-actions/index.js'; export * from './constants.js'; +export * from './entity-actions/index.js'; export * from './global-contexts/index.js'; export * from './modals/index.js'; export * from './paths.js'; @@ -11,6 +11,7 @@ export * from './publishing/index.js'; export * from './recycle-bin/index.js'; export * from './reference/index.js'; export * from './repository/index.js'; +export * from './url/index.js'; export * from './user-permissions/index.js'; export * from './tree/index.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/manifests.ts index bb29839ea2ff..e744094a3c84 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/manifests.ts @@ -1,3 +1,4 @@ +import { manifests as auditLogManifests } from './audit-log/manifests.js'; import { manifests as collectionManifests } from './collection/manifests.js'; import { manifests as entityActionManifests } from './entity-actions/manifests.js'; import { manifests as entityBulkActionManifests } from './entity-bulk-actions/manifests.js'; @@ -13,12 +14,14 @@ import { manifests as rollbackManifests } from './rollback/manifests.js'; import { manifests as searchProviderManifests } from './search/manifests.js'; import { manifests as trackedReferenceManifests } from './reference/manifests.js'; import { manifests as treeManifests } from './tree/manifests.js'; +import { manifests as urlManifests } from './url/manifests.js'; import { manifests as userPermissionManifests } from './user-permissions/manifests.js'; import { manifests as workspaceManifests } from './workspace/manifests.js'; import type { UmbExtensionManifestKind } from '@umbraco-cms/backoffice/extension-registry'; export const manifests: Array = [ + ...auditLogManifests, ...collectionManifests, ...entityActionManifests, ...entityBulkActionManifests, @@ -34,6 +37,7 @@ export const manifests: Array = ...searchProviderManifests, ...trackedReferenceManifests, ...treeManifests, + ...urlManifests, ...userPermissionManifests, ...workspaceManifests, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/constants.ts index 655e81e66dd1..7a6c4a9d9c73 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/constants.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/constants.ts @@ -1,4 +1,3 @@ export * from './detail/constants.js'; export * from './item/constants.js'; -export * from './url/constants.js'; export * from './validation/constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/index.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/index.ts index 4e403fde93b1..8059abd30dde 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/index.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/index.ts @@ -1,6 +1,5 @@ export { UmbDocumentDetailRepository } from './detail/index.js'; export { UmbDocumentItemRepository } from './item/index.js'; -export { UmbDocumentUrlRepository, UMB_DOCUMENT_URL_REPOSITORY_ALIAS } from './url/index.js'; export { UmbDocumentPreviewRepository } from './preview/index.js'; export * from './constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/manifests.ts index 7c077b7378a1..4dfb0c911f4e 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/manifests.ts @@ -1,5 +1,4 @@ import { manifests as detailManifests } from './detail/manifests.js'; import { manifests as itemManifests } from './item/manifests.js'; -import { manifests as urlManifests } from './url/manifests.js'; -export const manifests: Array = [...detailManifests, ...itemManifests, ...urlManifests]; +export const manifests: Array = [...detailManifests, ...itemManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/constants.ts new file mode 100644 index 000000000000..41a409dec1f0 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/constants.ts @@ -0,0 +1 @@ +export * from './repository/constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/index.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/index.ts new file mode 100644 index 000000000000..03eef61de79a --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/index.ts @@ -0,0 +1,3 @@ +export { UmbDocumentUrlRepository, UMB_DOCUMENT_URL_REPOSITORY_ALIAS } from './repository/index.js'; + +export * from './constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-links.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts similarity index 92% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-links.element.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts index 4024d2297784..21f09008aa2f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-links.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts @@ -1,7 +1,7 @@ -import { UmbDocumentUrlRepository } from '../../../repository/url/document-url.repository.js'; -import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../document-workspace.context-token.js'; -import type { UmbDocumentVariantOptionModel } from '../../../types.js'; -import type { UmbDocumentUrlModel } from '../../../repository/url/types.js'; +import { UmbDocumentUrlRepository } from '../repository/index.js'; +import type { UmbDocumentVariantOptionModel } from '../../types.js'; +import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../workspace/constants.js'; +import type { UmbDocumentUrlModel } from '../repository/types.js'; import { css, customElement, html, nothing, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import type { UmbEntityActionEvent } from '@umbraco-cms/backoffice/entity-action'; @@ -18,8 +18,8 @@ interface UmbDocumentInfoViewLink { state: DocumentVariantStateModel | null | undefined; } -@customElement('umb-document-workspace-view-info-links') -export class UmbDocumentWorkspaceViewInfoLinksElement extends UmbLitElement { +@customElement('umb-document-links-workspace-info-app') +export class UmbDocumentLinksWorkspaceInfoAppElement extends UmbLitElement { #documentUrlRepository = new UmbDocumentUrlRepository(this); @state() @@ -284,10 +284,10 @@ export class UmbDocumentWorkspaceViewInfoLinksElement extends UmbLitElement { ]; } -export default UmbDocumentWorkspaceViewInfoLinksElement; +export default UmbDocumentLinksWorkspaceInfoAppElement; declare global { interface HTMLElementTagNameMap { - 'umb-document-workspace-view-info-links': UmbDocumentWorkspaceViewInfoLinksElement; + 'umb-document-links-workspace-info-app': UmbDocumentLinksWorkspaceInfoAppElement; } } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts new file mode 100644 index 000000000000..7e8a0b5d7d19 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts @@ -0,0 +1,9 @@ +export const manifests: Array = [ + { + type: 'workspaceInfoApp', + name: 'Document Links Workspace Info App', + alias: 'Umb.WorkspaceInfoApp.Document.Links', + element: () => import('./document-links-workspace-info-app.element.js'), + weight: 100, + }, +]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/manifests.ts new file mode 100644 index 000000000000..f241b57605f5 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/manifests.ts @@ -0,0 +1,4 @@ +import { manifests as infoAppManifests } from './info-app/manifests.js'; +import { manifests as repositoryManifests } from './repository/manifests.js'; + +export const manifests: Array = [...repositoryManifests, ...infoAppManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/constants.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/constants.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/constants.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.repository.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.repository.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.repository.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.repository.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.server.data-source.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.server.data-source.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.server.data-source.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.server.data-source.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.store.context-token.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.store.context-token.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.store.context-token.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.store.context-token.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.store.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.store.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/document-url.store.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/document-url.store.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/index.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/index.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/index.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/index.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/manifests.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/manifests.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/manifests.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/types.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/types.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/repository/url/types.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/repository/types.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/utils.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/utils.ts index a7e8ea7e4dd0..3622652b5111 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/utils.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/utils.ts @@ -37,3 +37,12 @@ export const sortVariants = (a: VariantType, b: VariantType) => { return compareDefault(a, b) || compareMandatory(a, b) || compareState(a, b) || compareName(a, b); }; + +export const TimeOptions: Intl.DateTimeFormatOptions = { + year: 'numeric', + month: 'long', + day: 'numeric', + hour: 'numeric', + minute: 'numeric', + second: 'numeric', +}; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/index.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/index.ts new file mode 100644 index 000000000000..5414064f667b --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/index.ts @@ -0,0 +1 @@ +export * from './document-workspace.context-token.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts index 0e7c96dadf9f..81d6954dc4dc 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts @@ -1,7 +1,7 @@ import { UMB_DOCUMENT_PROPERTY_DATASET_CONTEXT, UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../../constants.js'; import type { UmbDocumentVariantModel } from '../../../types.js'; import { UMB_DOCUMENT_PUBLISHING_WORKSPACE_CONTEXT } from '../../../publishing/index.js'; -import { TimeOptions } from './utils.js'; +import { TimeOptions } from '../../../utils.js'; import { css, customElement, html, ifDefined, nothing, state } from '@umbraco-cms/backoffice/external/lit'; import { DocumentVariantStateModel } from '@umbraco-cms/backoffice/external/backend-api'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; @@ -16,8 +16,6 @@ import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backof import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; // import of local components -import './document-workspace-view-info-links.element.js'; -import './document-workspace-view-info-history.element.js'; import './document-workspace-view-info-reference.element.js'; @customElement('umb-document-workspace-view-info') @@ -182,10 +180,9 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { override render() { return html`
- + -
From 4026e03606e2fc3fdd8a09a103af4c19fa94d0bb Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 15:15:56 +0100 Subject: [PATCH 02/20] register references as an extension --- .../document-workspace-view-info-reference.element.ts | 2 +- .../documents/documents/reference/info-app/manifests.ts | 9 +++++++++ .../packages/documents/documents/reference/manifests.ts | 3 ++- .../views/info/document-workspace-view-info.element.ts | 5 ----- 4 files changed, 12 insertions(+), 7 deletions(-) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/{workspace/views/info => reference/info-app}/document-workspace-view-info-reference.element.ts (98%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-reference.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-workspace-view-info-reference.element.ts similarity index 98% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-reference.element.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-workspace-view-info-reference.element.ts index 12cccd21f165..c67233964ae3 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info-reference.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-workspace-view-info-reference.element.ts @@ -1,4 +1,4 @@ -import { UmbDocumentReferenceRepository } from '../../../reference/index.js'; +import { UmbDocumentReferenceRepository } from '../repository/index.js'; import { css, customElement, html, nothing, property, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; import { isDefaultReference, isDocumentReference, isMediaReference } from '@umbraco-cms/backoffice/relations'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts new file mode 100644 index 000000000000..512e58c220b2 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts @@ -0,0 +1,9 @@ +export const manifests: Array = [ + { + type: 'workspaceInfoApp', + name: 'Document References Workspace Info App', + alias: 'Umb.WorkspaceInfoApp.Document.References', + element: () => import('./document-workspace-view-info-reference.element.js'), + weight: 90, + }, +]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/manifests.ts index 4ac6fbdcb2ff..d804039738aa 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/manifests.ts @@ -1,3 +1,4 @@ +import { manifests as infoAppManifests } from './info-app/manifests.js'; import { manifests as repositoryManifests } from './repository/manifests.js'; -export const manifests: Array = [...repositoryManifests]; +export const manifests: Array = [...infoAppManifests, ...repositoryManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts index 81d6954dc4dc..d21a6a2fcd3c 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts @@ -15,9 +15,6 @@ import { createExtensionApiByAlias } from '@umbraco-cms/backoffice/extension-reg import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backoffice/section'; import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; -// import of local components -import './document-workspace-view-info-reference.element.js'; - @customElement('umb-document-workspace-view-info') export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { @state() @@ -181,8 +178,6 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { return html`
-
From 49aae77b8e1862867b357a7e03d86aac297e7791 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 15:18:16 +0100 Subject: [PATCH 03/20] align naming --- ...=> document-references-workspace-view-info.element.ts} | 8 ++++---- .../documents/documents/reference/info-app/manifests.ts | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) rename src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/{document-workspace-view-info-reference.element.ts => document-references-workspace-view-info.element.ts} (95%) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-workspace-view-info-reference.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts similarity index 95% rename from src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-workspace-view-info-reference.element.ts rename to src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts index c67233964ae3..0928d889d352 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-workspace-view-info-reference.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts @@ -8,8 +8,8 @@ import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; import type { UmbReferenceModel } from '@umbraco-cms/backoffice/relations'; import type { UUIPaginationEvent } from '@umbraco-cms/backoffice/external/uui'; -@customElement('umb-document-workspace-view-info-reference') -export class UmbDocumentWorkspaceViewInfoReferenceElement extends UmbLitElement { +@customElement('umb-document-references-workspace-info-app') +export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement { #itemsPerPage = 10; #referenceRepository = new UmbDocumentReferenceRepository(this); @@ -194,10 +194,10 @@ export class UmbDocumentWorkspaceViewInfoReferenceElement extends UmbLitElement ]; } -export default UmbDocumentWorkspaceViewInfoReferenceElement; +export default UmbDocumentReferencesWorkspaceInfoAppElement; declare global { interface HTMLElementTagNameMap { - 'umb-document-workspace-view-info-reference': UmbDocumentWorkspaceViewInfoReferenceElement; + 'umb-document-references-workspace-info-app': UmbDocumentReferencesWorkspaceInfoAppElement; } } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts index 512e58c220b2..d247c9cc05b5 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts @@ -3,7 +3,7 @@ export const manifests: Array = [ type: 'workspaceInfoApp', name: 'Document References Workspace Info App', alias: 'Umb.WorkspaceInfoApp.Document.References', - element: () => import('./document-workspace-view-info-reference.element.js'), + element: () => import('./document-references-workspace-view-info.element.js'), weight: 90, }, ]; From daf2e18cd2aa19a103a5a12800b93ffe0ebf4f43 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 15:55:43 +0100 Subject: [PATCH 04/20] get unique from context --- ...-references-workspace-view-info.element.ts | 48 ++++++++++++++----- 1 file changed, 37 insertions(+), 11 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts index 0928d889d352..682d54114c78 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts @@ -1,5 +1,5 @@ import { UmbDocumentReferenceRepository } from '../repository/index.js'; -import { css, customElement, html, nothing, property, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; +import { css, customElement, html, nothing, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; import { isDefaultReference, isDocumentReference, isMediaReference } from '@umbraco-cms/backoffice/relations'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbTextStyles } from '@umbraco-cms/backoffice/style'; @@ -7,16 +7,11 @@ import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/rou import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; import type { UmbReferenceModel } from '@umbraco-cms/backoffice/relations'; import type { UUIPaginationEvent } from '@umbraco-cms/backoffice/external/uui'; +import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../constants.js'; +import type { UmbEntityUnique } from '@umbraco-cms/backoffice/entity'; @customElement('umb-document-references-workspace-info-app') export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement { - #itemsPerPage = 10; - - #referenceRepository = new UmbDocumentReferenceRepository(this); - - @property() - documentUnique = ''; - @state() private _editDocumentPath = ''; @@ -29,6 +24,11 @@ export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement @state() private _items?: Array = []; + #itemsPerPage = 10; + #referenceRepository = new UmbDocumentReferenceRepository(this); + #documentUnique?: UmbEntityUnique; + #workspaceContext?: typeof UMB_DOCUMENT_WORKSPACE_CONTEXT.TYPE; + constructor() { super(); @@ -40,15 +40,41 @@ export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement .observeRouteBuilder((routeBuilder) => { this._editDocumentPath = routeBuilder({}); }); + + this.consumeContext(UMB_DOCUMENT_WORKSPACE_CONTEXT, (context) => { + this.#workspaceContext = context; + this.#observeDocumentUnique(); + }); } - protected override firstUpdated(): void { - this.#getReferences(); + #observeDocumentUnique() { + this.observe( + this.#workspaceContext?.unique, + (unique) => { + if (!unique) { + this.#documentUnique = undefined; + this._items = []; + return; + } + + if (this.#documentUnique === unique) { + return; + } + + this.#documentUnique = unique; + this.#getReferences(); + }, + 'umbReferencesDocumentUniqueObserver', + ); } async #getReferences() { + if (!this.#documentUnique) { + throw new Error('Document unique is required'); + } + const { data } = await this.#referenceRepository.requestReferencedBy( - this.documentUnique, + this.#documentUnique, (this._currentPage - 1) * this.#itemsPerPage, this.#itemsPerPage, ); From 6a6353d01b6edd71288859b3f1b95d8115afb72c Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 18:50:01 +0100 Subject: [PATCH 05/20] add types for the extension point --- .../info/workspace-info-app.extension.ts | 22 +++++++++++++++++++ .../documents/audit-log/info-app/manifests.ts | 14 +++++++++++- .../documents/reference/info-app/manifests.ts | 12 ++++++++++ .../documents/url/info-app/manifests.ts | 12 ++++++++++ 4 files changed, 59 insertions(+), 1 deletion(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts new file mode 100644 index 000000000000..ee521b1617ff --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts @@ -0,0 +1,22 @@ +import type { ManifestElement, ManifestWithDynamicConditions } from '@umbraco-cms/backoffice/extension-api'; + +export interface UmbWorkspaceInfoAppElement extends HTMLElement { + manifest?: ManifestWorkspaceInfoApp; +} + +export interface ManifestWorkspaceInfoApp + extends ManifestElement, + ManifestWithDynamicConditions { + type: 'workspaceInfoApp'; + meta: MetaWorkspaceInfoApp; +} + +export interface MetaWorkspaceInfoApp { + label: string; +} + +declare global { + interface UmbExtensionManifestMap { + umbWorkspaceInfoApp: ManifestWorkspaceInfoApp; + } +} diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts index 61e712b68949..131be3b069d6 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts @@ -1,9 +1,21 @@ +import { UMB_DOCUMENT_WORKSPACE_ALIAS } from '../../workspace/constants.js'; +import { UMB_WORKSPACE_CONDITION_ALIAS } from '@umbraco-cms/backoffice/workspace'; + export const manifests: Array = [ { type: 'workspaceInfoApp', name: 'Document History Workspace Info App', alias: 'Umb.WorkspaceInfoApp.Document.History', element: () => import('./document-history-workspace-info-app.element.js'), - weight: 90, + weight: 80, + meta: { + label: 'History', + }, + conditions: [ + { + alias: UMB_WORKSPACE_CONDITION_ALIAS, + match: UMB_DOCUMENT_WORKSPACE_ALIAS, + }, + ], }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts index d247c9cc05b5..66cc0d5bb503 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts @@ -1,3 +1,6 @@ +import { UMB_DOCUMENT_WORKSPACE_ALIAS } from '../../workspace/constants.js'; +import { UMB_WORKSPACE_CONDITION_ALIAS } from '@umbraco-cms/backoffice/workspace'; + export const manifests: Array = [ { type: 'workspaceInfoApp', @@ -5,5 +8,14 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Document.References', element: () => import('./document-references-workspace-view-info.element.js'), weight: 90, + meta: { + label: 'References', + }, + conditions: [ + { + alias: UMB_WORKSPACE_CONDITION_ALIAS, + match: UMB_DOCUMENT_WORKSPACE_ALIAS, + }, + ], }, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts index 7e8a0b5d7d19..44285b0f508d 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts @@ -1,3 +1,6 @@ +import { UMB_DOCUMENT_WORKSPACE_ALIAS } from '../../workspace/constants.js'; +import { UMB_WORKSPACE_CONDITION_ALIAS } from '@umbraco-cms/backoffice/workspace'; + export const manifests: Array = [ { type: 'workspaceInfoApp', @@ -5,5 +8,14 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Document.Links', element: () => import('./document-links-workspace-info-app.element.js'), weight: 100, + meta: { + label: 'Links', + }, + conditions: [ + { + alias: UMB_WORKSPACE_CONDITION_ALIAS, + match: UMB_DOCUMENT_WORKSPACE_ALIAS, + }, + ], }, ]; From faf13c3f9e0fc98888945b8b69dc586d73cf51e6 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 18:54:54 +0100 Subject: [PATCH 06/20] localize labels --- .../documents/documents/audit-log/info-app/manifests.ts | 2 +- .../documents/documents/reference/info-app/manifests.ts | 2 +- .../src/packages/documents/documents/url/info-app/manifests.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts index 131be3b069d6..cb9782417bc4 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts @@ -9,7 +9,7 @@ export const manifests: Array = [ element: () => import('./document-history-workspace-info-app.element.js'), weight: 80, meta: { - label: 'History', + label: '#general_history', }, conditions: [ { diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts index 66cc0d5bb503..089ecc6fe4a0 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts @@ -9,7 +9,7 @@ export const manifests: Array = [ element: () => import('./document-references-workspace-view-info.element.js'), weight: 90, meta: { - label: 'References', + label: '#references_labelUsedByItems', }, conditions: [ { diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts index 44285b0f508d..315eb893995f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts @@ -9,7 +9,7 @@ export const manifests: Array = [ element: () => import('./document-links-workspace-info-app.element.js'), weight: 100, meta: { - label: 'Links', + label: '#general_links', }, conditions: [ { From df8da92344a8554a37147c0026624feaf3cb1150 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 20:53:32 +0100 Subject: [PATCH 07/20] wrap apps in a box element --- .../src/packages/core/workspace/info/types.ts | 1 + .../src/packages/core/workspace/types.ts | 7 ++++--- .../document-workspace-view-info.element.ts | 17 +++++++++++++++-- 3 files changed, 20 insertions(+), 5 deletions(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/types.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/types.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/types.ts new file mode 100644 index 000000000000..8b959f66e45a --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/types.ts @@ -0,0 +1 @@ +export type * from './workspace-info-app.extension.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts index 76bb7815af5b..7e0c0fe82e08 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts @@ -1,11 +1,12 @@ import type { UmbEntityUnique } from '@umbraco-cms/backoffice/entity'; -export type * from './extensions/types.js'; -export type * from './kinds/types.js'; export type * from './conditions/types.js'; export type * from './data-manager/types.js'; -export type * from './workspace-context.interface.js'; +export type * from './extensions/types.js'; +export type * from './info/types.js'; +export type * from './kinds/types.js'; export type * from './namable/types.js'; +export type * from './workspace-context.interface.js'; /** * @deprecated Use `UmbEntityUnique`instead. diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts index d21a6a2fcd3c..15521d052be2 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts @@ -7,13 +7,14 @@ import { DocumentVariantStateModel } from '@umbraco-cms/backoffice/external/back import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/router'; import { UMB_MODAL_MANAGER_CONTEXT } from '@umbraco-cms/backoffice/modal'; -import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; +import { UMB_WORKSPACE_MODAL, type ManifestWorkspaceInfoApp } from '@umbraco-cms/backoffice/workspace'; import { UMB_TEMPLATE_PICKER_MODAL, UmbTemplateItemRepository } from '@umbraco-cms/backoffice/template'; import type { UmbDocumentTypeDetailModel } from '@umbraco-cms/backoffice/document-type'; import type { UmbModalRouteBuilder } from '@umbraco-cms/backoffice/router'; import { createExtensionApiByAlias } from '@umbraco-cms/backoffice/extension-registry'; import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backoffice/section'; import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; +import type { UmbExtensionElementInitializer } from '@umbraco-cms/backoffice/extension-api'; @customElement('umb-document-workspace-view-info') export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { @@ -177,7 +178,10 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { override render() { return html`
- +
@@ -187,6 +191,15 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { `; } + #renderInfoApp(initializer: UmbExtensionElementInitializer) { + const headline = initializer.manifest?.meta.label; + return html` + + ${initializer.component} + `; + } + #renderGeneralSection() { const editDocumentTypePath = this._routeBuilder?.({ entityType: 'document-type' }) ?? ''; From 810b7d6de38bbae94b3f3ab47c872928e0130580 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 21:05:03 +0100 Subject: [PATCH 08/20] remove double box containers + adjust styling --- ...ment-history-workspace-info-app.element.ts | 14 ++-- ...-references-workspace-view-info.element.ts | 83 +++++++++---------- ...cument-links-workspace-info-app.element.ts | 12 ++- .../document-workspace-view-info.element.ts | 4 +- 4 files changed, 58 insertions(+), 55 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts index ec900a351dd1..208ead1d2ec2 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts @@ -99,19 +99,18 @@ export class UmbDocumentHistoryWorkspaceInfoAppElement extends UmbLitElement { override render() { return html` - - this.#allowedActions.has(manifest.alias)}> - + .filter=${(manifest: ManifestEntityAction) => + this.#allowedActions.has(manifest.alias)}> + ${when( this._items, () => this.#renderHistory(), () => html`
`, )} ${this.#renderPagination()} -
`; } @@ -163,6 +162,11 @@ export class UmbDocumentHistoryWorkspaceInfoAppElement extends UmbLitElement { static override styles = [ UmbTextStyles, css` + :host { + display: block; + padding: var(--uui-size-space-4) var(--uui-size-space-5); + } + #loader { display: flex; justify-content: center; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts index 682d54114c78..789efc0d632d 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts @@ -137,48 +137,46 @@ export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement override render() { if (!this._items?.length) return nothing; return html` - - - - - Name - Status - Type Name - Type - - ${repeat( - this._items, - (item) => item.id, - (item) => html` - - - - - - ${when( - isDocumentReference(item), - () => html` - - ${item.name} - - `, - () => item.name, - )} - - - ${this.#getPublishedStatus(item) - ? this.localize.term('content_published') - : this.localize.term('content_unpublished')} - - ${this.#getContentTypeName(item)} - ${this.#getContentType(item)} - - `, - )} - - + + + + Name + Status + Type Name + Type + + ${repeat( + this._items, + (item) => item.id, + (item) => html` + + + + + + ${when( + isDocumentReference(item), + () => html` + + ${item.name} + + `, + () => item.name, + )} + + + ${this.#getPublishedStatus(item) + ? this.localize.term('content_published') + : this.localize.term('content_unpublished')} + + ${this.#getContentTypeName(item)} + ${this.#getContentType(item)} + + `, + )} + ${this.#renderReferencePagination()} `; } @@ -202,6 +200,7 @@ export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement :host { display: contents; } + uui-table-cell:not(.link-cell) { color: var(--uui-color-text-alt); } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts index 21f09008aa2f..a7723cd80130 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts @@ -155,13 +155,11 @@ export class UmbDocumentLinksWorkspaceInfoAppElement extends UmbLitElement { override render() { return html` - - ${when( - this._loading, - () => this.#renderLoading(), - () => this.#renderContent(), - )} - + ${when( + this._loading, + () => this.#renderLoading(), + () => this.#renderContent(), + )} `; } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts index 15521d052be2..ff740f699be1 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts @@ -194,7 +194,9 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { #renderInfoApp(initializer: UmbExtensionElementInitializer) { const headline = initializer.manifest?.meta.label; return html` - + ${initializer.component} `; From dc7f02f1216b3cebc70f362f9deaf54ec5b03b3d Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 16 Jan 2025 22:25:39 +0100 Subject: [PATCH 09/20] register media history --- .../media/audit-log/info-app/manifests.ts | 21 +++++++++++++ ...dia-history-workspace-info-app.element.ts} | 16 +++++----- .../info => audit-log/info-app}/utils.ts | 4 +-- .../media/media/audit-log/manifests.ts | 3 ++ .../src/packages/media/media/manifests.ts | 6 ++-- .../info/media-workspace-view-info.element.ts | 30 +++++++++++-------- 6 files changed, 56 insertions(+), 24 deletions(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts rename src/Umbraco.Web.UI.Client/src/packages/media/media/{workspace/views/info/media-workspace-view-info-history.element.ts => audit-log/info-app/media-history-workspace-info-app.element.ts} (89%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{workspace/views/info => audit-log/info-app}/utils.ts (87%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/manifests.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts new file mode 100644 index 000000000000..ff6482b7d789 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts @@ -0,0 +1,21 @@ +import { UMB_MEDIA_WORKSPACE_ALIAS } from '../../workspace/constants.js'; +import { UMB_WORKSPACE_CONDITION_ALIAS } from '@umbraco-cms/backoffice/workspace'; + +export const manifests: Array = [ + { + type: 'workspaceInfoApp', + name: 'Media History Workspace Info App', + alias: 'Umb.WorkspaceInfoApp.Media.History', + element: () => import('./media-history-workspace-info-app.element.js'), + weight: 80, + meta: { + label: '#general_history', + }, + conditions: [ + { + alias: UMB_WORKSPACE_CONDITION_ALIAS, + match: UMB_MEDIA_WORKSPACE_ALIAS, + }, + ], + }, +]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info-history.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts similarity index 89% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info-history.element.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts index 33ac9a609fa1..143857a715c1 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info-history.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts @@ -1,7 +1,7 @@ -import type { UmbMediaAuditLogModel } from '../../../audit-log/types.js'; -import { UmbMediaAuditLogRepository } from '../../../audit-log/index.js'; -import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../media-workspace.context-token.js'; -import { TimeOptions, getMediaHistoryTagStyleAndText } from './utils.js'; +import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../workspace/constants.js'; +import type { UmbMediaAuditLogModel } from '../types.js'; +import { UmbMediaAuditLogRepository } from '../repository/index.js'; +import { getMediaHistoryTagStyleAndText, TimeOptions } from './utils.js'; import { css, html, customElement, state, nothing, repeat } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbTextStyles } from '@umbraco-cms/backoffice/style'; @@ -10,8 +10,8 @@ import type { UUIPaginationEvent } from '@umbraco-cms/backoffice/external/uui'; import type { UmbUserItemModel } from '@umbraco-cms/backoffice/user'; import { UmbUserItemRepository } from '@umbraco-cms/backoffice/user'; -@customElement('umb-media-workspace-view-info-history') -export class UmbMediaWorkspaceViewInfoHistoryElement extends UmbLitElement { +@customElement('umb-media-history-workspace-info-app') +export class UmbMediaHistoryWorkspaceInfoAppElement extends UmbLitElement { @state() _currentPageNumber = 1; @@ -172,10 +172,10 @@ export class UmbMediaWorkspaceViewInfoHistoryElement extends UmbLitElement { ]; } -export default UmbMediaWorkspaceViewInfoHistoryElement; +export default UmbMediaHistoryWorkspaceInfoAppElement; declare global { interface HTMLElementTagNameMap { - 'umb-media-workspace-view-info-history': UmbMediaWorkspaceViewInfoHistoryElement; + 'umb-media-workspace-view-info-history': UmbMediaHistoryWorkspaceInfoAppElement; } } diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/utils.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/utils.ts similarity index 87% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/utils.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/utils.ts index f4290ab2c017..e410f350d42c 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/utils.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/utils.ts @@ -1,5 +1,5 @@ -import type { UmbMediaAuditLogType } from '../../../audit-log/utils/index.js'; -import { UmbMediaAuditLog } from '../../../audit-log/utils/index.js'; +import type { UmbMediaAuditLogType } from '../utils/index.js'; +import { UmbMediaAuditLog } from '../utils/index.js'; interface HistoryStyleMap { look: 'default' | 'primary' | 'secondary' | 'outline' | 'placeholder'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/manifests.ts new file mode 100644 index 000000000000..c72138184b5a --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/manifests.ts @@ -0,0 +1,3 @@ +import { manifests as infoAppManifests } from './info-app/manifests.js'; + +export const manifests: Array = [...infoAppManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts index d6f8ad84e405..b71f13222876 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts @@ -1,7 +1,9 @@ +import { manifests as auditLogManifests } from './audit-log/manifests.js'; import { manifests as collectionManifests } from './collection/manifests.js'; import { manifests as dropzoneManifests } from './dropzone/manifests.js'; import { manifests as entityActionsManifests } from './entity-actions/manifests.js'; import { manifests as entityBulkActionsManifests } from './entity-bulk-actions/manifests.js'; +import { manifests as fileUploadPreviewManifests } from './components/input-upload-field/manifests.js'; import { manifests as menuManifests } from './menu/manifests.js'; import { manifests as modalManifests } from './modals/manifests.js'; import { manifests as propertyEditorsManifests } from './property-editors/manifests.js'; @@ -11,13 +13,14 @@ import { manifests as searchManifests } from './search/manifests.js'; import { manifests as sectionViewManifests } from './dashboard/manifests.js'; import { manifests as treeManifests } from './tree/manifests.js'; import { manifests as workspaceManifests } from './workspace/manifests.js'; -import { manifests as fileUploadPreviewManifests } from './components/input-upload-field/manifests.js'; export const manifests: Array = [ + ...auditLogManifests, ...collectionManifests, ...dropzoneManifests, ...entityActionsManifests, ...entityBulkActionsManifests, + ...fileUploadPreviewManifests, ...menuManifests, ...modalManifests, ...propertyEditorsManifests, @@ -27,5 +30,4 @@ export const manifests: Array = [ ...sectionViewManifests, ...treeManifests, ...workspaceManifests, - ...fileUploadPreviewManifests, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts index c79e95d0f4c3..32a3d387712b 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts @@ -1,20 +1,20 @@ import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../media-workspace.context-token.js'; -import { TimeOptions } from './utils.js'; +import { TimeOptions } from '../../../audit-log/info-app/utils.js'; import { css, customElement, html, ifDefined, nothing, repeat, state } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import type { UmbMediaTypeItemModel } from '@umbraco-cms/backoffice/media-type'; import { UMB_MEDIA_TYPE_ENTITY_TYPE, UmbMediaTypeItemRepository } from '@umbraco-cms/backoffice/media-type'; import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/router'; import { UmbTextStyles } from '@umbraco-cms/backoffice/style'; -import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; +import { UMB_WORKSPACE_MODAL, type ManifestWorkspaceInfoApp } from '@umbraco-cms/backoffice/workspace'; import type { MediaUrlInfoModel } from '@umbraco-cms/backoffice/external/backend-api'; import { createExtensionApiByAlias } from '@umbraco-cms/backoffice/extension-registry'; import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backoffice/section'; import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; // import of local components -import './media-workspace-view-info-history.element.js'; import './media-workspace-view-info-reference.element.js'; +import type { UmbExtensionElementInitializer } from '@umbraco-cms/backoffice/extension-api'; @customElement('umb-media-workspace-view-info') export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { @@ -130,15 +130,10 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { override render() { return html`
- - - - - - - +
) { + const headline = initializer.manifest?.meta.label; + return html` + + ${initializer.component} + `; + } + #renderGeneralSection() { return html` ${this.#renderCreateDate()} ${this.#renderUpdateDate()} From 61c3f529e559c81b12b32cd38a7e199f6c5be720 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 17 Jan 2025 08:43:42 +0100 Subject: [PATCH 10/20] move url files into folder --- .../media/imaging/components/media-image.element.ts | 2 +- .../media-history-workspace-info-app.element.ts | 12 +++++++----- .../src/packages/media/media/constants.ts | 1 + .../src/packages/media/media/index.ts | 3 ++- .../src/packages/media/media/manifests.ts | 2 ++ .../image-cropper-editor-modal.element.ts | 2 +- .../src/packages/media/media/repository/constants.ts | 1 - .../src/packages/media/media/repository/index.ts | 1 - .../src/packages/media/media/repository/manifests.ts | 8 +------- .../src/packages/media/media/repository/types.ts | 1 - .../src/packages/media/media/types.ts | 3 ++- .../src/packages/media/media/url/constants.ts | 1 + .../src/packages/media/media/url/index.ts | 1 + .../src/packages/media/media/url/manifests.ts | 3 +++ .../{repository/url => url/repository}/constants.ts | 0 .../{repository/url => url/repository}/index.ts | 0 .../{repository/url => url/repository}/manifests.ts | 0 .../url => url/repository}/media-url.repository.ts | 0 .../repository}/media-url.server.data-source.ts | 0 .../repository}/media-url.store.context-token.ts | 0 .../url => url/repository}/media-url.store.ts | 0 .../{repository/url => url/repository}/types.ts | 0 .../src/packages/media/media/url/types.ts | 1 + .../utils/all-umb-consts/index.ts | 4 ++-- 24 files changed, 25 insertions(+), 21 deletions(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/url/constants.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/url/index.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/constants.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/index.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/manifests.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/media-url.repository.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/media-url.server.data-source.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/media-url.store.context-token.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/media-url.store.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/media/media/{repository/url => url/repository}/types.ts (100%) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/url/types.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/imaging/components/media-image.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/imaging/components/media-image.element.ts index c81596b112b4..517bfab56b77 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/imaging/components/media-image.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/imaging/components/media-image.element.ts @@ -1,4 +1,4 @@ -import { UmbMediaUrlRepository } from '../../media/repository/index.js'; +import { UmbMediaUrlRepository } from '../../media/url/index.js'; import { css, customElement, html, nothing, property, state, when } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbTextStyles } from '@umbraco-cms/backoffice/style'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts index 143857a715c1..9b1d8104f312 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts @@ -83,13 +83,10 @@ export class UmbMediaHistoryWorkspaceInfoAppElement extends UmbLitElement { } override render() { - return html` -
-

History

-
+ return html` ${this._items ? this.#renderHistory() : html` `} ${this.#renderPagination()} -
`; + `; } #renderHistory() { @@ -145,6 +142,11 @@ export class UmbMediaHistoryWorkspaceInfoAppElement extends UmbLitElement { static override styles = [ UmbTextStyles, css` + :host { + display: block; + padding: var(--uui-size-space-4) var(--uui-size-space-5); + } + uui-loader-circle { font-size: 2rem; } diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/constants.ts index ef2d8e44dfe8..e873149ff56e 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/constants.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/constants.ts @@ -8,6 +8,7 @@ export * from './recycle-bin/constants.js'; export * from './reference/constants.js'; export * from './repository/constants.js'; export * from './tree/constants.js'; +export * from './url/constants.js'; export * from './workspace/constants.js'; export * from './paths.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/index.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/index.ts index 377c05b6dc47..f9957ebb0d9b 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/index.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/index.ts @@ -1,9 +1,10 @@ export * from './components/index.js'; -export * from './dropzone/index.js'; export * from './constants.js'; +export * from './dropzone/index.js'; export * from './reference/index.js'; export * from './repository/index.js'; export * from './search/index.js'; +export * from './url/index.js'; export * from './utils/index.js'; export { UmbMediaAuditLogRepository } from './audit-log/index.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts index b71f13222876..2bd839ad4225 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts @@ -12,6 +12,7 @@ import { manifests as repositoryManifests } from './repository/manifests.js'; import { manifests as searchManifests } from './search/manifests.js'; import { manifests as sectionViewManifests } from './dashboard/manifests.js'; import { manifests as treeManifests } from './tree/manifests.js'; +import { manifests as urlManifests } from './url/manifests.js'; import { manifests as workspaceManifests } from './workspace/manifests.js'; export const manifests: Array = [ @@ -29,5 +30,6 @@ export const manifests: Array = [ ...searchManifests, ...sectionViewManifests, ...treeManifests, + ...urlManifests, ...workspaceManifests, ]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/modals/image-cropper-editor/image-cropper-editor-modal.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/modals/image-cropper-editor/image-cropper-editor-modal.element.ts index 33a7bbfa082d..cd2b11c38830 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/modals/image-cropper-editor/image-cropper-editor-modal.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/modals/image-cropper-editor/image-cropper-editor-modal.element.ts @@ -1,8 +1,8 @@ -import { UmbMediaUrlRepository } from '../../repository/index.js'; import { UMB_MEDIA_PICKER_MODAL } from '../media-picker/media-picker-modal.token.js'; import type { UmbCropModel } from '../../types.js'; import type { UmbInputImageCropperFieldElement } from '../../components/input-image-cropper/image-cropper-field.element.js'; import type { UmbImageCropperPropertyEditorValue } from '../../components/index.js'; +import { UmbMediaUrlRepository } from '../../url/index.js'; import type { UmbImageCropperEditorModalData, UmbImageCropperEditorModalValue, diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/constants.ts index 655e81e66dd1..7a6c4a9d9c73 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/constants.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/constants.ts @@ -1,4 +1,3 @@ export * from './detail/constants.js'; export * from './item/constants.js'; -export * from './url/constants.js'; export * from './validation/constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/index.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/index.ts index 034f9d529ba5..d55093c76181 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/index.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/index.ts @@ -1,3 +1,2 @@ export { UmbMediaDetailRepository } from './detail/index.js'; export { UmbMediaItemRepository } from './item/index.js'; -export { UmbMediaUrlRepository } from './url/index.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/manifests.ts index 62a6814b7013..74a3121896bb 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/manifests.ts @@ -1,11 +1,5 @@ import { manifests as detailManifests } from './detail/manifests.js'; import { manifests as itemManifests } from './item/manifests.js'; -import { manifests as urlManifests } from './url/manifests.js'; import { manifests as validationManifests } from './validation/manifests.js'; -export const manifests: Array = [ - ...detailManifests, - ...itemManifests, - ...urlManifests, - ...validationManifests, -]; +export const manifests: Array = [...detailManifests, ...itemManifests, ...validationManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/types.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/types.ts index 6988c782f6df..3c4135818c76 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/types.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/types.ts @@ -1,2 +1 @@ -export type { UmbMediaUrlModel } from './url/types.js'; export type { UmbMediaItemModel } from './item/types.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/types.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/types.ts index ade991b00fc2..c9545de5a05e 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/types.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/types.ts @@ -6,11 +6,12 @@ import type { UmbContentDetailModel, UmbElementValueModel } from '@umbraco-cms/b export type * from './audit-log/types.js'; export type * from './collection/types.js'; export type * from './dropzone/types.js'; -export type * from './recycle-bin/types.js'; export type * from './modals/types.js'; +export type * from './recycle-bin/types.js'; export type * from './repository/types.js'; export type * from './search/types.js'; export type * from './tree/types.js'; +export type * from './url/types.js'; export interface UmbMediaDetailModel extends UmbContentDetailModel { mediaType: { diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/constants.ts new file mode 100644 index 000000000000..41a409dec1f0 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/constants.ts @@ -0,0 +1 @@ +export * from './repository/constants.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/index.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/index.ts new file mode 100644 index 000000000000..3d76f338dddc --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/index.ts @@ -0,0 +1 @@ +export * from './repository/index.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts new file mode 100644 index 000000000000..4ac6fbdcb2ff --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts @@ -0,0 +1,3 @@ +import { manifests as repositoryManifests } from './repository/manifests.js'; + +export const manifests: Array = [...repositoryManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/constants.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/constants.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/constants.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/constants.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/index.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/index.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/index.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/index.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/manifests.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/manifests.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/manifests.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.repository.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.repository.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.repository.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.repository.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.server.data-source.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.server.data-source.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.server.data-source.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.server.data-source.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.store.context-token.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.store.context-token.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.store.context-token.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.store.context-token.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.store.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.store.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/media-url.store.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/media-url.store.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/types.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/types.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/repository/url/types.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/url/repository/types.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/types.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/types.ts new file mode 100644 index 000000000000..e32ac4b889fe --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/types.ts @@ -0,0 +1 @@ +export type * from './repository/types.js'; diff --git a/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts b/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts index e8d76f2d6502..1b53a43a1f02 100644 --- a/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts +++ b/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts @@ -140,7 +140,7 @@ export const foundConsts = [{ }, { path: '@umbraco-cms/backoffice/document', - consts: ["UMB_DOCUMENT_COLLECTION_ALIAS","UMB_DOCUMENT_COLLECTION_CONTEXT","UMB_DOCUMENT_COLLECTION_REPOSITORY_ALIAS","UMB_DOCUMENT_GRID_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_TABLE_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_CREATE_OPTIONS_MODAL","UMB_CREATE_BLUEPRINT_MODAL","UMB_DOCUMENT_CREATE_BLUEPRINT_REPOSITORY_ALIAS","UMB_CULTURE_AND_HOSTNAMES_MODAL","UMB_DOCUMENT_CULTURE_AND_HOSTNAMES_REPOSITORY_ALIAS","UMB_DUPLICATE_DOCUMENT_MODAL","UMB_DUPLICATE_DOCUMENT_MODAL_ALIAS","UMB_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_MODAL","UMB_DOCUMENT_NOTIFICATIONS_MODAL_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_REPOSITORY_ALIAS","UMB_PUBLIC_ACCESS_MODAL","UMB_DOCUMENT_PUBLIC_ACCESS_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_TRASH_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_ENTITY_TYPE","UMB_DOCUMENT_ROOT_ENTITY_TYPE","UMB_DOCUMENT_CONFIGURATION_CONTEXT","UMB_CONTENT_MENU_ALIAS","UMB_DOCUMENT_PICKER_MODAL","UMB_DOCUMENT_SAVE_MODAL","UMB_DOCUMENT_SAVE_MODAL_ALIAS","UMB_DOCUMENT_WORKSPACE_PATH","UMB_CREATE_FROM_BLUEPRINT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_CREATE_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_EDIT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_DOCUMENT_PROPERTY_DATASET_CONTEXT","UMB_DOCUMENT_PUBLISH_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_MODAL","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL","UMB_DOCUMENT_PUBLISHING_REPOSITORY_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL","UMB_DOCUMENT_UNPUBLISH_MODAL_ALIAS","UMB_DOCUMENT_UNPUBLISH_MODAL","UMB_DOCUMENT_PUBLISHING_WORKSPACE_CONTEXT","UMB_DOCUMENT_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_DOCUMENT_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_DOCUMENT_REFERENCE_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_STORE_ALIAS","UMB_DOCUMENT_DETAIL_STORE_CONTEXT","UMB_DOCUMENT_ITEM_REPOSITORY_ALIAS","UMB_DOCUMENT_STORE_ALIAS","UMB_DOCUMENT_ITEM_STORE_CONTEXT","UMB_DOCUMENT_URL_REPOSITORY_ALIAS","UMB_DOCUMENT_URL_STORE_ALIAS","UMB_DOCUMENT_URL_STORE_CONTEXT","UMB_DOCUMENT_VALIDATION_REPOSITORY_ALIAS","UMB_ROLLBACK_MODAL_ALIAS","UMB_ROLLBACK_MODAL","UMB_ROLLBACK_REPOSITORY_ALIAS","UMB_DOCUMENT_SEARCH_PROVIDER_ALIAS","UMB_DOCUMENT_TREE_STORE_CONTEXT","UMB_DOCUMENT_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_TREE_STORE_ALIAS","UMB_DOCUMENT_TREE_ALIAS","UMB_DOCUMENT_USER_PERMISSION_CONDITION_ALIAS","UMB_USER_PERMISSION_DOCUMENT_CREATE","UMB_USER_PERMISSION_DOCUMENT_READ","UMB_USER_PERMISSION_DOCUMENT_UPDATE","UMB_USER_PERMISSION_DOCUMENT_DELETE","UMB_USER_PERMISSION_DOCUMENT_CREATE_BLUEPRINT","UMB_USER_PERMISSION_DOCUMENT_NOTIFICATIONS","UMB_USER_PERMISSION_DOCUMENT_PUBLISH","UMB_USER_PERMISSION_DOCUMENT_PERMISSIONS","UMB_USER_PERMISSION_DOCUMENT_UNPUBLISH","UMB_USER_PERMISSION_DOCUMENT_DUPLICATE","UMB_USER_PERMISSION_DOCUMENT_MOVE","UMB_USER_PERMISSION_DOCUMENT_SORT","UMB_USER_PERMISSION_DOCUMENT_CULTURE_AND_HOSTNAMES","UMB_USER_PERMISSION_DOCUMENT_PUBLIC_ACCESS","UMB_USER_PERMISSION_DOCUMENT_ROLLBACK","UMB_DOCUMENT_PERMISSION_REPOSITORY_ALIAS","UMB_DOCUMENT_IS_NOT_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_IS_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_WORKSPACE_ALIAS","UMB_DOCUMENT_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_DOCUMENT_WORKSPACE_CONTEXT"] + consts: ["UMB_DOCUMENT_COLLECTION_ALIAS","UMB_DOCUMENT_COLLECTION_CONTEXT","UMB_DOCUMENT_COLLECTION_REPOSITORY_ALIAS","UMB_DOCUMENT_GRID_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_TABLE_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_CREATE_OPTIONS_MODAL","UMB_CREATE_BLUEPRINT_MODAL","UMB_DOCUMENT_CREATE_BLUEPRINT_REPOSITORY_ALIAS","UMB_CULTURE_AND_HOSTNAMES_MODAL","UMB_DOCUMENT_CULTURE_AND_HOSTNAMES_REPOSITORY_ALIAS","UMB_DUPLICATE_DOCUMENT_MODAL","UMB_DUPLICATE_DOCUMENT_MODAL_ALIAS","UMB_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_MODAL","UMB_DOCUMENT_NOTIFICATIONS_MODAL_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_REPOSITORY_ALIAS","UMB_PUBLIC_ACCESS_MODAL","UMB_DOCUMENT_PUBLIC_ACCESS_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_TRASH_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_ENTITY_TYPE","UMB_DOCUMENT_ROOT_ENTITY_TYPE","UMB_DOCUMENT_CONFIGURATION_CONTEXT","UMB_CONTENT_MENU_ALIAS","UMB_DOCUMENT_PICKER_MODAL","UMB_DOCUMENT_SAVE_MODAL","UMB_DOCUMENT_SAVE_MODAL_ALIAS","UMB_DOCUMENT_WORKSPACE_PATH","UMB_CREATE_FROM_BLUEPRINT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_CREATE_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_EDIT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_DOCUMENT_PROPERTY_DATASET_CONTEXT","UMB_DOCUMENT_PUBLISH_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_MODAL","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL","UMB_DOCUMENT_PUBLISHING_REPOSITORY_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL","UMB_DOCUMENT_UNPUBLISH_MODAL_ALIAS","UMB_DOCUMENT_UNPUBLISH_MODAL","UMB_DOCUMENT_PUBLISHING_WORKSPACE_CONTEXT","UMB_DOCUMENT_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_DOCUMENT_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_DOCUMENT_REFERENCE_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_STORE_ALIAS","UMB_DOCUMENT_DETAIL_STORE_CONTEXT","UMB_DOCUMENT_ITEM_REPOSITORY_ALIAS","UMB_DOCUMENT_STORE_ALIAS","UMB_DOCUMENT_ITEM_STORE_CONTEXT","UMB_DOCUMENT_VALIDATION_REPOSITORY_ALIAS","UMB_ROLLBACK_MODAL_ALIAS","UMB_ROLLBACK_MODAL","UMB_ROLLBACK_REPOSITORY_ALIAS","UMB_DOCUMENT_SEARCH_PROVIDER_ALIAS","UMB_DOCUMENT_TREE_STORE_CONTEXT","UMB_DOCUMENT_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_TREE_STORE_ALIAS","UMB_DOCUMENT_TREE_ALIAS","UMB_DOCUMENT_URL_REPOSITORY_ALIAS","UMB_DOCUMENT_URL_STORE_ALIAS","UMB_DOCUMENT_URL_STORE_CONTEXT","UMB_DOCUMENT_USER_PERMISSION_CONDITION_ALIAS","UMB_USER_PERMISSION_DOCUMENT_CREATE","UMB_USER_PERMISSION_DOCUMENT_READ","UMB_USER_PERMISSION_DOCUMENT_UPDATE","UMB_USER_PERMISSION_DOCUMENT_DELETE","UMB_USER_PERMISSION_DOCUMENT_CREATE_BLUEPRINT","UMB_USER_PERMISSION_DOCUMENT_NOTIFICATIONS","UMB_USER_PERMISSION_DOCUMENT_PUBLISH","UMB_USER_PERMISSION_DOCUMENT_PERMISSIONS","UMB_USER_PERMISSION_DOCUMENT_UNPUBLISH","UMB_USER_PERMISSION_DOCUMENT_DUPLICATE","UMB_USER_PERMISSION_DOCUMENT_MOVE","UMB_USER_PERMISSION_DOCUMENT_SORT","UMB_USER_PERMISSION_DOCUMENT_CULTURE_AND_HOSTNAMES","UMB_USER_PERMISSION_DOCUMENT_PUBLIC_ACCESS","UMB_USER_PERMISSION_DOCUMENT_ROLLBACK","UMB_DOCUMENT_PERMISSION_REPOSITORY_ALIAS","UMB_DOCUMENT_IS_NOT_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_IS_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_WORKSPACE_ALIAS","UMB_DOCUMENT_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_DOCUMENT_WORKSPACE_CONTEXT"] }, { path: '@umbraco-cms/backoffice/entity-action', @@ -212,7 +212,7 @@ export const foundConsts = [{ }, { path: '@umbraco-cms/backoffice/media', - consts: ["UMB_MEDIA_COLLECTION_ALIAS","UMB_MEDIA_COLLECTION_CONTEXT","UMB_MEDIA_COLLECTION_REPOSITORY_ALIAS","UMB_MEDIA_GRID_COLLECTION_VIEW_ALIAS","UMB_MEDIA_TABLE_COLLECTION_VIEW_ALIAS","UMB_DROPZONE_MEDIA_TYPE_PICKER_MODAL","UMB_MEDIA_CREATE_OPTIONS_MODAL","UMB_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_MEDIA_REPOSITORY_ALIAS","UMB_BULK_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_BULK_TRASH_MEDIA_REPOSITORY_ALIAS","UMB_MEDIA_ENTITY_TYPE","UMB_MEDIA_ROOT_ENTITY_TYPE","UMB_MEDIA_PLACEHOLDER_ENTITY_TYPE","UMB_MEDIA_MENU_ALIAS","UMB_IMAGE_CROPPER_EDITOR_MODAL","UMB_MEDIA_CAPTION_ALT_TEXT_MODAL","UMB_MEDIA_PICKER_MODAL","UMB_MEDIA_WORKSPACE_PATH","UMB_CREATE_MEDIA_WORKSPACE_PATH_PATTERN","UMB_EDIT_MEDIA_WORKSPACE_PATH_PATTERN","UMB_MEDIA_VARIANT_CONTEXT","UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_MEDIA_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_MEDIA_REFERENCE_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_STORE_ALIAS","UMB_MEDIA_DETAIL_STORE_CONTEXT","UMB_MEDIA_ITEM_REPOSITORY_ALIAS","UMB_MEDIA_STORE_ALIAS","UMB_MEDIA_ITEM_STORE_CONTEXT","UMB_MEDIA_URL_REPOSITORY_ALIAS","UMB_MEDIA_URL_STORE_ALIAS","UMB_MEDIA_URL_STORE_CONTEXT","UMB_MEDIA_VALIDATION_REPOSITORY_ALIAS","UMB_MEDIA_TREE_REPOSITORY_ALIAS","UMB_MEDIA_TREE_STORE_ALIAS","UMB_MEDIA_TREE_ALIAS","UMB_MEDIA_TREE_PICKER_MODAL","UMB_MEDIA_TREE_STORE_CONTEXT","UMB_MEDIA_WORKSPACE_ALIAS","UMB_MEMBER_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_MEDIA_WORKSPACE_CONTEXT"] + consts: ["UMB_MEDIA_COLLECTION_ALIAS","UMB_MEDIA_COLLECTION_CONTEXT","UMB_MEDIA_COLLECTION_REPOSITORY_ALIAS","UMB_MEDIA_GRID_COLLECTION_VIEW_ALIAS","UMB_MEDIA_TABLE_COLLECTION_VIEW_ALIAS","UMB_DROPZONE_MEDIA_TYPE_PICKER_MODAL","UMB_MEDIA_CREATE_OPTIONS_MODAL","UMB_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_MEDIA_REPOSITORY_ALIAS","UMB_BULK_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_BULK_TRASH_MEDIA_REPOSITORY_ALIAS","UMB_MEDIA_ENTITY_TYPE","UMB_MEDIA_ROOT_ENTITY_TYPE","UMB_MEDIA_PLACEHOLDER_ENTITY_TYPE","UMB_MEDIA_MENU_ALIAS","UMB_IMAGE_CROPPER_EDITOR_MODAL","UMB_MEDIA_CAPTION_ALT_TEXT_MODAL","UMB_MEDIA_PICKER_MODAL","UMB_MEDIA_WORKSPACE_PATH","UMB_CREATE_MEDIA_WORKSPACE_PATH_PATTERN","UMB_EDIT_MEDIA_WORKSPACE_PATH_PATTERN","UMB_MEDIA_VARIANT_CONTEXT","UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_MEDIA_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_MEDIA_REFERENCE_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_STORE_ALIAS","UMB_MEDIA_DETAIL_STORE_CONTEXT","UMB_MEDIA_ITEM_REPOSITORY_ALIAS","UMB_MEDIA_STORE_ALIAS","UMB_MEDIA_ITEM_STORE_CONTEXT","UMB_MEDIA_VALIDATION_REPOSITORY_ALIAS","UMB_MEDIA_TREE_REPOSITORY_ALIAS","UMB_MEDIA_TREE_STORE_ALIAS","UMB_MEDIA_TREE_ALIAS","UMB_MEDIA_TREE_PICKER_MODAL","UMB_MEDIA_TREE_STORE_CONTEXT","UMB_MEDIA_URL_REPOSITORY_ALIAS","UMB_MEDIA_URL_STORE_ALIAS","UMB_MEDIA_URL_STORE_CONTEXT","UMB_MEDIA_WORKSPACE_ALIAS","UMB_MEMBER_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_MEDIA_WORKSPACE_CONTEXT"] }, { path: '@umbraco-cms/backoffice/member-group', From a9039389f4ef3885de74358edc6b9b1f28eb5113 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 17 Jan 2025 09:28:05 +0100 Subject: [PATCH 11/20] register references --- .../src/packages/media/media/manifests.ts | 2 + .../media/reference/info-app/manifests.ts | 21 ++++++++ ...-references-workspace-info-app.element.ts} | 52 +++++++++++++++---- .../media/media/reference/manifests.ts | 3 +- .../info/media-workspace-view-info.element.ts | 3 -- 5 files changed, 67 insertions(+), 14 deletions(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts rename src/Umbraco.Web.UI.Client/src/packages/media/media/{workspace/views/info/media-workspace-view-info-reference.element.ts => reference/info-app/media-references-workspace-info-app.element.ts} (81%) diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts index 2bd839ad4225..1b61cda60755 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/manifests.ts @@ -8,6 +8,7 @@ import { manifests as menuManifests } from './menu/manifests.js'; import { manifests as modalManifests } from './modals/manifests.js'; import { manifests as propertyEditorsManifests } from './property-editors/manifests.js'; import { manifests as recycleBinManifests } from './recycle-bin/manifests.js'; +import { manifests as referenceManifests } from './reference/manifests.js'; import { manifests as repositoryManifests } from './repository/manifests.js'; import { manifests as searchManifests } from './search/manifests.js'; import { manifests as sectionViewManifests } from './dashboard/manifests.js'; @@ -26,6 +27,7 @@ export const manifests: Array = [ ...modalManifests, ...propertyEditorsManifests, ...recycleBinManifests, + ...referenceManifests, ...repositoryManifests, ...searchManifests, ...sectionViewManifests, diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts new file mode 100644 index 000000000000..692057ac2558 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts @@ -0,0 +1,21 @@ +import { UMB_MEDIA_WORKSPACE_ALIAS } from '../../workspace/constants.js'; +import { UMB_WORKSPACE_CONDITION_ALIAS } from '@umbraco-cms/backoffice/workspace'; + +export const manifests: Array = [ + { + type: 'workspaceInfoApp', + name: 'Media References Workspace Info App', + alias: 'Umb.WorkspaceInfoApp.Media.References', + element: () => import('./media-references-workspace-info-app.element.js'), + weight: 80, + meta: { + label: '#references_labelUsedByItems', + }, + conditions: [ + { + alias: UMB_WORKSPACE_CONDITION_ALIAS, + match: UMB_MEDIA_WORKSPACE_ALIAS, + }, + ], + }, +]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info-reference.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts similarity index 81% rename from src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info-reference.element.ts rename to src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts index 4f9aaa6bb868..0e43ff261080 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info-reference.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts @@ -1,5 +1,6 @@ -import { UmbMediaReferenceRepository } from '../../../reference/index.js'; -import { css, customElement, html, nothing, property, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; +import { UmbMediaReferenceRepository } from '../repository/index.js'; +import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../workspace/constants.js'; +import { css, customElement, html, nothing, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; import { isDefaultReference, isDocumentReference, isMediaReference } from '@umbraco-cms/backoffice/relations'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/router'; @@ -8,18 +9,16 @@ import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; import type { UmbReferenceModel } from '@umbraco-cms/backoffice/relations'; import type { UmbModalRouteBuilder } from '@umbraco-cms/backoffice/router'; import type { UUIPaginationEvent } from '@umbraco-cms/backoffice/external/uui'; +import type { UmbEntityUnique } from '@umbraco-cms/backoffice/entity'; -@customElement('umb-media-workspace-view-info-reference') -export class UmbMediaWorkspaceViewInfoReferenceElement extends UmbLitElement { +@customElement('umb-media-references-workspace-info-app') +export class UmbMediaReferencesWorkspaceInfoAppElement extends UmbLitElement { #itemsPerPage = 10; #referenceRepository; #routeBuilder?: UmbModalRouteBuilder; - @property() - mediaUnique = ''; - @state() private _currentPage = 1; @@ -32,6 +31,9 @@ export class UmbMediaWorkspaceViewInfoReferenceElement extends UmbLitElement { @state() private _loading = true; + #workspaceContext?: typeof UMB_MEDIA_WORKSPACE_CONTEXT.TYPE; + #mediaUnique?: UmbEntityUnique; + constructor() { super(); this.#referenceRepository = new UmbMediaReferenceRepository(this); @@ -44,6 +46,32 @@ export class UmbMediaWorkspaceViewInfoReferenceElement extends UmbLitElement { .observeRouteBuilder((routeBuilder) => { this.#routeBuilder = routeBuilder; }); + + this.consumeContext(UMB_MEDIA_WORKSPACE_CONTEXT, (context) => { + this.#workspaceContext = context; + this.#observeMediaUnique(); + }); + } + + #observeMediaUnique() { + this.observe( + this.#workspaceContext?.unique, + (unique) => { + if (!unique) { + this.#mediaUnique = undefined; + this._items = []; + return; + } + + if (this.#mediaUnique === unique) { + return; + } + + this.#mediaUnique = unique; + this.#getReferences(); + }, + 'umbReferencesDocumentUniqueObserver', + ); } protected override firstUpdated(): void { @@ -51,10 +79,14 @@ export class UmbMediaWorkspaceViewInfoReferenceElement extends UmbLitElement { } async #getReferences() { + if (!this.#mediaUnique) { + throw new Error('Media unique is required'); + } + this._loading = true; const { data } = await this.#referenceRepository.requestReferencedBy( - this.mediaUnique, + this.#mediaUnique, (this._currentPage - 1) * this.#itemsPerPage, this.#itemsPerPage, ); @@ -218,10 +250,10 @@ export class UmbMediaWorkspaceViewInfoReferenceElement extends UmbLitElement { ]; } -export default UmbMediaWorkspaceViewInfoReferenceElement; +export default UmbMediaReferencesWorkspaceInfoAppElement; declare global { interface HTMLElementTagNameMap { - 'umb-media-workspace-view-info-reference': UmbMediaWorkspaceViewInfoReferenceElement; + 'umb-media-references-workspace-info-app': UmbMediaReferencesWorkspaceInfoAppElement; } } diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/manifests.ts index 4ac6fbdcb2ff..cad6350ec827 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/manifests.ts @@ -1,3 +1,4 @@ import { manifests as repositoryManifests } from './repository/manifests.js'; +import { manifests as infoAppManifests } from './info-app/manifests.js'; -export const manifests: Array = [...repositoryManifests]; +export const manifests: Array = [...repositoryManifests, ...infoAppManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts index 32a3d387712b..f6a499c598fa 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts @@ -11,9 +11,6 @@ import type { MediaUrlInfoModel } from '@umbraco-cms/backoffice/external/backend import { createExtensionApiByAlias } from '@umbraco-cms/backoffice/extension-registry'; import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backoffice/section'; import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; - -// import of local components -import './media-workspace-view-info-reference.element.js'; import type { UmbExtensionElementInitializer } from '@umbraco-cms/backoffice/extension-api'; @customElement('umb-media-workspace-view-info') From 4a728d88c2a09f908399a9c82a13ca26b0cb82a2 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 17 Jan 2025 09:29:55 +0100 Subject: [PATCH 12/20] remove double box --- .../media-references-workspace-info-app.element.ts | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts index 0e43ff261080..1b2b6ddcccdd 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts @@ -156,13 +156,11 @@ export class UmbMediaReferencesWorkspaceInfoAppElement extends UmbLitElement { override render() { return html` - - ${when( - this._loading, - () => html``, - () => html`${this.#renderItems()} ${this.#renderPagination()}`, - )} - + ${when( + this._loading, + () => html``, + () => html`${this.#renderItems()} ${this.#renderPagination()}`, + )} `; } From e3dd44f35742d077cc18f81818cf463833605c8e Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 17 Jan 2025 09:51:55 +0100 Subject: [PATCH 13/20] split media links into info app --- .../media/reference/info-app/manifests.ts | 2 +- .../media/media/url/info-app/manifests.ts | 21 +++ .../media-links-workspace-info-app.element.ts | 142 ++++++++++++++++++ .../src/packages/media/media/url/manifests.ts | 3 +- .../info/media-workspace-view-info.element.ts | 100 ------------ 5 files changed, 166 insertions(+), 102 deletions(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts index 692057ac2558..772ac537704f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts @@ -7,7 +7,7 @@ export const manifests: Array = [ name: 'Media References Workspace Info App', alias: 'Umb.WorkspaceInfoApp.Media.References', element: () => import('./media-references-workspace-info-app.element.js'), - weight: 80, + weight: 90, meta: { label: '#references_labelUsedByItems', }, diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts new file mode 100644 index 000000000000..fe093b2a4108 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts @@ -0,0 +1,21 @@ +import { UMB_MEDIA_WORKSPACE_ALIAS } from '../../workspace/constants.js'; +import { UMB_WORKSPACE_CONDITION_ALIAS } from '@umbraco-cms/backoffice/workspace'; + +export const manifests: Array = [ + { + type: 'workspaceInfoApp', + name: 'Media Links Workspace Info App', + alias: 'Umb.WorkspaceInfoApp.Media.Links', + element: () => import('./media-links-workspace-info-app.element.js'), + weight: 100, + meta: { + label: '#general_links', + }, + conditions: [ + { + alias: UMB_WORKSPACE_CONDITION_ALIAS, + match: UMB_MEDIA_WORKSPACE_ALIAS, + }, + ], + }, +]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts new file mode 100644 index 000000000000..f042b1f6090b --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts @@ -0,0 +1,142 @@ +import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../workspace/constants.js'; +import type { MediaUrlInfoModel } from '@umbraco-cms/backoffice/external/backend-api'; +import { css, customElement, html, repeat, state } from '@umbraco-cms/backoffice/external/lit'; +import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; + +@customElement('umb-document-links-workspace-info-app') +export class UmbMediaLinksWorkspaceInfoAppElement extends UmbLitElement { + @state() + private _urls?: Array; + + #workspaceContext?: typeof UMB_MEDIA_WORKSPACE_CONTEXT.TYPE; + + constructor() { + super(); + + this.consumeContext(UMB_MEDIA_WORKSPACE_CONTEXT, (context) => { + this.#workspaceContext = context; + this.#observeUrls(); + }); + } + + #observeUrls() { + if (!this.#workspaceContext) return; + + this.observe( + this.#workspaceContext.urls, + (urls) => { + this._urls = urls; + }, + '__urls', + ); + } + + protected override render() { + return html` ${this.#renderLinksSection()} `; + } + + #openSvg(imagePath: string) { + const popup = window.open('', '_blank'); + if (!popup) return; + + const html = ` + + + +`; + + popup.document.open(); + popup.document.write(html); + popup.document.close(); + } + + #renderLinksSection() { + if (this._urls && this._urls.length) { + return html` + ${repeat( + this._urls, + (item) => item.url, + (item) => this.#renderLinkItem(item), + )} + `; + } else { + return html` + + `; + } + } + + #renderLinkItem(item: MediaUrlInfoModel) { + const ext = item.url.split(/[#?]/)[0].split('.').pop()?.trim(); + if (ext === 'svg') { + return html` + this.#openSvg(item.url)}> + ${item.url} + + + `; + } else { + return html` + + ${item.url} + + + `; + } + } + + static override styles = [ + css` + uui-box { + --uui-box-default-padding: 0; + } + + #link-section { + display: flex; + flex-direction: column; + text-align: left; + } + + .link-item { + padding: var(--uui-size-space-4) var(--uui-size-space-6); + display: grid; + grid-template-columns: 1fr auto; + gap: var(--uui-size-6); + color: inherit; + text-decoration: none; + word-break: break-all; + } + + .link-language { + color: var(--uui-color-divider-emphasis); + } + + .link-content.italic { + font-style: italic; + } + + .link-item uui-icon { + margin-right: var(--uui-size-space-2); + vertical-align: middle; + } + + .link-item.with-href { + cursor: pointer; + } + + .link-item.with-href:hover { + background: var(--uui-color-divider); + } + `, + ]; +} + +export default UmbMediaLinksWorkspaceInfoAppElement; + +declare global { + interface HTMLElementTagNameMap { + 'umb-media-links-workspace-info-app': UmbMediaLinksWorkspaceInfoAppElement; + } +} diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts index 4ac6fbdcb2ff..cad6350ec827 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/manifests.ts @@ -1,3 +1,4 @@ import { manifests as repositoryManifests } from './repository/manifests.js'; +import { manifests as infoAppManifests } from './info-app/manifests.js'; -export const manifests: Array = [...repositoryManifests]; +export const manifests: Array = [...repositoryManifests, ...infoAppManifests]; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts index f6a499c598fa..511de01adbfe 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts @@ -34,9 +34,6 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { #mediaTypeItemRepository = new UmbMediaTypeItemRepository(this); - @state() - private _urls?: Array; - @state() private _createDate?: string | null = null; @@ -87,14 +84,6 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { #observeContent() { if (!this.#workspaceContext) return; - this.observe( - this.#workspaceContext.urls, - (urls) => { - this._urls = urls; - }, - '__urls', - ); - this.observe( this.#workspaceContext.unique, (unique) => { @@ -109,20 +98,6 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { this._updateDate = variants?.[0]?.updateDate; }); } - #openSvg(imagePath: string) { - const popup = window.open('', '_blank'); - if (!popup) return; - - const html = ` - - - -`; - - popup.document.open(); - popup.document.write(html); - popup.document.close(); - } override render() { return html` @@ -140,43 +115,6 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { `; } - #renderLinksSection() { - if (this._urls && this._urls.length) { - return html` - ${repeat( - this._urls, - (item) => item.url, - (item) => this.#renderLinkItem(item), - )} - `; - } else { - return html` - - `; - } - } - - #renderLinkItem(item: MediaUrlInfoModel) { - const ext = item.url.split(/[#?]/)[0].split('.').pop()?.trim(); - if (ext === 'svg') { - return html` - this.#openSvg(item.url)}> - ${item.url} - - - `; - } else { - return html` - - ${item.url} - - - `; - } - } - #renderInfoApp(initializer: UmbExtensionElementInitializer) { const headline = initializer.manifest?.meta.label; return html` @@ -267,44 +205,6 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { margin-bottom: var(--uui-size-space-6); } - // Link section - - #link-section { - display: flex; - flex-direction: column; - text-align: left; - } - - .link-item { - padding: var(--uui-size-space-4) var(--uui-size-space-6); - display: grid; - grid-template-columns: 1fr auto; - gap: var(--uui-size-6); - color: inherit; - text-decoration: none; - } - - .link-language { - color: var(--uui-color-divider-emphasis); - } - - .link-content.italic { - font-style: italic; - } - - .link-item uui-icon { - margin-right: var(--uui-size-space-2); - vertical-align: middle; - } - - .link-item.with-href { - cursor: pointer; - } - - .link-item.with-href:hover { - background: var(--uui-color-divider); - } - uui-ref-node-document-type[readonly] { padding-top: 7px; padding-bottom: 7px; From c12f6a22734467883bef419e9bc15c5589a92685 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 17 Jan 2025 09:53:05 +0100 Subject: [PATCH 14/20] Update media-links-workspace-info-app.element.ts --- .../url/info-app/media-links-workspace-info-app.element.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts index f042b1f6090b..b3994befd03a 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts @@ -3,7 +3,7 @@ import type { MediaUrlInfoModel } from '@umbraco-cms/backoffice/external/backend import { css, customElement, html, repeat, state } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; -@customElement('umb-document-links-workspace-info-app') +@customElement('umb-media-links-workspace-info-app') export class UmbMediaLinksWorkspaceInfoAppElement extends UmbLitElement { @state() private _urls?: Array; From 5e7065b7db7e812e1c6b8be2c7c7aee8a1a1550e Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 30 Jan 2025 14:18:35 +0100 Subject: [PATCH 15/20] add layout element --- .../src/packages/core/workspace/index.ts | 5 ++- .../info-app/global-components/index.ts | 3 ++ .../workspace-info-app-layout.element.ts | 31 +++++++++++++++++++ .../packages/core/workspace/info-app/index.ts | 3 ++ .../workspace/{info => info-app}/types.ts | 0 .../workspace-info-app.extension.ts | 5 ++- .../src/packages/core/workspace/types.ts | 2 +- 7 files changed, 42 insertions(+), 7 deletions(-) create mode 100644 src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/index.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/workspace-info-app-layout.element.ts create mode 100644 src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/index.ts rename src/Umbraco.Web.UI.Client/src/packages/core/workspace/{info => info-app}/types.ts (100%) rename src/Umbraco.Web.UI.Client/src/packages/core/workspace/{info => info-app}/workspace-info-app.extension.ts (83%) diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/index.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/index.ts index 04221017ddad..055747196e5a 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/index.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/index.ts @@ -1,13 +1,11 @@ -import './entity-detail/global-components/index.js'; - export * from './components/index.js'; export * from './conditions/const.js'; export * from './constants.js'; export * from './contexts/index.js'; export * from './controllers/index.js'; -export * from './entity-detail/global-components/index.js'; export * from './entity-detail/index.js'; export * from './entity/index.js'; +export * from './info-app/index.js'; export * from './modals/index.js'; export * from './paths.js'; export * from './submittable/index.js'; @@ -15,4 +13,5 @@ export * from './utils/object-to-property-value-array.function.js'; export * from './workspace-property-dataset/index.js'; export * from './workspace.context-token.js'; export * from './workspace.element.js'; + export type * from './types.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/index.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/index.ts new file mode 100644 index 000000000000..7103e66d1e85 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/index.ts @@ -0,0 +1,3 @@ +import './workspace-info-app-layout.element.js'; + +export * from './workspace-info-app-layout.element.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/workspace-info-app-layout.element.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/workspace-info-app-layout.element.ts new file mode 100644 index 000000000000..3b6388299e0d --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/global-components/workspace-info-app-layout.element.ts @@ -0,0 +1,31 @@ +import { css, customElement, html, ifDefined, property } from '@umbraco-cms/backoffice/external/lit'; +import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; + +@customElement('umb-workspace-info-app-layout') +export class UmbWorkspaceInfoAppLayoutElement extends UmbLitElement { + @property({ type: String }) + headline?: string; + + protected override render() { + return html` + + + + + `; + } + + static override styles = [ + css` + uui-box { + --uui-box-default-padding: 0; + } + `, + ]; +} + +declare global { + interface HTMLElementTagNameMap { + 'umb-workspace-info-app-layout': UmbWorkspaceInfoAppLayoutElement; + } +} diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/index.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/index.ts new file mode 100644 index 000000000000..6b7434bd11d7 --- /dev/null +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/index.ts @@ -0,0 +1,3 @@ +import './global-components/index.js'; + +export * from './global-components/index.js'; diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/types.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/types.ts similarity index 100% rename from src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/types.ts rename to src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/types.ts diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/workspace-info-app.extension.ts similarity index 83% rename from src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts rename to src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/workspace-info-app.extension.ts index ee521b1617ff..19616992aa13 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info/workspace-info-app.extension.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/info-app/workspace-info-app.extension.ts @@ -11,9 +11,8 @@ export interface ManifestWorkspaceInfoApp meta: MetaWorkspaceInfoApp; } -export interface MetaWorkspaceInfoApp { - label: string; -} +// eslint-disable-next-line @typescript-eslint/no-empty-object-type +export interface MetaWorkspaceInfoApp {} declare global { interface UmbExtensionManifestMap { diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts index 7e0c0fe82e08..cc9d02132f10 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/types.ts @@ -3,7 +3,7 @@ import type { UmbEntityUnique } from '@umbraco-cms/backoffice/entity'; export type * from './conditions/types.js'; export type * from './data-manager/types.js'; export type * from './extensions/types.js'; -export type * from './info/types.js'; +export type * from './info-app/types.js'; export type * from './kinds/types.js'; export type * from './namable/types.js'; export type * from './workspace-context.interface.js'; From b840fec22889042d98b36f702615c79dc9725c97 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 30 Jan 2025 14:19:19 +0100 Subject: [PATCH 16/20] wrap in layout element --- ...ment-history-workspace-info-app.element.ts | 30 ++++--- .../documents/audit-log/info-app/manifests.ts | 3 - ...-references-workspace-view-info.element.ts | 86 ++++++++++--------- .../documents/reference/info-app/manifests.ts | 3 - ...cument-links-workspace-info-app.element.ts | 12 +-- .../documents/url/info-app/manifests.ts | 3 - .../document-workspace-view-info.element.ts | 16 +--- 7 files changed, 69 insertions(+), 84 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts index 208ead1d2ec2..2a08e9e9b6a6 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts @@ -99,18 +99,22 @@ export class UmbDocumentHistoryWorkspaceInfoAppElement extends UmbLitElement { override render() { return html` - - this.#allowedActions.has(manifest.alias)}> - - ${when( - this._items, - () => this.#renderHistory(), - () => html`
`, - )} - ${this.#renderPagination()} + + + this.#allowedActions.has(manifest.alias)}> + +
+ ${when( + this._items, + () => this.#renderHistory(), + () => html`
`, + )} + ${this.#renderPagination()} +
+
`; } @@ -162,7 +166,7 @@ export class UmbDocumentHistoryWorkspaceInfoAppElement extends UmbLitElement { static override styles = [ UmbTextStyles, css` - :host { + #content { display: block; padding: var(--uui-size-space-4) var(--uui-size-space-5); } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts index cb9782417bc4..f8860e6add90 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/manifests.ts @@ -8,9 +8,6 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Document.History', element: () => import('./document-history-workspace-info-app.element.js'), weight: 80, - meta: { - label: '#general_history', - }, conditions: [ { alias: UMB_WORKSPACE_CONDITION_ALIAS, diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts index 789efc0d632d..def6b92a8060 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/document-references-workspace-view-info.element.ts @@ -1,4 +1,5 @@ import { UmbDocumentReferenceRepository } from '../repository/index.js'; +import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../constants.js'; import { css, customElement, html, nothing, repeat, state, when } from '@umbraco-cms/backoffice/external/lit'; import { isDefaultReference, isDocumentReference, isMediaReference } from '@umbraco-cms/backoffice/relations'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; @@ -7,7 +8,6 @@ import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/rou import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; import type { UmbReferenceModel } from '@umbraco-cms/backoffice/relations'; import type { UUIPaginationEvent } from '@umbraco-cms/backoffice/external/uui'; -import { UMB_DOCUMENT_WORKSPACE_CONTEXT } from '../../constants.js'; import type { UmbEntityUnique } from '@umbraco-cms/backoffice/entity'; @customElement('umb-document-references-workspace-info-app') @@ -137,47 +137,49 @@ export class UmbDocumentReferencesWorkspaceInfoAppElement extends UmbLitElement override render() { if (!this._items?.length) return nothing; return html` - - - - Name - Status - Type Name - Type - - ${repeat( - this._items, - (item) => item.id, - (item) => html` - - - - - - ${when( - isDocumentReference(item), - () => html` - - ${item.name} - - `, - () => item.name, - )} - - - ${this.#getPublishedStatus(item) - ? this.localize.term('content_published') - : this.localize.term('content_unpublished')} - - ${this.#getContentTypeName(item)} - ${this.#getContentType(item)} - - `, - )} - - ${this.#renderReferencePagination()} + + + + + Name + Status + Type Name + Type + + ${repeat( + this._items, + (item) => item.id, + (item) => html` + + + + + + ${when( + isDocumentReference(item), + () => html` + + ${item.name} + + `, + () => item.name, + )} + + + ${this.#getPublishedStatus(item) + ? this.localize.term('content_published') + : this.localize.term('content_unpublished')} + + ${this.#getContentTypeName(item)} + ${this.#getContentType(item)} + + `, + )} + + ${this.#renderReferencePagination()} + `; } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts index 089ecc6fe4a0..42f6e34b1949 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/reference/info-app/manifests.ts @@ -8,9 +8,6 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Document.References', element: () => import('./document-references-workspace-view-info.element.js'), weight: 90, - meta: { - label: '#references_labelUsedByItems', - }, conditions: [ { alias: UMB_WORKSPACE_CONDITION_ALIAS, diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts index a7723cd80130..ea3346c04cbd 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts @@ -155,11 +155,13 @@ export class UmbDocumentLinksWorkspaceInfoAppElement extends UmbLitElement { override render() { return html` - ${when( - this._loading, - () => this.#renderLoading(), - () => this.#renderContent(), - )} + + ${when( + this._loading, + () => this.#renderLoading(), + () => this.#renderContent(), + )} + `; } diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts index 315eb893995f..58a7862ff3ac 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/manifests.ts @@ -8,9 +8,6 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Document.Links', element: () => import('./document-links-workspace-info-app.element.js'), weight: 100, - meta: { - label: '#general_links', - }, conditions: [ { alias: UMB_WORKSPACE_CONDITION_ALIAS, diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts index ff740f699be1..6fb10c2d8071 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts @@ -178,10 +178,7 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { override render() { return html`
- +
@@ -191,17 +188,6 @@ export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { `; } - #renderInfoApp(initializer: UmbExtensionElementInitializer) { - const headline = initializer.manifest?.meta.label; - return html` - - ${initializer.component} - `; - } - #renderGeneralSection() { const editDocumentTypePath = this._routeBuilder?.({ entityType: 'document-type' }) ?? ''; From 4aae50257246c6a4713916379fa7d47a8333dde5 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 30 Jan 2025 14:57:40 +0100 Subject: [PATCH 17/20] add layout element --- ...ment-history-workspace-info-app.element.ts | 6 +++ ...cument-links-workspace-info-app.element.ts | 3 +- .../media/audit-log/info-app/manifests.ts | 3 -- ...edia-history-workspace-info-app.element.ts | 38 +++++++++++-------- .../media/reference/info-app/manifests.ts | 3 -- ...a-references-workspace-info-app.element.ts | 18 ++++----- .../media/media/url/info-app/manifests.ts | 3 -- .../media-links-workspace-info-app.element.ts | 6 ++- .../info/media-workspace-view-info.element.ts | 16 +------- 9 files changed, 44 insertions(+), 52 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts index 2a08e9e9b6a6..264f28b9a4c5 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/audit-log/info-app/document-history-workspace-info-app.element.ts @@ -182,6 +182,12 @@ export class UmbDocumentHistoryWorkspaceInfoAppElement extends UmbLitElement { gap: var(--uui-size-layout-1); } + .log-type uui-tag { + height: fit-content; + margin-top: auto; + margin-bottom: auto; + } + uui-pagination { flex: 1; display: flex; diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts index ea3346c04cbd..bfd6d56d45c2 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/url/info-app/document-links-workspace-info-app.element.ts @@ -257,8 +257,7 @@ export class UmbDocumentLinksWorkspaceInfoAppElement extends UmbLitElement { justify-content: space-between; align-items: center; gap: var(--uui-size-6); - - padding: var(--uui-size-space-4) var(--uui-size-space-6); + padding: var(--uui-size-space-4) var(--uui-size-space-5); &:is(a) { cursor: pointer; diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts index ff6482b7d789..d79e6b6fba9e 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/manifests.ts @@ -8,9 +8,6 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Media.History', element: () => import('./media-history-workspace-info-app.element.js'), weight: 80, - meta: { - label: '#general_history', - }, conditions: [ { alias: UMB_WORKSPACE_CONDITION_ALIAS, diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts index 9b1d8104f312..58fa25757a0f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/audit-log/info-app/media-history-workspace-info-app.element.ts @@ -2,7 +2,7 @@ import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../workspace/constants.js'; import type { UmbMediaAuditLogModel } from '../types.js'; import { UmbMediaAuditLogRepository } from '../repository/index.js'; import { getMediaHistoryTagStyleAndText, TimeOptions } from './utils.js'; -import { css, html, customElement, state, nothing, repeat } from '@umbraco-cms/backoffice/external/lit'; +import { css, html, customElement, state, nothing, repeat, when } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbTextStyles } from '@umbraco-cms/backoffice/style'; import { UmbPaginationManager } from '@umbraco-cms/backoffice/utils'; @@ -84,8 +84,16 @@ export class UmbMediaHistoryWorkspaceInfoAppElement extends UmbLitElement { override render() { return html` - ${this._items ? this.#renderHistory() : html` `} - ${this.#renderPagination()} + +
+ ${when( + this._items, + () => this.#renderHistory(), + () => html`
`, + )} + ${this.#renderPagination()} +
+
`; } @@ -142,30 +150,30 @@ export class UmbMediaHistoryWorkspaceInfoAppElement extends UmbLitElement { static override styles = [ UmbTextStyles, css` - :host { + #content { display: block; padding: var(--uui-size-space-4) var(--uui-size-space-5); } - uui-loader-circle { - font-size: 2rem; + #loader { + display: flex; + justify-content: center; } - uui-tag uui-icon { - margin-right: var(--uui-size-space-1); + .log-type { + display: grid; + grid-template-columns: var(--uui-size-40) auto; + gap: var(--uui-size-layout-1); } - .log-type { - flex-grow: 1; - gap: var(--uui-size-space-2); + .log-type uui-tag { + height: fit-content; + margin-top: auto; + margin-bottom: auto; } uui-pagination { flex: 1; - display: inline-block; - } - - .pagination { display: flex; justify-content: center; margin-top: var(--uui-size-layout-1); diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts index 772ac537704f..6740bdc27f5d 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/manifests.ts @@ -8,9 +8,6 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Media.References', element: () => import('./media-references-workspace-info-app.element.js'), weight: 90, - meta: { - label: '#references_labelUsedByItems', - }, conditions: [ { alias: UMB_WORKSPACE_CONDITION_ALIAS, diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts index 1b2b6ddcccdd..e552b8554071 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/reference/info-app/media-references-workspace-info-app.element.ts @@ -155,20 +155,20 @@ export class UmbMediaReferencesWorkspaceInfoAppElement extends UmbLitElement { } override render() { + if (!this._items?.length) return nothing; return html` - ${when( - this._loading, - () => html``, - () => html`${this.#renderItems()} ${this.#renderPagination()}`, - )} + + ${when( + this._loading, + () => html``, + () => html`${this.#renderItems()} ${this.#renderPagination()}`, + )} + `; } #renderItems() { - if (!this._items?.length) - return html`

- This item has no references. -

`; + if (!this._items?.length) return nothing; return html` diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts index fe093b2a4108..ac663b2e9c39 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/manifests.ts @@ -8,9 +8,6 @@ export const manifests: Array = [ alias: 'Umb.WorkspaceInfoApp.Media.Links', element: () => import('./media-links-workspace-info-app.element.js'), weight: 100, - meta: { - label: '#general_links', - }, conditions: [ { alias: UMB_WORKSPACE_CONDITION_ALIAS, diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts index b3994befd03a..114792debbef 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/url/info-app/media-links-workspace-info-app.element.ts @@ -32,7 +32,9 @@ export class UmbMediaLinksWorkspaceInfoAppElement extends UmbLitElement { } protected override render() { - return html` ${this.#renderLinksSection()} `; + return html` + ${this.#renderLinksSection()} + `; } #openSvg(imagePath: string) { @@ -100,7 +102,7 @@ export class UmbMediaLinksWorkspaceInfoAppElement extends UmbLitElement { } .link-item { - padding: var(--uui-size-space-4) var(--uui-size-space-6); + padding: var(--uui-size-space-4) var(--uui-size-space-5); display: grid; grid-template-columns: 1fr auto; gap: var(--uui-size-6); diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts index 511de01adbfe..c201edb13d1b 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts @@ -102,10 +102,7 @@ export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { override render() { return html`
- +
) { - const headline = initializer.manifest?.meta.label; - return html` - - ${initializer.component} - `; - } - #renderGeneralSection() { return html` ${this.#renderCreateDate()} ${this.#renderUpdateDate()} From 54e4a26d77cda241708d719904ad68de37f6846b Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 30 Jan 2025 17:02:13 +0100 Subject: [PATCH 18/20] update consts --- src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts b/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts index 7fd643335e0d..2220b1a2bf7c 100644 --- a/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts +++ b/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts @@ -212,7 +212,7 @@ export const foundConsts = [{ }, { path: '@umbraco-cms/backoffice/media', - consts: ["UMB_MEDIA_COLLECTION_ALIAS","UMB_MEDIA_COLLECTION_CONTEXT","UMB_MEDIA_COLLECTION_REPOSITORY_ALIAS","UMB_MEDIA_GRID_COLLECTION_VIEW_ALIAS","UMB_MEDIA_TABLE_COLLECTION_VIEW_ALIAS","UMB_DROPZONE_MEDIA_TYPE_PICKER_MODAL","UMB_MEDIA_CREATE_OPTIONS_MODAL","UMB_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_MEDIA_REPOSITORY_ALIAS","UMB_BULK_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_BULK_TRASH_MEDIA_REPOSITORY_ALIAS","UMB_MEDIA_ENTITY_TYPE","UMB_MEDIA_ROOT_ENTITY_TYPE","UMB_MEDIA_PLACEHOLDER_ENTITY_TYPE","UMB_MEDIA_MENU_ALIAS","UMB_IMAGE_CROPPER_EDITOR_MODAL","UMB_MEDIA_CAPTION_ALT_TEXT_MODAL","UMB_MEDIA_PICKER_MODAL","UMB_MEDIA_WORKSPACE_PATH","UMB_CREATE_MEDIA_WORKSPACE_PATH_PATTERN","UMB_EDIT_MEDIA_WORKSPACE_PATH_PATTERN","UMB_MEDIA_VARIANT_CONTEXT","UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_MEDIA_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_MEDIA_REFERENCE_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_STORE_ALIAS","UMB_MEDIA_DETAIL_STORE_CONTEXT","UMB_MEDIA_ITEM_REPOSITORY_ALIAS","UMB_MEDIA_STORE_ALIAS","UMB_MEDIA_ITEM_STORE_CONTEXT","UMB_MEDIA_VALIDATION_REPOSITORY_ALIAS","UMB_MEDIA_TREE_REPOSITORY_ALIAS","UMB_MEDIA_TREE_STORE_ALIAS","UMB_MEDIA_TREE_ALIAS","UMB_MEDIA_TREE_PICKER_MODAL","UMB_MEDIA_TREE_STORE_CONTEXT","UMB_MEDIA_URL_REPOSITORY_ALIAS","UMB_MEDIA_URL_STORE_ALIAS","UMB_MEDIA_URL_STORE_CONTEXT","UMB_MEDIA_WORKSPACE_ALIAS","UMB_MEMBER_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_MEDIA_WORKSPACE_CONTEXT"] + consts: ["UMB_MEDIA_COLLECTION_ALIAS","UMB_MEDIA_COLLECTION_CONTEXT","UMB_MEDIA_COLLECTION_REPOSITORY_ALIAS","UMB_MEDIA_GRID_COLLECTION_VIEW_ALIAS","UMB_MEDIA_TABLE_COLLECTION_VIEW_ALIAS","UMB_DROPZONE_MEDIA_TYPE_PICKER_MODAL","UMB_MEDIA_CREATE_OPTIONS_MODAL","UMB_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_MEDIA_REPOSITORY_ALIAS","UMB_BULK_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_BULK_TRASH_MEDIA_REPOSITORY_ALIAS","UMB_MEDIA_ENTITY_TYPE","UMB_MEDIA_ROOT_ENTITY_TYPE","UMB_MEDIA_PLACEHOLDER_ENTITY_TYPE","UMB_MEDIA_MENU_ALIAS","UMB_IMAGE_CROPPER_EDITOR_MODAL","UMB_MEDIA_CAPTION_ALT_TEXT_MODAL","UMB_MEDIA_PICKER_MODAL","UMB_MEDIA_WORKSPACE_PATH","UMB_CREATE_MEDIA_WORKSPACE_PATH_PATTERN","UMB_EDIT_MEDIA_WORKSPACE_PATH_PATTERN","UMB_MEDIA_VARIANT_CONTEXT","UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_MEDIA_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_MEDIA_REFERENCE_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_STORE_ALIAS","UMB_MEDIA_DETAIL_STORE_CONTEXT","UMB_MEDIA_ITEM_REPOSITORY_ALIAS","UMB_MEDIA_STORE_ALIAS","UMB_MEDIA_ITEM_STORE_CONTEXT","UMB_MEDIA_VALIDATION_REPOSITORY_ALIAS","UMB_MEDIA_SEARCH_PROVIDER_ALIAS","UMB_MEDIA_TREE_REPOSITORY_ALIAS","UMB_MEDIA_TREE_STORE_ALIAS","UMB_MEDIA_TREE_ALIAS","UMB_MEDIA_TREE_PICKER_MODAL","UMB_MEDIA_TREE_STORE_CONTEXT","UMB_MEDIA_URL_REPOSITORY_ALIAS","UMB_MEDIA_URL_STORE_ALIAS","UMB_MEDIA_URL_STORE_CONTEXT","UMB_MEDIA_WORKSPACE_ALIAS","UMB_MEMBER_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_MEDIA_WORKSPACE_CONTEXT"] }, { path: '@umbraco-cms/backoffice/member-group', @@ -404,7 +404,7 @@ export const foundConsts = [{ }, { path: '@umbraco-cms/backoffice/user', - consts: ["UMB_CREATE_USER_CLIENT_CREDENTIAL_MODAL","UMB_CREATE_USER_CLIENT_CREDENTIAL_MODAL_ALIAS","UMB_USER_CLIENT_CREDENTIAL_REPOSITORY_ALIAS","UMB_USER_COLLECTION_ALIAS","UMB_USER_COLLECTION_REPOSITORY_ALIAS","UMB_USER_COLLECTION_CONTEXT","UMB_COLLECTION_VIEW_USER_TABLE","UMB_COLLECTION_VIEW_USER_GRID","UMB_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS","UMB_USER_ALLOW_DELETE_CONDITION_ALIAS","UMB_USER_ALLOW_DISABLE_CONDITION_ALIAS","UMB_USER_ALLOW_ENABLE_CONDITION_ALIAS","UMB_USER_ALLOW_EXTERNAL_LOGIN_CONDITION_ALIAS","UMB_USER_ALLOW_MFA_CONDITION_ALIAS","UMB_USER_ALLOW_UNLOCK_CONDITION_ALIAS","UMB_USER_IS_DEFAULT_KIND_CONDITION_ALIAS","UMB_CREATE_USER_MODAL","UMB_CREATE_USER_SUCCESS_MODAL","UMB_CREATE_USER_MODAL_ALIAS","UMB_USER_ENTITY_TYPE","UMB_USER_ROOT_ENTITY_TYPE","UMB_INVITE_USER_MODAL","UMB_RESEND_INVITE_TO_USER_MODAL","UMB_INVITE_USER_REPOSITORY_ALIAS","UMB_USER_MFA_MODAL","UMB_USER_PICKER_MODAL","UMB_USER_WORKSPACE_PATH","UMB_USER_ROOT_WORKSPACE_PATH","UMB_USER_AVATAR_REPOSITORY_ALIAS","UMB_CHANGE_USER_PASSWORD_REPOSITORY_ALIAS","UMB_USER_CONFIG_REPOSITORY_ALIAS","UMB_USER_CONFIG_STORE_ALIAS","UMB_USER_CONFIG_STORE_CONTEXT","UMB_CURRENT_USER_CONFIG_STORE_CONTEXT","UMB_USER_DETAIL_REPOSITORY_ALIAS","UMB_USER_DETAIL_STORE_ALIAS","UMB_USER_DETAIL_STORE_CONTEXT","UMB_DISABLE_USER_REPOSITORY_ALIAS","UMB_ENABLE_USER_REPOSITORY_ALIAS","UMB_USER_ITEM_REPOSITORY_ALIAS","UMB_USER_ITEM_STORE_ALIAS","UMB_USER_ITEM_STORE_CONTEXT","UMB_NEW_USER_PASSWORD_REPOSITORY_ALIAS","UMB_UNLOCK_USER_REPOSITORY_ALIAS","UMB_USER_WORKSPACE_ALIAS","UMB_USER_WORKSPACE_CONTEXT","UMB_USER_ROOT_WORKSPACE_ALIAS"] + consts: ["UMB_CREATE_USER_CLIENT_CREDENTIAL_MODAL","UMB_CREATE_USER_CLIENT_CREDENTIAL_MODAL_ALIAS","UMB_USER_CLIENT_CREDENTIAL_REPOSITORY_ALIAS","UMB_USER_COLLECTION_ALIAS","UMB_USER_COLLECTION_REPOSITORY_ALIAS","UMB_USER_COLLECTION_CONTEXT","UMB_COLLECTION_VIEW_USER_TABLE","UMB_COLLECTION_VIEW_USER_GRID","UMB_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS","UMB_CURRENT_USER_ALLOW_CHANGE_PASSWORD_CONDITION_ALIAS","UMB_USER_ALLOW_DELETE_CONDITION_ALIAS","UMB_USER_ALLOW_DISABLE_CONDITION_ALIAS","UMB_USER_ALLOW_ENABLE_CONDITION_ALIAS","UMB_USER_ALLOW_EXTERNAL_LOGIN_CONDITION_ALIAS","UMB_USER_ALLOW_MFA_CONDITION_ALIAS","UMB_CURRENT_USER_ALLOW_MFA_CONDITION_ALIAS","UMB_USER_ALLOW_UNLOCK_CONDITION_ALIAS","UMB_USER_IS_DEFAULT_KIND_CONDITION_ALIAS","UMB_CREATE_USER_MODAL","UMB_CREATE_USER_SUCCESS_MODAL","UMB_CREATE_USER_MODAL_ALIAS","UMB_USER_ENTITY_TYPE","UMB_USER_ROOT_ENTITY_TYPE","UMB_INVITE_USER_MODAL","UMB_RESEND_INVITE_TO_USER_MODAL","UMB_INVITE_USER_REPOSITORY_ALIAS","UMB_USER_MFA_MODAL","UMB_USER_PICKER_MODAL","UMB_USER_WORKSPACE_PATH","UMB_USER_ROOT_WORKSPACE_PATH","UMB_USER_AVATAR_REPOSITORY_ALIAS","UMB_CHANGE_USER_PASSWORD_REPOSITORY_ALIAS","UMB_USER_CONFIG_REPOSITORY_ALIAS","UMB_USER_CONFIG_STORE_ALIAS","UMB_CURRENT_USER_CONFIG_REPOSITORY_ALIAS","UMB_CURRENT_USER_CONFIG_STORE_ALIAS","UMB_CURRENT_USER_CONFIG_STORE_CONTEXT","UMB_USER_CONFIG_STORE_CONTEXT","UMB_USER_DETAIL_REPOSITORY_ALIAS","UMB_USER_DETAIL_STORE_ALIAS","UMB_USER_DETAIL_STORE_CONTEXT","UMB_DISABLE_USER_REPOSITORY_ALIAS","UMB_ENABLE_USER_REPOSITORY_ALIAS","UMB_USER_ITEM_REPOSITORY_ALIAS","UMB_USER_ITEM_STORE_ALIAS","UMB_USER_ITEM_STORE_CONTEXT","UMB_NEW_USER_PASSWORD_REPOSITORY_ALIAS","UMB_UNLOCK_USER_REPOSITORY_ALIAS","UMB_USER_WORKSPACE_ALIAS","UMB_USER_WORKSPACE_CONTEXT","UMB_USER_ROOT_WORKSPACE_ALIAS"] }, { path: '@umbraco-cms/backoffice/utils', From 357128151c7f59a4a8ff3d1990128fdf1d70c527 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Thu, 30 Jan 2025 17:03:30 +0100 Subject: [PATCH 19/20] remove unused --- .../views/info/document-workspace-view-info.element.ts | 3 +-- .../views/info/media-workspace-view-info.element.ts | 6 ++---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts index 6fb10c2d8071..d21a6a2fcd3c 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/views/info/document-workspace-view-info.element.ts @@ -7,14 +7,13 @@ import { DocumentVariantStateModel } from '@umbraco-cms/backoffice/external/back import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/router'; import { UMB_MODAL_MANAGER_CONTEXT } from '@umbraco-cms/backoffice/modal'; -import { UMB_WORKSPACE_MODAL, type ManifestWorkspaceInfoApp } from '@umbraco-cms/backoffice/workspace'; +import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; import { UMB_TEMPLATE_PICKER_MODAL, UmbTemplateItemRepository } from '@umbraco-cms/backoffice/template'; import type { UmbDocumentTypeDetailModel } from '@umbraco-cms/backoffice/document-type'; import type { UmbModalRouteBuilder } from '@umbraco-cms/backoffice/router'; import { createExtensionApiByAlias } from '@umbraco-cms/backoffice/extension-registry'; import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backoffice/section'; import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; -import type { UmbExtensionElementInitializer } from '@umbraco-cms/backoffice/extension-api'; @customElement('umb-document-workspace-view-info') export class UmbDocumentWorkspaceViewInfoElement extends UmbLitElement { diff --git a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts index c201edb13d1b..4dce9bd32ac2 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/media/media/workspace/views/info/media-workspace-view-info.element.ts @@ -1,17 +1,15 @@ import { UMB_MEDIA_WORKSPACE_CONTEXT } from '../../media-workspace.context-token.js'; import { TimeOptions } from '../../../audit-log/info-app/utils.js'; -import { css, customElement, html, ifDefined, nothing, repeat, state } from '@umbraco-cms/backoffice/external/lit'; +import { css, customElement, html, ifDefined, nothing, state } from '@umbraco-cms/backoffice/external/lit'; import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element'; import type { UmbMediaTypeItemModel } from '@umbraco-cms/backoffice/media-type'; import { UMB_MEDIA_TYPE_ENTITY_TYPE, UmbMediaTypeItemRepository } from '@umbraco-cms/backoffice/media-type'; import { UmbModalRouteRegistrationController } from '@umbraco-cms/backoffice/router'; import { UmbTextStyles } from '@umbraco-cms/backoffice/style'; -import { UMB_WORKSPACE_MODAL, type ManifestWorkspaceInfoApp } from '@umbraco-cms/backoffice/workspace'; -import type { MediaUrlInfoModel } from '@umbraco-cms/backoffice/external/backend-api'; +import { UMB_WORKSPACE_MODAL } from '@umbraco-cms/backoffice/workspace'; import { createExtensionApiByAlias } from '@umbraco-cms/backoffice/extension-registry'; import { UMB_SECTION_USER_PERMISSION_CONDITION_ALIAS } from '@umbraco-cms/backoffice/section'; import { UMB_SETTINGS_SECTION_ALIAS } from '@umbraco-cms/backoffice/settings'; -import type { UmbExtensionElementInitializer } from '@umbraco-cms/backoffice/extension-api'; @customElement('umb-media-workspace-view-info') export class UmbMediaWorkspaceViewInfoElement extends UmbLitElement { From dab3977ebf4773aa58c88495c34c3dce3d27c0b1 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Fri, 31 Jan 2025 09:27:38 +0100 Subject: [PATCH 20/20] Update index.ts --- src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts b/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts index 0c33d9bb70c2..81387d9cc9ee 100644 --- a/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts +++ b/src/Umbraco.Web.UI.Client/utils/all-umb-consts/index.ts @@ -140,7 +140,7 @@ export const foundConsts = [{ }, { path: '@umbraco-cms/backoffice/document', - consts: ["UMB_DOCUMENT_COLLECTION_ALIAS","UMB_DOCUMENT_COLLECTION_CONTEXT","UMB_DOCUMENT_COLLECTION_REPOSITORY_ALIAS","UMB_DOCUMENT_GRID_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_TABLE_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_CREATE_OPTIONS_MODAL","UMB_CREATE_BLUEPRINT_MODAL","UMB_DOCUMENT_CREATE_BLUEPRINT_REPOSITORY_ALIAS","UMB_CULTURE_AND_HOSTNAMES_MODAL","UMB_DOCUMENT_CULTURE_AND_HOSTNAMES_REPOSITORY_ALIAS","UMB_DUPLICATE_DOCUMENT_MODAL","UMB_DUPLICATE_DOCUMENT_MODAL_ALIAS","UMB_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_MODAL","UMB_DOCUMENT_NOTIFICATIONS_MODAL_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_REPOSITORY_ALIAS","UMB_PUBLIC_ACCESS_MODAL","UMB_DOCUMENT_PUBLIC_ACCESS_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_TRASH_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_ENTITY_TYPE","UMB_DOCUMENT_ROOT_ENTITY_TYPE","UMB_DOCUMENT_CONFIGURATION_CONTEXT","UMB_CONTENT_MENU_ALIAS","UMB_DOCUMENT_PICKER_MODAL","UMB_DOCUMENT_SAVE_MODAL","UMB_DOCUMENT_SAVE_MODAL_ALIAS","UMB_DOCUMENT_WORKSPACE_PATH","UMB_CREATE_FROM_BLUEPRINT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_CREATE_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_EDIT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_DOCUMENT_PROPERTY_DATASET_CONTEXT","UMB_DOCUMENT_PUBLISH_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_MODAL","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL","UMB_DOCUMENT_PUBLISHING_REPOSITORY_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL","UMB_DOCUMENT_UNPUBLISH_MODAL_ALIAS","UMB_DOCUMENT_UNPUBLISH_MODAL","UMB_DOCUMENT_PUBLISHING_WORKSPACE_CONTEXT","UMB_DOCUMENT_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_DOCUMENT_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_DOCUMENT_REFERENCE_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_STORE_ALIAS","UMB_DOCUMENT_DETAIL_STORE_CONTEXT","UMB_DOCUMENT_ITEM_REPOSITORY_ALIAS","UMB_DOCUMENT_STORE_ALIAS","UMB_DOCUMENT_ITEM_STORE_CONTEXT","UMB_DOCUMENT_URL_REPOSITORY_ALIAS","UMB_DOCUMENT_URL_STORE_ALIAS","UMB_DOCUMENT_URL_STORE_CONTEXT","UMB_DOCUMENT_VALIDATION_REPOSITORY_ALIAS","UMB_ROLLBACK_MODAL_ALIAS","UMB_ROLLBACK_MODAL","UMB_ROLLBACK_REPOSITORY_ALIAS","UMB_DOCUMENT_SEARCH_PROVIDER_ALIAS","UMB_DOCUMENT_TREE_STORE_CONTEXT","UMB_DOCUMENT_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_TREE_STORE_ALIAS","UMB_DOCUMENT_TREE_ALIAS","UMB_DOCUMENT_USER_PERMISSION_CONDITION_ALIAS","UMB_USER_PERMISSION_DOCUMENT_CREATE","UMB_USER_PERMISSION_DOCUMENT_READ","UMB_USER_PERMISSION_DOCUMENT_UPDATE","UMB_USER_PERMISSION_DOCUMENT_DELETE","UMB_USER_PERMISSION_DOCUMENT_CREATE_BLUEPRINT","UMB_USER_PERMISSION_DOCUMENT_NOTIFICATIONS","UMB_USER_PERMISSION_DOCUMENT_PUBLISH","UMB_USER_PERMISSION_DOCUMENT_PERMISSIONS","UMB_USER_PERMISSION_DOCUMENT_UNPUBLISH","UMB_USER_PERMISSION_DOCUMENT_DUPLICATE","UMB_USER_PERMISSION_DOCUMENT_MOVE","UMB_USER_PERMISSION_DOCUMENT_SORT","UMB_USER_PERMISSION_DOCUMENT_CULTURE_AND_HOSTNAMES","UMB_USER_PERMISSION_DOCUMENT_PUBLIC_ACCESS","UMB_USER_PERMISSION_DOCUMENT_ROLLBACK","UMB_DOCUMENT_PERMISSION_REPOSITORY_ALIAS","UMB_DOCUMENT_IS_NOT_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_IS_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_WORKSPACE_ALIAS","UMB_DOCUMENT_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_DOCUMENT_WORKSPACE_CONTEXT"] + consts: ["UMB_DOCUMENT_COLLECTION_ALIAS","UMB_DOCUMENT_COLLECTION_CONTEXT","UMB_DOCUMENT_COLLECTION_REPOSITORY_ALIAS","UMB_DOCUMENT_GRID_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_TABLE_COLLECTION_VIEW_ALIAS","UMB_DOCUMENT_CREATE_OPTIONS_MODAL","UMB_CREATE_BLUEPRINT_MODAL","UMB_DOCUMENT_CREATE_BLUEPRINT_REPOSITORY_ALIAS","UMB_CULTURE_AND_HOSTNAMES_MODAL","UMB_DOCUMENT_CULTURE_AND_HOSTNAMES_REPOSITORY_ALIAS","UMB_DUPLICATE_DOCUMENT_MODAL","UMB_DUPLICATE_DOCUMENT_MODAL_ALIAS","UMB_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_MODAL","UMB_DOCUMENT_NOTIFICATIONS_MODAL_ALIAS","UMB_DOCUMENT_NOTIFICATIONS_REPOSITORY_ALIAS","UMB_PUBLIC_ACCESS_MODAL","UMB_DOCUMENT_PUBLIC_ACCESS_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_DUPLICATE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_MOVE_DOCUMENT_REPOSITORY_ALIAS","UMB_BULK_TRASH_DOCUMENT_REPOSITORY_ALIAS","UMB_DOCUMENT_ENTITY_TYPE","UMB_DOCUMENT_ROOT_ENTITY_TYPE","UMB_DOCUMENT_CONFIGURATION_CONTEXT","UMB_CONTENT_MENU_ALIAS","UMB_DOCUMENT_PICKER_MODAL","UMB_DOCUMENT_SAVE_MODAL","UMB_DOCUMENT_SAVE_MODAL_ALIAS","UMB_DOCUMENT_WORKSPACE_PATH","UMB_CREATE_FROM_BLUEPRINT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_CREATE_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_EDIT_DOCUMENT_WORKSPACE_PATH_PATTERN","UMB_DOCUMENT_PROPERTY_DATASET_CONTEXT","UMB_DOCUMENT_PUBLISH_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_MODAL","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL_ALIAS","UMB_DOCUMENT_PUBLISH_WITH_DESCENDANTS_MODAL","UMB_DOCUMENT_PUBLISHING_REPOSITORY_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL_ALIAS","UMB_DOCUMENT_SCHEDULE_MODAL","UMB_DOCUMENT_UNPUBLISH_MODAL_ALIAS","UMB_DOCUMENT_UNPUBLISH_MODAL","UMB_DOCUMENT_PUBLISHING_WORKSPACE_CONTEXT","UMB_DOCUMENT_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_DOCUMENT_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_ALIAS","UMB_DOCUMENT_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_DOCUMENT_REFERENCE_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_REPOSITORY_ALIAS","UMB_DOCUMENT_DETAIL_STORE_ALIAS","UMB_DOCUMENT_DETAIL_STORE_CONTEXT","UMB_DOCUMENT_ITEM_REPOSITORY_ALIAS","UMB_DOCUMENT_STORE_ALIAS","UMB_DOCUMENT_ITEM_STORE_CONTEXT","UMB_DOCUMENT_VALIDATION_REPOSITORY_ALIAS","UMB_ROLLBACK_MODAL_ALIAS","UMB_ROLLBACK_MODAL","UMB_ROLLBACK_REPOSITORY_ALIAS","UMB_DOCUMENT_SEARCH_PROVIDER_ALIAS","UMB_DOCUMENT_TREE_STORE_CONTEXT","UMB_DOCUMENT_TREE_REPOSITORY_ALIAS","UMB_DOCUMENT_TREE_STORE_ALIAS","UMB_DOCUMENT_TREE_ALIAS","UMB_DOCUMENT_URL_REPOSITORY_ALIAS","UMB_DOCUMENT_URL_STORE_ALIAS","UMB_DOCUMENT_URL_STORE_CONTEXT","UMB_DOCUMENT_USER_PERMISSION_CONDITION_ALIAS","UMB_USER_PERMISSION_DOCUMENT_CREATE","UMB_USER_PERMISSION_DOCUMENT_READ","UMB_USER_PERMISSION_DOCUMENT_UPDATE","UMB_USER_PERMISSION_DOCUMENT_DELETE","UMB_USER_PERMISSION_DOCUMENT_CREATE_BLUEPRINT","UMB_USER_PERMISSION_DOCUMENT_NOTIFICATIONS","UMB_USER_PERMISSION_DOCUMENT_PUBLISH","UMB_USER_PERMISSION_DOCUMENT_PERMISSIONS","UMB_USER_PERMISSION_DOCUMENT_UNPUBLISH","UMB_USER_PERMISSION_DOCUMENT_DUPLICATE","UMB_USER_PERMISSION_DOCUMENT_MOVE","UMB_USER_PERMISSION_DOCUMENT_SORT","UMB_USER_PERMISSION_DOCUMENT_CULTURE_AND_HOSTNAMES","UMB_USER_PERMISSION_DOCUMENT_PUBLIC_ACCESS","UMB_USER_PERMISSION_DOCUMENT_ROLLBACK","UMB_DOCUMENT_PERMISSION_REPOSITORY_ALIAS","UMB_DOCUMENT_IS_NOT_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_IS_TRASHED_CONDITION_ALIAS","UMB_DOCUMENT_WORKSPACE_ALIAS","UMB_DOCUMENT_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_DOCUMENT_WORKSPACE_CONTEXT"] }, { path: '@umbraco-cms/backoffice/entity-action', @@ -212,7 +212,7 @@ export const foundConsts = [{ }, { path: '@umbraco-cms/backoffice/media', - consts: ["UMB_MEDIA_COLLECTION_ALIAS","UMB_MEDIA_COLLECTION_CONTEXT","UMB_MEDIA_COLLECTION_REPOSITORY_ALIAS","UMB_MEDIA_GRID_COLLECTION_VIEW_ALIAS","UMB_MEDIA_TABLE_COLLECTION_VIEW_ALIAS","UMB_DROPZONE_MEDIA_TYPE_PICKER_MODAL","UMB_MEDIA_CREATE_OPTIONS_MODAL","UMB_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_MEDIA_REPOSITORY_ALIAS","UMB_BULK_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_BULK_TRASH_MEDIA_REPOSITORY_ALIAS","UMB_MEDIA_ENTITY_TYPE","UMB_MEDIA_ROOT_ENTITY_TYPE","UMB_MEDIA_PLACEHOLDER_ENTITY_TYPE","UMB_MEDIA_MENU_ALIAS","UMB_IMAGE_CROPPER_EDITOR_MODAL","UMB_MEDIA_CAPTION_ALT_TEXT_MODAL","UMB_MEDIA_PICKER_MODAL","UMB_MEDIA_WORKSPACE_PATH","UMB_CREATE_MEDIA_WORKSPACE_PATH_PATTERN","UMB_EDIT_MEDIA_WORKSPACE_PATH_PATTERN","UMB_MEDIA_VARIANT_CONTEXT","UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_MEDIA_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_MEDIA_REFERENCE_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_STORE_ALIAS","UMB_MEDIA_DETAIL_STORE_CONTEXT","UMB_MEDIA_ITEM_REPOSITORY_ALIAS","UMB_MEDIA_STORE_ALIAS","UMB_MEDIA_ITEM_STORE_CONTEXT","UMB_MEDIA_URL_REPOSITORY_ALIAS","UMB_MEDIA_URL_STORE_ALIAS","UMB_MEDIA_URL_STORE_CONTEXT","UMB_MEDIA_VALIDATION_REPOSITORY_ALIAS","UMB_MEDIA_SEARCH_PROVIDER_ALIAS","UMB_MEDIA_TREE_REPOSITORY_ALIAS","UMB_MEDIA_TREE_STORE_ALIAS","UMB_MEDIA_TREE_ALIAS","UMB_MEDIA_TREE_PICKER_MODAL","UMB_MEDIA_TREE_STORE_CONTEXT","UMB_MEDIA_WORKSPACE_ALIAS","UMB_MEMBER_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_MEDIA_WORKSPACE_CONTEXT"] + consts: ["UMB_MEDIA_COLLECTION_ALIAS","UMB_MEDIA_COLLECTION_CONTEXT","UMB_MEDIA_COLLECTION_REPOSITORY_ALIAS","UMB_MEDIA_GRID_COLLECTION_VIEW_ALIAS","UMB_MEDIA_TABLE_COLLECTION_VIEW_ALIAS","UMB_DROPZONE_MEDIA_TYPE_PICKER_MODAL","UMB_MEDIA_CREATE_OPTIONS_MODAL","UMB_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_SORT_CHILDREN_OF_MEDIA_REPOSITORY_ALIAS","UMB_BULK_MOVE_MEDIA_REPOSITORY_ALIAS","UMB_BULK_TRASH_MEDIA_REPOSITORY_ALIAS","UMB_MEDIA_ENTITY_TYPE","UMB_MEDIA_ROOT_ENTITY_TYPE","UMB_MEDIA_PLACEHOLDER_ENTITY_TYPE","UMB_MEDIA_MENU_ALIAS","UMB_IMAGE_CROPPER_EDITOR_MODAL","UMB_MEDIA_CAPTION_ALT_TEXT_MODAL","UMB_MEDIA_PICKER_MODAL","UMB_MEDIA_WORKSPACE_PATH","UMB_CREATE_MEDIA_WORKSPACE_PATH_PATTERN","UMB_EDIT_MEDIA_WORKSPACE_PATH_PATTERN","UMB_MEDIA_VARIANT_CONTEXT","UMB_MEDIA_RECYCLE_BIN_ROOT_ENTITY_TYPE","UMB_MEDIA_RECYCLE_BIN_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_REPOSITORY_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_ALIAS","UMB_MEDIA_RECYCLE_BIN_TREE_STORE_CONTEXT","UMB_MEDIA_REFERENCE_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_REPOSITORY_ALIAS","UMB_MEDIA_DETAIL_STORE_ALIAS","UMB_MEDIA_DETAIL_STORE_CONTEXT","UMB_MEDIA_ITEM_REPOSITORY_ALIAS","UMB_MEDIA_STORE_ALIAS","UMB_MEDIA_ITEM_STORE_CONTEXT","UMB_MEDIA_VALIDATION_REPOSITORY_ALIAS","UMB_MEDIA_SEARCH_PROVIDER_ALIAS","UMB_MEDIA_TREE_REPOSITORY_ALIAS","UMB_MEDIA_TREE_STORE_ALIAS","UMB_MEDIA_TREE_ALIAS","UMB_MEDIA_TREE_PICKER_MODAL","UMB_MEDIA_TREE_STORE_CONTEXT","UMB_MEDIA_URL_REPOSITORY_ALIAS","UMB_MEDIA_URL_STORE_ALIAS","UMB_MEDIA_URL_STORE_CONTEXT","UMB_MEDIA_WORKSPACE_ALIAS","UMB_MEMBER_DETAIL_MODEL_VARIANT_SCAFFOLD","UMB_MEDIA_WORKSPACE_CONTEXT"] }, { path: '@umbraco-cms/backoffice/member-group',