Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
79 commits
Select commit Hold shift + click to select a range
207c72f
todos
nielslyngsoe Mar 29, 2025
78b3d76
navigation context
nielslyngsoe Mar 29, 2025
af40088
replace raw manifests with view context
nielslyngsoe Mar 29, 2025
982c6b9
Array State has method
nielslyngsoe Mar 29, 2025
7365fc7
rename to hint and much more
nielslyngsoe Mar 29, 2025
d482a21
Notes for later
nielslyngsoe Mar 29, 2025
b492203
correcting one word
nielslyngsoe Mar 29, 2025
7724575
more notes
nielslyngsoe Mar 29, 2025
5d2aab7
update JS Docs
nielslyngsoe Mar 29, 2025
77d546c
Merge remote-tracking branch 'origin/main' into v16/feature/workspace…
nielslyngsoe May 6, 2025
e2d8c13
update tests for getHasOne
nielslyngsoe May 6, 2025
55c8a08
fix context api usage
nielslyngsoe May 6, 2025
62013f2
update code for v.16
nielslyngsoe May 6, 2025
dd83e84
correct test
nielslyngsoe May 6, 2025
4642e0e
export UMB_WORKSPACE_VIEW_CONTEXT
nielslyngsoe May 6, 2025
5f59f4b
minor corrections
nielslyngsoe May 6, 2025
1ba948e
rename to _hintMap
nielslyngsoe May 6, 2025
97533a4
refactor part 1
nielslyngsoe May 8, 2025
adfda51
Merge branch 'main' into v16/feature/workspace-view-navigation-context
nielslyngsoe Aug 11, 2025
61ceb57
update version number in comment
nielslyngsoe Aug 11, 2025
ff46b18
clear method for array states
nielslyngsoe Aug 14, 2025
fa5067c
declare hint import map
nielslyngsoe Aug 14, 2025
47f03e2
mega refactor
nielslyngsoe Aug 14, 2025
42f6863
final corrections for working POC
nielslyngsoe Aug 14, 2025
0408fa0
clean up path logic
nielslyngsoe Aug 14, 2025
536069a
implement scaffold
nielslyngsoe Aug 15, 2025
bebc5ec
propagation and inheritance from view to workspace
nielslyngsoe Aug 15, 2025
9b6a242
separate types from classes
nielslyngsoe Aug 15, 2025
843b889
refactor to view context
nielslyngsoe Aug 15, 2025
26cd519
rename editor navigation context to editor context
nielslyngsoe Aug 15, 2025
4b16be5
propagate removals
nielslyngsoe Aug 15, 2025
0758e5f
clean up notes
nielslyngsoe Aug 15, 2025
45a64fa
Merge branch 'main' into v16/feature/workspace-view-navigation-context
nielslyngsoe Aug 15, 2025
613aae7
Hints for Content Tabs
nielslyngsoe Aug 15, 2025
1d48d6a
use const path
nielslyngsoe Aug 15, 2025
421af86
handle gone parent
nielslyngsoe Aug 15, 2025
2ce17d3
added comments on something to be looked at
nielslyngsoe Aug 15, 2025
0936768
hints context types
nielslyngsoe Aug 15, 2025
4c15a85
contentTypeMergedContainers
nielslyngsoe Aug 15, 2025
d6395d0
lint fixes
nielslyngsoe Aug 19, 2025
4c1df67
public contentTypeMergedContainers
nielslyngsoe Aug 19, 2025
de765be
refactor property structure helper class
nielslyngsoe Aug 19, 2025
3b07192
a few notes for Presets
nielslyngsoe Aug 19, 2025
c275279
set variant ID instead of parsing it to the constructor
nielslyngsoe Aug 20, 2025
8191111
do not inject root to the path
nielslyngsoe Aug 21, 2025
db1d91d
adjust structure manager logic
nielslyngsoe Aug 21, 2025
14292f1
UmbPropertyTypeContainerMergedModel type update
nielslyngsoe Aug 21, 2025
bb934d9
correct mergedContainersOfParentIdAndType
nielslyngsoe Aug 21, 2025
e6f7432
refactor to utilize new observable for better outcome and performance
nielslyngsoe Aug 21, 2025
915eeb0
Merge branch 'main' into v16/feature/workspace-view-navigation-context
nielslyngsoe Aug 21, 2025
ae46550
fix lint errors
nielslyngsoe Aug 21, 2025
34d6a1a
fix missing import
nielslyngsoe Aug 21, 2025
19a262c
Apply suggestion from @Copilot
nielslyngsoe Aug 21, 2025
240dc36
Update src/Umbraco.Web.UI.Client/src/packages/core/hint/context/hints…
nielslyngsoe Aug 21, 2025
de7689d
Update src/Umbraco.Web.UI.Client/src/packages/content/content/workspa…
nielslyngsoe Aug 21, 2025
b395af8
Update src/Umbraco.Web.UI.Client/src/packages/content/content/workspa…
nielslyngsoe Aug 21, 2025
04b46ea
Merge branch 'v16/feature/workspace-view-navigation-context' into v16…
nielslyngsoe Aug 21, 2025
01885d0
clean up
nielslyngsoe Aug 21, 2025
da63fc9
remove console.log
nielslyngsoe Aug 21, 2025
0530171
Merge branch 'v16/feature/workspace-view-navigation-context' into v16…
nielslyngsoe Aug 21, 2025
982a811
declare new exports of core
nielslyngsoe Aug 21, 2025
aa4ab26
Merge branch 'v16/feature/workspace-view-navigation-context' into v16…
nielslyngsoe Aug 21, 2025
f54af57
Update src/Umbraco.Web.UI.Client/src/packages/content/content-type/wo…
nielslyngsoe Aug 21, 2025
59e49d4
clean up
nielslyngsoe Aug 21, 2025
752afb0
fix const export
nielslyngsoe Aug 22, 2025
c3a2f91
Merge branch 'main' into v16/feature/workspace-view-navigation-context
iOvergaard Aug 22, 2025
8c98c38
remove root from hints path
nielslyngsoe Aug 22, 2025
a5a4a5a
also check for invariant
nielslyngsoe Aug 22, 2025
a5fd19c
Merge branch 'v16/feature/workspace-view-navigation-context' into v16…
nielslyngsoe Aug 25, 2025
6357039
Merge branch 'main' into v16/feature/structure-manager-refactor-imple…
nielslyngsoe Aug 25, 2025
89af479
name more as legacy
nielslyngsoe Aug 25, 2025
c63eee4
Merge branch 'main' into v16/feature/structure-manager-refactor-imple…
nielslyngsoe Aug 28, 2025
30720e7
Merge branch 'main' into v16/feature/structure-manager-refactor-imple…
nielslyngsoe Aug 28, 2025
6f923ab
fix eslint
nielslyngsoe Aug 28, 2025
84f198c
Merge branch 'main' into v16/feature/structure-manager-refactor-imple…
iOvergaard Aug 29, 2025
4740b9f
Merge branch 'main' into v16/feature/structure-manager-refactor-imple…
nielslyngsoe Aug 29, 2025
38371b0
fix container id setting
nielslyngsoe Aug 29, 2025
3fde465
fix resetting inherited property
nielslyngsoe Aug 29, 2025
c512bfa
fix re-rendering problem
nielslyngsoe Aug 29, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { css, html, customElement, state, repeat, nothing } from '@umbraco-cms/b
import { UmbTextStyles } from '@umbraco-cms/backoffice/style';
import { UmbContentTypeContainerStructureHelper } from '@umbraco-cms/backoffice/content-type';
import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element';
import type { UmbPropertyTypeContainerModel } from '@umbraco-cms/backoffice/content-type';
import type { UmbPropertyTypeContainerMergedModel } from '@umbraco-cms/backoffice/content-type';
import type { UmbWorkspaceViewElement } from '@umbraco-cms/backoffice/workspace';

