From 2554b7807b7ca437c32abf588157b791b263c2b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20Lyngs=C3=B8?= Date: Mon, 4 May 2026 10:53:58 +0200 Subject: [PATCH] cherry picked fix from #22422 --- .../documents/workspace/document-workspace.context.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/document-workspace.context.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/document-workspace.context.ts index 9f57bdf80f14..a66769a42b64 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/document-workspace.context.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/documents/workspace/document-workspace.context.ts @@ -241,11 +241,17 @@ export class UmbDocumentWorkspaceContext async create(parent: UmbEntityModel, documentTypeUnique: string, blueprintUnique?: string) { if (blueprintUnique) { + this.resetState(); + this.loading.addState({ unique: 'blueprint-fetch' }); const blueprintRepository = new UmbDocumentBlueprintDetailRepository(this); const { data } = await blueprintRepository.scaffoldByUnique(blueprintUnique); - if (!data) throw new Error('Blueprint data is missing'); + if (!data) { + this.loading.removeState('blueprint-fetch'); + throw new Error('Blueprint data is missing'); + } + this.loading.removeState('blueprint-fetch'); return this.createScaffold({ parent, preset: {