Subversion-Projekte lars-tiefland.cienc

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
9 lars 1
var ComponentsEditors = function () {
2
 
3
    var handleWysihtml5 = function () {
4
        if (!jQuery().wysihtml5) {
5
            return;
6
        }
7
 
8
        if ($('.wysihtml5').size() > 0) {
9
            $('.wysihtml5').wysihtml5({
10
                "stylesheets": ["../assets/global/plugins/bootstrap-wysihtml5/wysiwyg-color.css"]
11
            });
12
        }
13
    }
14
 
15
    var handleSummernote = function () {
16
        $('#summernote_1').summernote({height: 300});
17
        //API:
18
        //var sHTML = $('#summernote_1').code(); // get code
19
        //$('#summernote_1').destroy(); // destroy
20
    }
21
 
22
    return {
23
        //main function to initiate the module
24
        init: function () {
25
            handleWysihtml5();
26
            handleSummernote();
27
        }
28
    };
29
 
30
}();
31
 
32
jQuery(document).ready(function() {
33
   ComponentsEditors.init();
34
});