Closed willdayble closed 4 years ago
Or alternatively, separate for attr for options?
Alright, @willdayble, fresh template macro.
wysiwyg(input_name, content, toolbar_styles)
Everything but input_name
is optional. You'll get the full toolbar if you leave out toolbar styles.
You have to wrap things in an empty form in course edit though until we can untangle all the gnarly autosave code (#194).
<form>
{{ wysiwyg('course_summary', course.summary_html, ['bold', 'italic']) }}
</form>
Looking at http://fitz-dev.com:5000/course/fitzroy-academy/lessons/2/edit
See
_lesson.html
, it seems to have ugly<script>
tags down the bottom of the file doing the wysiwyg stuff, should this all be in fit.js and whatnot?This is probably a reason to check out how we're doing them all.
Maybe we need some standards:
data-fit-wysiwyg-full
= full wysiwyg text-editor with headers, links, quotes, image upload etcdata-fit-wysiwyg-lite
= Only bold/italic + links (no headers, quotes, etc)data-fit-wysiwyg-min
= only carriage returnsI think that's it? We should probably chat this through I'm guessing lol.