From 321fe2954e3d7014b717e3babf2d1bff50eebab5 Mon Sep 17 00:00:00 2001 From: vnetonline Date: Sat, 29 Nov 2025 15:10:58 +1100 Subject: [PATCH] Added Style Paramater to RichTextEditor to remove the `margin-bottom: 50px;` if the developer wishes --- Oqtane.Client/Modules/Controls/RichTextEditor.razor | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Oqtane.Client/Modules/Controls/RichTextEditor.razor b/Oqtane.Client/Modules/Controls/RichTextEditor.razor index 6933783a..e4e98fba 100644 --- a/Oqtane.Client/Modules/Controls/RichTextEditor.razor +++ b/Oqtane.Client/Modules/Controls/RichTextEditor.razor @@ -7,7 +7,7 @@ @inject ISettingService SettingService @inject IStringLocalizer Localizer -
+
@_textEditorComponent
@@ -18,6 +18,8 @@ private RenderFragment _textEditorComponent; private ITextEditor _textEditor; + private string _style = "margin-bottom: 50px;"; + [Parameter] public string Content { get; set; } @@ -30,6 +32,9 @@ [Parameter] public string Provider { get; set; } + [Parameter] + public string Style { get; set; } // optional + [Parameter(CaptureUnmatchedValues = true)] public Dictionary AdditionalAttributes { get; set; } = new Dictionary(); @@ -40,6 +45,12 @@ protected override void OnParametersSet() { + + if (!string.IsNullOrEmpty(Style)) + { + _style = Style; + } + _textEditorComponent = (builder) => { CreateTextEditor(builder);