Add shared editor partials (_EditableText, _EditItemControls)

This commit is contained in:
Francesco Lorenzo D'Amico
2026-09-11 13:39:32 +02:00
parent 6dd0ecaceb
commit c72da7f501
2 changed files with 11 additions and 0 deletions
@@ -0,0 +1,6 @@
@* Schaltflaechen zum Verschieben und Loeschen eines Listeneintrags. Nur im Edit-Modus gerendert. *@
<span class="pe-item-controls">
<button type="button" class="pe-move-up" title="Nach oben">&#9650;</button>
<button type="button" class="pe-move-down" title="Nach unten">&#9660;</button>
<button type="button" class="pe-delete" title="Eintrag löschen">&#10005;</button>
</span>
@@ -0,0 +1,5 @@
@model EditableText
@if (Model.EditMode)
{<span data-field="@Model.Field" @(Model.Max.HasValue ? Html.Raw($"data-max=\"{Model.Max}\"") : Html.Raw("")) contenteditable="true">@Model.Text</span>}
else
{@Model.Text}