From 2ee243ec87076b10032d518b10412415c7b6d738 Mon Sep 17 00:00:00 2001 From: Hopiu Date: Tue, 11 Apr 2017 21:59:32 +0200 Subject: [PATCH] Update widgets.py How about adding those extra variables to the widgets context? This would give some extra flexibility in rendering the template. For example bootstrap tabs: ```
{{ markdownx_editor }}
``` --- markdownx/widgets.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/markdownx/widgets.py b/markdownx/widgets.py index b5691a7..82dc126 100755 --- a/markdownx/widgets.py +++ b/markdownx/widgets.py @@ -71,6 +71,9 @@ class MarkdownxWidget(forms.Textarea): return template.render({ 'markdownx_editor': widget, + 'name': name, + 'value': value, + 'attrs': attrs, }) @staticmethod