diff --git a/src/Umbraco.Web.UI.Client/src/packages/block/block/workspace/manifests.ts b/src/Umbraco.Web.UI.Client/src/packages/block/block/workspace/manifests.ts index 8d31bc6c3f..8b25bde2eb 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/block/block/workspace/manifests.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/block/block/workspace/manifests.ts @@ -1,6 +1,6 @@ -import { UMB_BLOCK_WORKSPACE_ALIAS } from './index.js'; import { UmbSubmitWorkspaceAction } from '@umbraco-cms/backoffice/workspace'; import type { ManifestTypes } from '@umbraco-cms/backoffice/extension-registry'; +import { UMB_BLOCK_WORKSPACE_ALIAS } from './index.js'; export const manifests: Array = [ { @@ -73,8 +73,6 @@ export const manifests: Array = [ alias: 'Umb.Condition.WorkspaceAlias', match: UMB_BLOCK_WORKSPACE_ALIAS, }, - ], - TODO_conditions: [ { alias: 'Umb.Condition.BlockWorkspaceHasSettings', }, diff --git a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/components/workspace-editor/workspace-editor.element.ts b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/components/workspace-editor/workspace-editor.element.ts index aa80c9d47a..752797671f 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/core/workspace/components/workspace-editor/workspace-editor.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/core/workspace/components/workspace-editor/workspace-editor.element.ts @@ -56,10 +56,10 @@ export class UmbWorkspaceEditorElement extends UmbLitElement { } private _createRoutes() { - this._routes = []; + let newRoutes: UmbRoute[] = []; if (this._workspaceViews.length > 0) { - this._routes = this._workspaceViews.map((manifest) => { + newRoutes = this._workspaceViews.map((manifest) => { return { path: `view/${manifest.meta.pathname}`, component: () => createExtensionElement(manifest), @@ -72,14 +72,17 @@ export class UmbWorkspaceEditorElement extends UmbLitElement { }); // If we have a post fix then we need to add a direct from the empty url of the split-view-index: - const firstView = this._workspaceViews[0]; - if (firstView) { - this._routes.push({ + // TODO: This is problematic, cause if a workspaceView appears later, then this takes over. And it is also a problem if it does not use redirect, but just a view defined with and empty path. + /*const firstRoute = newRoutes[0]; + if (firstRoute) { + newRoutes.push({ path: ``, - redirectTo: `view/${firstView.meta.pathname}`, + redirectTo: firstRoute.path, }); - } + }*/ } + + this._routes = newRoutes; } override render() {