/**
Expand All @@ -20,10 +20,10 @@ export class UmbBlockWorkspaceViewEditContentNoRouterElement extends UmbLitEleme
private _hasRootGroups = false;

@state()
private _tabs?: Array<UmbPropertyTypeContainerModel>;
private _tabs?: Array<UmbPropertyTypeContainerMergedModel>;

@state()
private _activeTabId?: string | null | undefined;
private _activeTabKey?: string | null | undefined;

//@state()
//private _activeTabName?: string | null | undefined;
Expand All @@ -36,7 +36,7 @@ export class UmbBlockWorkspaceViewEditContentNoRouterElement extends UmbLitEleme

this.#tabsStructureHelper.setIsRoot(true);
this.#tabsStructureHelper.setContainerChildType('Tab');
this.observe(this.#tabsStructureHelper.mergedContainers, (tabs) => {
this.observe(this.#tabsStructureHelper.childContainers, (tabs) => {
this._tabs = tabs;
this.#checkDefaultTabName();
});
Expand Down Expand Up @@ -68,20 +68,20 @@ export class UmbBlockWorkspaceViewEditContentNoRouterElement extends UmbLitEleme
if (!this._tabs || !this.#blockWorkspace) return;

// Find the default tab to grab:
if (this._activeTabId === undefined) {
if (this._activeTabKey === undefined) {
if (this._hasRootGroups) {
//this._activeTabName = null;
this._activeTabId = null;
this._activeTabKey = null;
} else if (this._tabs.length > 0) {
//this._activeTabName = this._tabs[0].name;
this._activeTabId = this._tabs[0].id;
this._activeTabKey = this._tabs[0].key;
}
}
}

#setTabName(tabName: string | undefined | null, tabId: string | null | undefined) {
#setTabName(tabName: string | undefined | null, tabKey: string | null | undefined) {
//this._activeTabName = tabName;
this._activeTabId = tabId;
this._activeTabKey = tabKey;
}

override render() {
Expand All @@ -93,7 +93,7 @@ export class UmbBlockWorkspaceViewEditContentNoRouterElement extends UmbLitEleme
? html`
<uui-tab
label="Content"
.active=${null === this._activeTabId}
.active=${null === this._activeTabKey}
@click=${() => this.#setTabName(null, null)}
>Content</uui-tab
>
Expand All @@ -105,19 +105,19 @@ export class UmbBlockWorkspaceViewEditContentNoRouterElement extends UmbLitEleme
(tab) => {
return html`<uui-tab
label=${tab.name ?? 'Unnamed'}
.active=${tab.id === this._activeTabId}
@click=${() => this.#setTabName(tab.name, tab.id)}
.active=${tab.key === this._activeTabKey}
@click=${() => this.#setTabName(tab.name, tab.key)}
>${tab.name}</uui-tab
>`;
},
)}
</uui-tab-group>`
: nothing}
${this._activeTabId !== undefined
${this._activeTabKey !== undefined
? html`<umb-block-workspace-view-edit-tab
.managerName=${'content'}
.hideSingleGroup=${true}
.containerId=${this._activeTabId}>
.containerId=${this._activeTabKey}>
</umb-block-workspace-view-edit-tab>`
: nothing}
`;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { UMB_BLOCK_WORKSPACE_CONTEXT } from '../../block-workspace.context-token.js';
import { css, html, customElement, property, state, repeat } from '@umbraco-cms/backoffice/external/lit';
import { UmbTextStyles } from '@umbraco-cms/backoffice/style';
import type { UmbContentTypeModel, UmbPropertyTypeContainerModel } from '@umbraco-cms/backoffice/content-type';
import type { UmbContentTypeModel, UmbPropertyTypeContainerMergedModel } from '@umbraco-cms/backoffice/content-type';
import { UmbContentTypeContainerStructureHelper } from '@umbraco-cms/backoffice/content-type';
import { UmbLitElement } from '@umbraco-cms/backoffice/lit-element';

Expand Down Expand Up @@ -42,7 +42,7 @@ export class UmbBlockWorkspaceViewEditTabElement extends UmbLitElement {
hideSingleGroup = false;

@state()
private _groups: Array<UmbPropertyTypeContainerModel> = [];
private _groups: Array<UmbPropertyTypeContainerMergedModel> = [];

@state()
private _hasProperties = false;
Expand All @@ -60,7 +60,7 @@ export class UmbBlockWorkspaceViewEditTabElement extends UmbLitElement {
if (!this.#blockWorkspace || !this.#managerName) return;
this.#groupStructureHelper.setStructureManager(this.#blockWorkspace[this.#managerName].structure);
this.observe(
this.#groupStructureHelper.mergedContainers,
this.#groupStructureHelper.childContainers,
(groups) => {
this._groups = groups;
},
Expand Down Expand Up @@ -89,18 +89,18 @@ export class UmbBlockWorkspaceViewEditTabElement extends UmbLitElement {
? this.renderGroup(this._groups[0])
: repeat(
this._groups,
(group) => group.id,
(group) => group.key,
(group) => html` <uui-box .headline=${group.name}>${this.renderGroup(group)}</uui-box>`,
)}
`;
}

renderGroup(group: UmbPropertyTypeContainerModel) {
renderGroup(group: UmbPropertyTypeContainerMergedModel) {
return html`
<umb-block-workspace-view-edit-properties
.managerName=${this.#managerName}
data-mark="property-group:${group.name}"
.containerId=${group.id}></umb-block-workspace-view-edit-properties>
.containerId=${group.ids[0]}></umb-block-workspace-view-edit-properties>
`;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { UMB_BLOCK_WORKSPACE_CONTEXT } from '../../block-workspace.context-token
import type { UmbBlockWorkspaceViewEditTabElement } from './block-workspace-view-edit-tab.element.js';
import { css, html, customElement, state, repeat, property } from '@umbraco-cms/backoffice/external/lit';
import { UmbTextStyles } from '@umbraco-cms/backoffice/style';
import type { UmbContentTypeModel, UmbPropertyTypeContainerModel } from '@umbraco-cms/backoffice/content-type';
import type { UmbContentTypeModel, UmbPropertyTypeContainerMergedModel } from '@umbraco-cms/backoffice/content-type';
import { UmbContentTypeContainerStructureHelper } from '@umbraco-cms/backoffice/content-type';
import type { UmbRoute, UmbRouterSlotChangeEvent, UmbRouterSlotInitEvent } from '@umbraco-cms/backoffice/router';
import { encodeFolderName } from '@umbraco-cms/backoffice/router';
Expand Down Expand Up @@ -34,7 +34,7 @@ export class UmbBlockWorkspaceViewEditElement extends UmbLitElement implements U
private _routes: UmbRoute[] = [];

@state()
private _tabs?: Array<UmbPropertyTypeContainerModel>;
private _tabs?: Array<UmbPropertyTypeContainerMergedModel>;

@state()
private _routerPath?: string;
Expand All @@ -48,7 +48,7 @@ export class UmbBlockWorkspaceViewEditElement extends UmbLitElement implements U
this.#tabsStructureHelper.setIsRoot(true);
this.#tabsStructureHelper.setContainerChildType('Tab');
this.observe(
this.#tabsStructureHelper.mergedContainers,
this.#tabsStructureHelper.childContainers,
(tabs) => {
this._tabs = tabs;
this.#createRoutes();
Expand Down Expand Up @@ -102,7 +102,7 @@ export class UmbBlockWorkspaceViewEditElement extends UmbLitElement implements U
component: () => import('./block-workspace-view-edit-tab.element.js'),
setup: (component) => {
(component as UmbBlockWorkspaceViewEditTabElement).managerName = this.#managerName;
(component as UmbBlockWorkspaceViewEditTabElement).containerId = tab.id;
(component as UmbBlockWorkspaceViewEditTabElement).containerId = tab.ids[0];
},
});
});
Expand Down
Loading
Loading