diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts
index 845041a25f..24dd2e2cfa 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.context.ts
@@ -1,10 +1,8 @@
import { UmbWorkspaceContentContext } from '../workspace/workspace-content/workspace-content.context';
import type { DataTypeDetails } from '@umbraco-cms/models';
-import { UmbControllerHostInterface } from 'src/core/controller/controller-host.mixin';
-import { createObservablePart } from '@umbraco-cms/observable-api';
-import { UmbContextProviderController } from 'src/core/context-api/provide/context-provider.controller';
-import { UmbContextConsumerController } from 'src/core/context-api/consume/context-consumer.controller';
-import { UniqueObjectBehaviorSubject } from 'src/core/observable-api/unique-object-behavior-subject';
+import { UmbControllerHostInterface } from '@umbraco-cms/controller';
+import { createObservablePart, UniqueObjectBehaviorSubject } from '@umbraco-cms/observable-api';
+import { UmbContextConsumerController, UmbContextProviderController } from '@umbraco-cms/context-api';
// If we get this from the server then we can consider using TypeScripts Partial<> around the model from the Management-API.
export type WorkspacePropertyData
= {
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.element.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.element.ts
index d9f15582ed..8a8945effb 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.element.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace-property/workspace-property.element.ts
@@ -9,7 +9,7 @@ import type { DataTypePropertyData, ManifestPropertyEditorUI, ManifestTypes } fr
import '../../property-actions/shared/property-action-menu/property-action-menu.element';
import '../../../../backoffice/shared/components/workspace/workspace-property-layout/workspace-property-layout.element';
-import { UmbObserverController } from 'src/core/observable-api/observer.controller';
+import { UmbObserverController } from '@umbraco-cms/observable-api';
import { UmbLitElement } from '@umbraco-cms/element';
/**
@@ -49,10 +49,10 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
];
@state()
- private _label?:string;
+ private _label?: string;
@state()
- private _description?:string;
+ private _description?: string;
/**
* Label. Name of the property
@@ -98,7 +98,7 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
private _propertyEditorUIAlias = '';
@property({ type: String, attribute: 'property-editor-ui-alias' })
public set propertyEditorUIAlias(value: string) {
- if(this._propertyEditorUIAlias === value) return;
+ if (this._propertyEditorUIAlias === value) return;
this._propertyEditorUIAlias = value;
this._observePropertyEditorUI();
}
@@ -110,7 +110,7 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
* @attr
* @default undefined
*/
- @property({attribute: false })
+ @property({ attribute: false })
public set value(value: unknown) {
this._propertyContext.setValue(value);
}
@@ -131,7 +131,6 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
@state()
private _element?: { value?: any; config?: any } & HTMLElement; // TODO: invent interface for propertyEditorUI.
-
private _propertyContext = new UmbWorkspacePropertyContext(this);
private propertyEditorUIObserver?: UmbObserverController;
@@ -139,7 +138,6 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
private _valueObserver?: UmbObserverController;
private _configObserver?: UmbObserverController;
-
constructor() {
super();
@@ -149,21 +147,23 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
this.observe(this._propertyContext.description, (description) => {
this._description = description;
});
-
}
private _onPropertyEditorChange = (e: CustomEvent) => {
const target = e.composedPath()[0] as any;
- this.value = target.value;// Sets value in context.
+ this.value = target.value; // Sets value in context.
e.stopPropagation();
};
private _observePropertyEditorUI() {
this.propertyEditorUIObserver?.destroy();
- this.propertyEditorUIObserver = this.observe(umbExtensionsRegistry.getByTypeAndAlias('propertyEditorUI', this._propertyEditorUIAlias), (manifest) => {
- this._gotEditorUI(manifest);
- });
+ this.propertyEditorUIObserver = this.observe(
+ umbExtensionsRegistry.getByTypeAndAlias('propertyEditorUI', this._propertyEditorUIAlias),
+ (manifest) => {
+ this._gotEditorUI(manifest);
+ }
+ );
}
private _gotEditorUI(manifest?: ManifestPropertyEditorUI | null) {
@@ -183,33 +183,34 @@ export class UmbWorkspacePropertyElement extends UmbLitElement {
this._valueObserver?.destroy();
this._configObserver?.destroy();
- if(this._element) {
+ if (this._element) {
this._element.addEventListener('property-value-change', this._onPropertyEditorChange as any as EventListener);
this._valueObserver = this.observe(this._propertyContext.value, (value) => {
- if(this._element) {
+ if (this._element) {
this._element.value = value;
}
});
this._configObserver = this.observe(this._propertyContext.config, (config) => {
- if(this._element) {
+ if (this._element) {
this._element.config = config;
}
});
}
this.requestUpdate('element', oldValue);
-
})
.catch(() => {
// TODO: loading JS failed so we should do some nice UI. (This does only happen if extension has a js prop, otherwise we concluded that no source was needed resolved the load.)
});
}
-
render() {
return html`
-
+
${this._renderPropertyActionMenu()}
${this._element}
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/views/collection/workspace-view-collection.element.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/views/collection/workspace-view-collection.element.ts
index 882dc1bdf9..255b7eb11b 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/views/collection/workspace-view-collection.element.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/views/collection/workspace-view-collection.element.ts
@@ -3,15 +3,16 @@ import { UUITextStyles } from '@umbraco-ui/uui-css/lib';
import { customElement } from 'lit/decorators.js';
import { ifDefined } from 'lit-html/directives/if-defined.js';
import { UmbWorkspaceContentContext } from '../../workspace-content.context';
+import { UmbMediaTreeStore } from '../../../../../../media/media/media.tree.store';
import {
UmbCollectionContext,
UMB_COLLECTION_CONTEXT_TOKEN,
-} from 'src/backoffice/shared/collection/collection.context';
-import { UmbMediaStore, UmbMediaStoreItemType } from 'src/backoffice/media/media/media.store';
+} from '../../../../../../shared/collection/collection.context';
import '../../../../../../shared/components/content-property/content-property.element';
import '../../../../../../shared/collection/dashboards/dashboard-collection.element';
import { UmbLitElement } from '@umbraco-cms/element';
+import { FolderTreeItem } from '@umbraco-cms/backend-api';
@customElement('umb-workspace-view-collection')
export class UmbWorkspaceViewCollectionElement extends UmbLitElement {
@@ -27,7 +28,7 @@ export class UmbWorkspaceViewCollectionElement extends UmbLitElement {
private _workspaceContext?: UmbWorkspaceContentContext;
- private _collectionContext?: UmbCollectionContext;
+ private _collectionContext?: UmbCollectionContext;
constructor() {
super();
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/workspace-content.context.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/workspace-content.context.ts
index f700645f0a..3a494630a3 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/workspace-content.context.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/components/workspace/workspace-content/workspace-content.context.ts
@@ -1,18 +1,16 @@
import { v4 as uuidv4 } from 'uuid';
-import { UmbNotificationService, UMB_NOTIFICATION_SERVICE_CONTEXT_TOKEN } from '../../../../../core/notification';
-import { UmbNotificationDefaultData } from '../../../../../core/notification/layouts/default';
-import { UmbNodeStoreBase } from '@umbraco-cms/stores/store';
+import { UmbNotificationService, UMB_NOTIFICATION_SERVICE_CONTEXT_TOKEN, UmbNotificationDefaultData } from '@umbraco-cms/notification';
import { UmbControllerHostInterface } from '@umbraco-cms/controller';
import { UmbContextConsumerController, UmbContextProviderController } from '@umbraco-cms/context-api';
-import { EntityTreeItem } from '@umbraco-cms/backend-api';
-import { UniqueBehaviorSubject, UmbObserverController } from '@umbraco-cms/observable-api';
-import { createObservablePart } from '@umbraco-cms/observable-api';
+import { UniqueBehaviorSubject, UmbObserverController, createObservablePart } from '@umbraco-cms/observable-api';
+import { UmbContentStore } from '@umbraco-cms/store';
+import type { ContentTreeItem } from '@umbraco-cms/backend-api';
// TODO: Consider if its right to have this many class-inheritance of WorkspaceContext
// TODO: Could we extract this code into a 'Manager' of its own, which will be instantiated by the concrete Workspace Context. This will be more transparent and 'reuseable'
export abstract class UmbWorkspaceContentContext<
- ContentTypeType extends EntityTreeItem = EntityTreeItem,
- StoreType extends UmbNodeStoreBase = UmbNodeStoreBase
+ ContentTypeType extends ContentTreeItem = ContentTreeItem,
+ StoreType extends UmbContentStore = UmbContentStore
> {
protected _host: UmbControllerHostInterface;
@@ -104,7 +102,7 @@ export abstract class UmbWorkspaceContentContext<
// TODO: consider turning this into an abstract so each context implement this them selfs.
public save(): Promise {
if (!this._store) {
- // TODO: more beautiful error:
+ // TODO: add a more beautiful error:
console.error('Could not save cause workspace context has no store.');
return Promise.resolve();
}
@@ -120,7 +118,7 @@ export abstract class UmbWorkspaceContentContext<
});
}
- // TODO: how can we make sure to call this.
+ // TODO: how can we make sure to call this, we might need to turn this thing into a ContextProvider(extending) for it to call destroy?
public destroy(): void {
this._data.unsubscribe();
}
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/copy/property-action-copy.element.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/copy/property-action-copy.element.ts
index 4c0901e9bd..6e9a1db8c1 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/copy/property-action-copy.element.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/copy/property-action-copy.element.ts
@@ -1,8 +1,11 @@
import { html } from 'lit';
import { customElement, property } from 'lit/decorators.js';
-import type { UmbNotificationDefaultData } from '../../../../core/notification/layouts/default';
-import { UmbNotificationService, UMB_NOTIFICATION_SERVICE_CONTEXT_TOKEN } from '../../../../core/notification';
import type { UmbPropertyAction } from '../shared/property-action/property-action.model';
+import {
+ UmbNotificationDefaultData,
+ UmbNotificationService,
+ UMB_NOTIFICATION_SERVICE_CONTEXT_TOKEN,
+} from '@umbraco-cms/notification';
import { UmbLitElement } from '@umbraco-cms/element';
@customElement('umb-property-action-copy')
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/shared/property-action-menu/property-action-menu.context.ts b/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/shared/property-action-menu/property-action-menu.context.ts
index ca6fe35afc..da7137c8e4 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/shared/property-action-menu/property-action-menu.context.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/shared/property-actions/shared/property-action-menu/property-action-menu.context.ts
@@ -1,9 +1,8 @@
-import { UmbContextProviderController } from 'src/core/context-api/provide/context-provider.controller';
+import { UmbContextProviderController } from '@umbraco-cms/context-api';
import type { UmbControllerHostInterface } from '@umbraco-cms/controller';
import { UniqueBehaviorSubject } from '@umbraco-cms/observable-api';
export class UmbPropertyActionMenuContext {
-
#isOpen = new UniqueBehaviorSubject(false);
public readonly isOpen = this.#isOpen.asObservable();
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.detail.store.ts b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.detail.store.ts
new file mode 100644
index 0000000000..598a2f16d1
--- /dev/null
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.detail.store.ts
@@ -0,0 +1,100 @@
+import type { DictionaryDetails } from '@umbraco-cms/models';
+import { UmbContextToken } from '@umbraco-cms/context-api';
+import { createObservablePart, UniqueArrayBehaviorSubject } from '@umbraco-cms/observable-api';
+import { UmbStoreBase } from '@umbraco-cms/store';
+import { UmbControllerHostInterface } from '@umbraco-cms/controller';
+import { EntityTreeItem } from '@umbraco-cms/backend-api';
+
+
+export const UMB_DICTIONARY_DETAIL_STORE_CONTEXT_TOKEN = new UmbContextToken('UmbDictionaryDetailStore');
+
+
+/**
+ * @export
+ * @class UmbDictionaryDetailStore
+ * @extends {UmbStoreBase}
+ * @description - Details Data Store for Data Types
+ */
+export class UmbDictionaryDetailStore extends UmbStoreBase {
+
+
+ // TODO: use the right type:
+ #data = new UniqueArrayBehaviorSubject([], (x) => x.key);
+
+
+ constructor(host: UmbControllerHostInterface) {
+ super(host, UMB_DICTIONARY_DETAIL_STORE_CONTEXT_TOKEN.toString());
+ }
+
+ /**
+ * @description - Request a Data Type by key. The Data Type is added to the store and is returned as an Observable.
+ * @param {string} key
+ * @return {*} {(Observable)}
+ * @memberof UmbDictionaryDetailStore
+ */
+ getByKey(key: string) {
+ // TODO: use backend cli when available.
+ fetch(`/umbraco/management/api/v1/document/dictionary/${key}`)
+ .then((res) => res.json())
+ .then((data) => {
+ this.#data.append(data);
+ });
+
+ return createObservablePart(this.#data, (documents) =>
+ documents.find((document) => document.key === key)
+ );
+ }
+
+ // TODO: make sure UI somehow can follow the status of this action.
+ /**
+ * @description - Save a Dictionary.
+ * @param {Array} Dictionaries
+ * @memberof UmbDictionaryDetailStore
+ * @return {*} {Promise}
+ */
+ save(data: DictionaryDetails[]) {
+ // fetch from server and update store
+ // TODO: use Fetcher API.
+ let body: string;
+
+ try {
+ body = JSON.stringify(data);
+ } catch (error) {
+ console.error(error);
+ return Promise.reject();
+ }
+
+ // TODO: use backend cli when available.
+ return fetch('/umbraco/management/api/v1/dictionary/save', {
+ method: 'POST',
+ body: body,
+ headers: {
+ 'Content-Type': 'application/json',
+ },
+ })
+ .then((res) => res.json())
+ .then((data: Array) => {
+ this.#data.append(data);
+ });
+ }
+
+ // TODO: How can we avoid having this in both stores?
+ /**
+ * @description - Delete a Data Type.
+ * @param {string[]} keys
+ * @memberof UmbDictionaryDetailStore
+ * @return {*} {Promise}
+ */
+ async delete(keys: string[]) {
+ // TODO: use backend cli when available.
+ await fetch('/umbraco/backoffice/dictionary/delete', {
+ method: 'POST',
+ body: JSON.stringify(keys),
+ headers: {
+ 'Content-Type': 'application/json',
+ },
+ });
+
+ this.#data.remove(keys);
+ }
+}
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.store.ts b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.store.ts
deleted file mode 100644
index 0fcf2c3fe5..0000000000
--- a/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.store.ts
+++ /dev/null
@@ -1,55 +0,0 @@
-import { map, Observable } from 'rxjs';
-import { UmbDataStoreBase } from '../../../core/stores/store';
-import { DictionaryResource, EntityTreeItem } from '@umbraco-cms/backend-api';
-import { tryExecuteAndNotify } from '@umbraco-cms/resources';
-import { UmbContextToken } from '@umbraco-cms/context-api';
-
-export const STORE_ALIAS = 'UmbDictionaryStore';
-
-/**
- * @export
- * @class UmbDictionaryStore
- * @extends {UmbDataStoreBase}
- * @description - Data Store for Dictionary Items.
- */
-export class UmbDictionaryStore extends UmbDataStoreBase {
- public readonly storeAlias = STORE_ALIAS;
-
- /**
- * @description - Get the root of the tree.
- * @return {*} {Observable>}
- * @memberof UmbDictionaryStore
- */
- getTreeRoot(): Observable> {
- tryExecuteAndNotify(this.host, DictionaryResource.getTreeDictionaryRoot({})).then(({ data }) => {
- if (data) {
- this.updateItems(data.items);
- }
- });
-
- return this.items.pipe(map((items) => items.filter((item) => item.parentKey === null)));
- }
-
- /**
- * @description - Get the children of a tree item.
- * @param {string} key
- * @return {*} {Observable>}
- * @memberof UmbDataTypesStore
- */
- getTreeItemChildren(key: string): Observable> {
- tryExecuteAndNotify(
- this.host,
- DictionaryResource.getTreeDictionaryChildren({
- parentKey: key,
- })
- ).then(({ data }) => {
- if (data) {
- this.updateItems(data.items);
- }
- });
-
- return this.items.pipe(map((items) => items.filter((item) => item.parentKey === key)));
- }
-}
-
-export const UMB_DICTIONARY_STORE_CONTEXT_TOKEN = new UmbContextToken(STORE_ALIAS);
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.tree.store.ts b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.tree.store.ts
new file mode 100644
index 0000000000..f7f8687833
--- /dev/null
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/dictionary.tree.store.ts
@@ -0,0 +1,96 @@
+import { DictionaryResource, DocumentTreeItem } from '@umbraco-cms/backend-api';
+import { tryExecuteAndNotify } from '@umbraco-cms/resources';
+import { UmbContextToken } from '@umbraco-cms/context-api';
+import { createObservablePart, UniqueArrayBehaviorSubject } from '@umbraco-cms/observable-api';
+import { UmbStoreBase } from '@umbraco-cms/store';
+import { UmbControllerHostInterface } from '@umbraco-cms/controller';
+
+
+export const UMB_DICTIONARY_TREE_STORE_CONTEXT_TOKEN = new UmbContextToken('UmbDictionaryTreeStore');
+
+
+/**
+ * @export
+ * @class UmbDictionaryTreeStore
+ * @extends {UmbStoreBase}
+ * @description - Tree Data Store for Data Types
+ */
+export class UmbDictionaryTreeStore extends UmbStoreBase {
+
+
+ #data = new UniqueArrayBehaviorSubject([], (x) => x.key);
+
+
+ constructor(host: UmbControllerHostInterface) {
+ super(host, UMB_DICTIONARY_TREE_STORE_CONTEXT_TOKEN.toString());
+ }
+
+ // TODO: How can we avoid having this in both stores?
+ /**
+ * @description - Delete a Data Type.
+ * @param {string[]} keys
+ * @memberof UmbDictionarysStore
+ * @return {*} {Promise}
+ */
+ async delete(keys: string[]) {
+ // TODO: use backend cli when available.
+ await fetch('/umbraco/backoffice/data-type/delete', {
+ method: 'POST',
+ body: JSON.stringify(keys),
+ headers: {
+ 'Content-Type': 'application/json',
+ },
+ });
+
+ this.#data.remove(keys);
+ }
+
+ getTreeRoot() {
+ tryExecuteAndNotify(this._host, DictionaryResource.getTreeDictionaryRoot({})).then(({ data }) => {
+ if (data) {
+ // TODO: how do we handle if an item has been removed during this session(like in another tab or by another user)?
+ this.#data.append(data.items);
+ }
+ });
+
+ // TODO: how do we handle trashed items?
+ // TODO: remove ignore when we know how to handle trashed items.
+ return createObservablePart(this.#data, (items) => items.filter((item) => item.parentKey === null && !item.isTrashed));
+ }
+
+ getTreeItemChildren(key: string) {
+ tryExecuteAndNotify(
+ this._host,
+ DictionaryResource.getTreeDictionaryChildren({
+ parentKey: key,
+ })
+ ).then(({ data }) => {
+ if (data) {
+ // TODO: how do we handle if an item has been removed during this session(like in another tab or by another user)?
+ this.#data.append(data.items);
+ }
+ });
+
+ // TODO: how do we handle trashed items?
+ // TODO: remove ignore when we know how to handle trashed items.
+ return createObservablePart(this.#data, (items) => items.filter((item) => item.parentKey === key && !item.isTrashed));
+ }
+
+ getTreeItems(keys: Array) {
+ if (keys?.length > 0) {
+ tryExecuteAndNotify(
+ this._host,
+ DictionaryResource.getTreeDictionaryItem({
+ key: keys,
+ })
+ ).then(({ data }) => {
+ if (data) {
+ // TODO: how do we handle if an item has been removed during this session(like in another tab or by another user)?
+ this.#data.append(data);
+ }
+ });
+ }
+
+ return createObservablePart(this.#data, (items) => items.filter((item) => keys.includes(item.key ?? '')));
+ }
+}
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/tree/manifests.ts b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/tree/manifests.ts
index f399178b43..8ba7f7d41e 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/tree/manifests.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/translation/dictionary/tree/manifests.ts
@@ -1,4 +1,4 @@
-import { STORE_ALIAS } from '../dictionary.store';
+import { UMB_DICTIONARY_TREE_STORE_CONTEXT_TOKEN } from '../dictionary.tree.store';
import type { ManifestTree, ManifestTreeItemAction } from '@umbraco-cms/models';
const treeAlias = 'Umb.Tree.Dictionary';
@@ -8,7 +8,7 @@ const tree: ManifestTree = {
alias: treeAlias,
name: 'Dictionary Tree',
meta: {
- storeAlias: STORE_ALIAS,
+ storeAlias: UMB_DICTIONARY_TREE_STORE_CONTEXT_TOKEN.toString(),
},
};
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/users/current-user/current-user-history.store.ts b/src/Umbraco.Web.UI.Client/src/backoffice/users/current-user/current-user-history.store.ts
index 1a512f18c6..6044e059f1 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/users/current-user/current-user-history.store.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/users/current-user/current-user-history.store.ts
@@ -1,6 +1,5 @@
import { UmbContextToken } from '@umbraco-cms/context-api';
-import { UniqueBehaviorSubject } from '@umbraco-cms/observable-api';
-import { createObservablePart } from '@umbraco-cms/observable-api';
+import { createObservablePart, UniqueBehaviorSubject } from '@umbraco-cms/observable-api';
export type UmbModelType = 'dialog' | 'sidebar';
diff --git a/src/Umbraco.Web.UI.Client/src/backoffice/users/user-groups/user-group.store.ts b/src/Umbraco.Web.UI.Client/src/backoffice/users/user-groups/user-group.store.ts
index ebf7d6af87..6c2e68b807 100644
--- a/src/Umbraco.Web.UI.Client/src/backoffice/users/user-groups/user-group.store.ts
+++ b/src/Umbraco.Web.UI.Client/src/backoffice/users/user-groups/user-group.store.ts
@@ -1,67 +1,67 @@
-import { map, Observable } from 'rxjs';
-import { UmbDataStoreBase } from '../../../core/stores/store';
-import type { UserGroupDetails, UserGroupEntity } from '@umbraco-cms/models';
+import type { UserGroupDetails } from '@umbraco-cms/models';
import { UmbContextToken } from '@umbraco-cms/context-api';
+import { UmbControllerHostInterface } from '@umbraco-cms/controller';
+import { createObservablePart, UniqueArrayBehaviorSubject } from '@umbraco-cms/observable-api';
+import { UmbStoreBase } from '@umbraco-cms/store';
// TODO: get rid of this type addition & { ... }:
export type UmbUserGroupStoreItemType = UserGroupDetails & { users?: Array };
-export const STORE_ALIAS = 'UmbUserGroupStore';
+export const UMB_USER_GROUP_STORE_CONTEXT_TOKEN = new UmbContextToken('UmbUserGroupStore');
/**
* @export
* @class UmbUserGroupStore
- * @extends {UmbDataStoreBase