From ed4700869dcb070d505129aed81a70de82275d05 Mon Sep 17 00:00:00 2001 From: bluepilledgreat <97983689+bluepilledgreat@users.noreply.github.com> Date: Sun, 20 Oct 2024 22:24:23 +0100 Subject: [PATCH] stop adding an extra end character --- Bloxstrap/UI/Elements/Editor/BootstrapperEditorWindow.xaml.cs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Bloxstrap/UI/Elements/Editor/BootstrapperEditorWindow.xaml.cs b/Bloxstrap/UI/Elements/Editor/BootstrapperEditorWindow.xaml.cs index e96a397..573b41a 100644 --- a/Bloxstrap/UI/Elements/Editor/BootstrapperEditorWindow.xaml.cs +++ b/Bloxstrap/UI/Elements/Editor/BootstrapperEditorWindow.xaml.cs @@ -285,6 +285,9 @@ namespace Bloxstrap.UI.Elements.Editor } else { + if (UIXML.Text.Length > UIXML.CaretOffset && UIXML.Text[UIXML.CaretOffset] == '>') + return; + var elementName = ShowAttributesForElementName(); // re-using functions :) if (elementName != null) UIXML.TextArea.Document.Insert(UIXML.CaretOffset, ">");