rename getType to getEntityType

This commit is contained in:
Niels Lyngsø
2023-12-12 14:14:48 +01:00
parent 9b67dd7f3c
commit 500e6104a1
5 changed files with 5 additions and 5 deletions

View File

@@ -26,7 +26,7 @@ export class UmbPropertyDatasetBaseContext
private _entityType!: string;
private _unique!: string;
getType() {
getEntityType() {
return this._entityType;
}
getUnique() {

View File

@@ -16,7 +16,7 @@ import type { Observable } from '@umbraco-cms/backoffice/external/rxjs';
* Also setting the name is an additional feature.
*/
export interface UmbPropertyDatasetContext {
getType(): string;
getEntityType(): string;
getUnique(): string | undefined;
getVariantId: () => UmbVariantId;

View File

@@ -26,7 +26,7 @@ export class UmbInvariantWorkspacePropertyDatasetContext<
getVariantId() {
return UmbVariantId.CreateInvariant();
}
getType() {
getEntityType() {
return this.#workspace.getEntityType();
}
getUnique() {

View File

@@ -5,7 +5,7 @@ import { UmbContextToken } from '@umbraco-cms/backoffice/context-api';
export const IsDocumentVariantContext = (
context: UmbPropertyDatasetContext,
): context is UmbDocumentPropertyDataContext => context.getType() === UMB_DOCUMENT_ENTITY_TYPE;
): context is UmbDocumentPropertyDataContext => context.getEntityType() === UMB_DOCUMENT_ENTITY_TYPE;
export const UMB_DOCUMENT_VARIANT_CONTEXT = new UmbContextToken<
UmbPropertyDatasetContext,

View File

@@ -34,7 +34,7 @@ export class UmbDocumentPropertyDataContext
// This will actually make it simpler if multiple are watching the same property.
// But it will also mean that we wil watch all properties and their structure, for variantID, all the time for all of the properties.
getType(): string {
getEntityType(): string {
return this.#workspace.getEntityType();
}
getUnique(): string | undefined {