Files @ 6121ce79cc88
Branch filter:

Location: symposion_app/pinaxcon/widgets.py

Nick Seidenman (N6)
Getting the splash homepage to work via CMS.

Nearly there. Much rubbish / cruft ripped out of site_base.html and content_page.html.
Had to modify cms_pages/models.py to accommodate a "simple" layout option in the homepage
editor.
Still some stuff to do. Styling not quite there yet, but want to checkpoint this.
from django import forms

class AceMarkdownEditor(forms.Textarea):

    def render(self, name, value, attrs):
        original = super(AceMarkdownEditor, self).render(name, value, attrs)
        ret = '''
                %s
                <script>
                    window.addEventListener("load", () => {
                        editor = loadEditor("%s");
                    }, 0);
                </script>
        ''' % (original, attrs["id"])

        return ret