Skip to content

Commit

Permalink
fix: expandable textarea
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasvinclav committed Nov 16, 2022
1 parent b1b3efc commit 432a741
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/unfold/templates/unfold/widgets/textarea.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<div class="relative">
<div class="border break-words font-medium invisible max-w-4xl px-3 py-2 text-sm" style="min-height: 64px">
{% if widget.value %}{{ widget.value }}{% endif %}
{% if widget.value %}{{ widget.value|linebreaks }}{% endif %}
</div>

<textarea onInput="this.previousElementSibling.innerText = this.value + String.fromCharCode(10)" name="{{ widget.name }}"{% include "django/forms/widgets/attrs.html" %}>{% if widget.value %}{{ widget.value }}{% endif %}</textarea>
Expand Down

0 comments on commit 432a741

Please sign in to comment.