├── .bowerrc ├── .gitignore ├── test ├── karma │ ├── testframework_test.js │ └── test-main.js ├── dom │ ├── set_attributes_test.js │ ├── unwrap_test.js │ ├── contains_test.js │ ├── set_styles_test.js │ ├── has_element_with_tag_name_test.js │ ├── rename_element_test.js │ ├── compare_document_position_test.js │ ├── has_element_with_class_name_test.js │ ├── insert_css_test.js │ ├── get_style_test.js │ ├── copy_attributes_test.js │ ├── get_as_dom_test.js │ ├── delegate_test.js │ ├── resolve_list_test.js │ ├── get_next_previous_element.js │ ├── observe_test.js │ ├── dom_node_test.js │ └── convert_to_list_test.js ├── lang │ ├── string_test.js │ ├── array_test.js │ └── object_test.js ├── bs │ ├── bootstrap_editor_changeView_test.js │ ├── bootstrap_editor_commands_test.js │ ├── bootstrap_editor_link_test.js │ └── bootstrap_editor_image_test.js ├── incompatible_test.js ├── testhelper.js ├── undo_manager_test.js └── index.html ├── generator ├── generate_simple.html ├── generate_advanced.html ├── generate.html ├── generate_advanced_unwrap.html └── print_parser_rules.js ├── dist ├── commands.js ├── parser_rules │ └── simple.json ├── amd │ └── commands.js ├── locales │ ├── bootstrap-wysihtml5.ja-JP.js │ ├── bootstrap-wysihtml5.ko-KR.js │ ├── bootstrap-wysihtml5.tr-TR.js │ ├── bootstrap-wysihtml5.en-US.js │ ├── bootstrap-wysihtml5.fr-FR.js │ ├── bootstrap-wysihtml5.hu-HU.js │ ├── bootstrap-wysihtml5.mo-MD.js │ ├── bootstrap-wysihtml5.zh-CN.js │ ├── bootstrap-wysihtml5.zh-TW.js │ ├── bootstrap-wysihtml5.de-DE.js │ ├── bootstrap-wysihtml5.it-IT.js │ ├── bootstrap-wysihtml5.sv-SE.js │ ├── bootstrap-wysihtml5.nb-NB.js │ ├── bootstrap-wysihtml5.el-GR.js │ ├── bootstrap-wysihtml5.nl-NL.js │ ├── bootstrap-wysihtml5.sk-SK.js │ ├── bootstrap-wysihtml5.da-DK.js │ ├── bootstrap-wysihtml5.hr-HR.js │ ├── bootstrap-wysihtml5.ua-UA.js │ ├── bootstrap-wysihtml5.lt-LT.js │ ├── bootstrap-wysihtml5.ar-AR.js │ ├── bootstrap-wysihtml5.il-HE.js │ ├── bootstrap-wysihtml5.ca-CT.js │ ├── bootstrap-wysihtml5.bg-BG.js │ ├── bootstrap-wysihtml5.cs-CZ.js │ ├── bootstrap-wysihtml5.pt-BR.js │ ├── bootstrap-wysihtml5.ru-RU.js │ ├── bootstrap-wysihtml5.es-AR.js │ ├── bootstrap-wysihtml5.es-ES.js │ └── bootstrap-wysihtml5.pl-PL.js ├── bootstrap3-wysihtml5.min.css └── bootstrap3-wysihtml5.css ├── src ├── commands │ └── small.js ├── generated │ └── commands.js ├── parser_rules │ └── simple.json ├── templates │ ├── html.hbs │ ├── blockquote.hbs │ ├── emphasis.hbs │ ├── image.hbs │ ├── font-styles.hbs │ ├── lists.hbs │ ├── link.hbs │ └── color.hbs ├── locales │ ├── bootstrap-wysihtml5.vi-VN.js │ ├── bootstrap-wysihtml5.ko-KR.js │ ├── bootstrap-wysihtml5.ja-JP.js │ ├── bootstrap-wysihtml5.en-US.js │ ├── bootstrap-wysihtml5.fr-FR.js │ ├── bootstrap-wysihtml5.hu-HU.js │ ├── bootstrap-wysihtml5.mo-MD.js │ ├── bootstrap-wysihtml5.zh-CN.js │ ├── bootstrap-wysihtml5.eo-EO.js │ ├── bootstrap-wysihtml5.zh-TW.js │ ├── bootstrap-wysihtml5.de-DE.js │ ├── bootstrap-wysihtml5.sv-SE.js │ ├── bootstrap-wysihtml5.nb-NB.js │ ├── bootstrap-wysihtml5.nl-NL.js │ ├── bootstrap-wysihtml5.sk-SK.js │ ├── bootstrap-wysihtml5.it-IT.js │ ├── bootstrap-wysihtml5.ua-UA.js │ ├── bootstrap-wysihtml5.el-GR.js │ ├── bootstrap-wysihtml5.da-DK.js │ ├── bootstrap-wysihtml5.hr-HR.js │ ├── bootstrap-wysihtml5.lt-LT.js │ ├── bootstrap-wysihtml5.tr-TR.js │ ├── bootstrap-wysihtml5.ar-AR.js │ ├── bootstrap-wysihtml5.il-HE.js │ ├── bootstrap-wysihtml5.pt-BR.js │ ├── bootstrap-wysihtml5.ca-CT.js │ ├── bootstrap-wysihtml5.cs-CZ.js │ ├── bootstrap-wysihtml5.bg-BG.js │ ├── bootstrap-wysihtml5.ru-RU.js │ ├── bootstrap-wysihtml5.es-AR.js │ ├── bootstrap-wysihtml5.es-ES.js │ └── bootstrap-wysihtml5.pl-PL.js └── bootstrap3-wysihtml5.css ├── examples ├── start.js ├── main.js ├── main-dev.js ├── start-dev.js ├── index-require-dev.html └── index-require.html ├── bower.json ├── LICENCE ├── package.json ├── index-all.html ├── index.html ├── karma.conf.js └── index-dev.html /.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "components" 3 | } 4 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | components 4 | coverage 5 | -------------------------------------------------------------------------------- /test/karma/testframework_test.js: -------------------------------------------------------------------------------- 1 | module('bootstrap3-wysihtml5-bower.testframework', { 2 | 3 | }); 4 | test("if test runner framework is working", function(){ 5 | ok(true, "hope it works"); 6 | }); 7 | -------------------------------------------------------------------------------- /generator/generate_simple.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /generator/generate_advanced.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /generator/generate.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /generator/generate_advanced_unwrap.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /dist/commands.js: -------------------------------------------------------------------------------- 1 | (function(wysihtml5) { 2 | wysihtml5.commands.small = { 3 | exec: function(composer, command) { 4 | return wysihtml5.commands.formatInline.exec(composer, command, "small"); 5 | }, 6 | 7 | state: function(composer, command) { 8 | return wysihtml5.commands.formatInline.state(composer, command, "small"); 9 | } 10 | }; 11 | })(wysihtml5); 12 | 13 | -------------------------------------------------------------------------------- /src/commands/small.js: -------------------------------------------------------------------------------- 1 | (function(wysihtml5) { 2 | wysihtml5.commands.small = { 3 | exec: function(composer, command) { 4 | return wysihtml5.commands.formatInline.exec(composer, command, "small"); 5 | }, 6 | 7 | state: function(composer, command) { 8 | return wysihtml5.commands.formatInline.state(composer, command, "small"); 9 | } 10 | }; 11 | })(wysihtml5); 12 | 13 | -------------------------------------------------------------------------------- /src/generated/commands.js: -------------------------------------------------------------------------------- 1 | (function(wysihtml5) { 2 | wysihtml5.commands.small = { 3 | exec: function(composer, command) { 4 | return wysihtml5.commands.formatInline.exec(composer, command, "small"); 5 | }, 6 | 7 | state: function(composer, command) { 8 | return wysihtml5.commands.formatInline.state(composer, command, "small"); 9 | } 10 | }; 11 | })(wysihtml5); 12 | 13 | -------------------------------------------------------------------------------- /src/parser_rules/simple.json: -------------------------------------------------------------------------------- 1 | { 2 | "tags": { 3 | "a": { 4 | "check_attributes": { 5 | "href": "url" 6 | }, 7 | "set_attributes": { 8 | "rel": "nofollow", 9 | "target": "_blank" 10 | } 11 | }, 12 | "b": {}, 13 | "br": {}, 14 | "div": {}, 15 | "em": {}, 16 | "i": {}, 17 | "li": {}, 18 | "ol": {}, 19 | "p": {}, 20 | "span": {}, 21 | "strong": {}, 22 | "ul": {} 23 | } 24 | } -------------------------------------------------------------------------------- /test/dom/set_attributes_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.dom.setAttributes", { 2 | setup: function() { 3 | this.element = document.createElement("div"); 4 | } 5 | }); 6 | 7 | test("Basic test", function() { 8 | wysihtml5.dom.setAttributes({ 9 | id: "foo", 10 | "class": "bar" 11 | }).on(this.element); 12 | 13 | equal(this.element.id, "foo"); 14 | equal(this.element.className, "bar"); 15 | }); -------------------------------------------------------------------------------- /dist/parser_rules/simple.json: -------------------------------------------------------------------------------- 1 | { 2 | "tags": { 3 | "a": { 4 | "check_attributes": { 5 | "href": "url" 6 | }, 7 | "set_attributes": { 8 | "rel": "nofollow", 9 | "target": "_blank" 10 | } 11 | }, 12 | "b": {}, 13 | "br": {}, 14 | "div": {}, 15 | "em": {}, 16 | "i": {}, 17 | "li": {}, 18 | "ol": {}, 19 | "p": {}, 20 | "span": {}, 21 | "strong": {}, 22 | "ul": {} 23 | } 24 | } -------------------------------------------------------------------------------- /test/karma/test-main.js: -------------------------------------------------------------------------------- 1 | var allTestFiles = []; 2 | var TEST_REGEXP = /(spec|test)\.js$/i; 3 | 4 | var pathToModule = function(path) { 5 | return path.replace(/^\/base\//, '').replace(/\.js$/, ''); 6 | }; 7 | 8 | Object.keys(window.__karma__.files).forEach(function(file) { 9 | if (TEST_REGEXP.test(file)) { 10 | // Normalize paths to RequireJS module names. 11 | allTestFiles.push(pathToModule(file)); 12 | } 13 | }); 14 | 15 | -------------------------------------------------------------------------------- /src/templates/html.hbs: -------------------------------------------------------------------------------- 1 |tes2
"; 4 | this.container = document.createElement("div"); 5 | this.containerInner = document.createElement("div"); 6 | this.containerInner.innerHTML = this.inner; 7 | this.container.appendChild(this.containerInner); 8 | } 9 | }); 10 | 11 | test("Basic test", function() { 12 | wysihtml5.dom.unwrap(this.containerInner); 13 | equal(this.container.innerHTML, this.inner, "Unwrapping element works splendid."); 14 | }); 15 | -------------------------------------------------------------------------------- /test/dom/contains_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.dom.contains", { 2 | setup: function() { 3 | this.container = document.createElement("div"); 4 | document.body.appendChild(this.container); 5 | }, 6 | 7 | teardown: function() { 8 | this.container.parentNode.removeChild(this.container); 9 | } 10 | }); 11 | 12 | 13 | test("Basic test", function() { 14 | ok(wysihtml5.dom.contains(document.documentElement, document.body)); 15 | ok(wysihtml5.dom.contains(document.body, this.container)); 16 | ok(!wysihtml5.dom.contains(this.container, document.body)); 17 | ok(!wysihtml5.dom.contains(document.body, document.body)); 18 | }); -------------------------------------------------------------------------------- /test/dom/set_styles_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.dom.setStyles", { 2 | setup: function() { 3 | this.element = document.createElement("div"); 4 | document.body.appendChild(this.element); 5 | }, 6 | 7 | teardown: function() { 8 | this.element.parentNode.removeChild(this.element); 9 | } 10 | }); 11 | 12 | test("Basic test", function() { 13 | wysihtml5.dom.setStyles("text-align: right; float: left").on(this.element); 14 | equal(wysihtml5.dom.getStyle("text-align").from(this.element), "right"); 15 | equal(wysihtml5.dom.getStyle("float").from(this.element), "left"); 16 | 17 | wysihtml5.dom.setStyles({ "float": "right" }).on(this.element); 18 | equal(wysihtml5.dom.getStyle("float").from(this.element), "right"); 19 | }); -------------------------------------------------------------------------------- /test/lang/string_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.lang.string"); 2 | 3 | test("trim()", function() { 4 | equal(wysihtml5.lang.string(" foo \n").trim(), "foo"); 5 | }); 6 | 7 | test("interpolate()", function() { 8 | equal( 9 | wysihtml5.lang.string("Hello #{name}, I LOVE YOUR NAME. IT'S VERY GERMAN AND SOUNDS STRONG.").interpolate({ name: "Reinhold" }), 10 | "Hello Reinhold, I LOVE YOUR NAME. IT'S VERY GERMAN AND SOUNDS STRONG." 11 | ); 12 | }); 13 | 14 | test("replace()", function() { 15 | equal( 16 | wysihtml5.lang.string("I LOVE CAKE").replace("CAKE").by("BOOBS"), 17 | "I LOVE BOOBS" 18 | ); 19 | }); 20 | 21 | test("escapeHTML()", function() { 22 | equal(wysihtml5.lang.string('&<>"').escapeHTML(), "&<>""); 23 | }); -------------------------------------------------------------------------------- /test/lang/array_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.lang.array"); 2 | 3 | test("contains()", function() { 4 | var arr = [1, "2", "foo"]; 5 | ok(wysihtml5.lang.array(arr).contains(1)); 6 | ok(!wysihtml5.lang.array(arr).contains(2)); 7 | ok(wysihtml5.lang.array(arr).contains("2")); 8 | ok(wysihtml5.lang.array(arr).contains("foo")); 9 | }); 10 | 11 | test("without()", function() { 12 | var arr = [1, 2, 3]; 13 | deepEqual(wysihtml5.lang.array(arr).without([1]), [2, 3]); 14 | deepEqual(wysihtml5.lang.array(arr).without([4]), [1, 2, 3]); 15 | }); 16 | 17 | test("get()", function() { 18 | var nodeList = document.getElementsByTagName("*"), 19 | arr = wysihtml5.lang.array(nodeList).get(); 20 | equal(arr.length, nodeList.length); 21 | ok(arr instanceof Array); 22 | }); -------------------------------------------------------------------------------- /examples/main.js: -------------------------------------------------------------------------------- 1 | require.config({ 2 | paths: { 3 | 'domReady': '../components/requirejs-domready/domReady', 4 | 'jquery': '../components/jquery/dist/jquery.min', 5 | 'rangy': '../components/wysihtml5x/lib/rangy/rangy-core', 6 | 'rangy-selectionsaverestore': '../components/wysihtml5x/lib/rangy/rangy-selectionsaverestore', 7 | 'bootstrap': '../components/bootstrap/dist/js/bootstrap.min', 8 | 'bootstrap.wysihtml5': '../dist/amd/bootstrap3-wysihtml5.all', 9 | 'bootstrap.wysihtml5.de-DE': '../dist/locales/bootstrap-wysihtml5.de-DE' 10 | }, 11 | shim: { 12 | 'bootstrap': { 13 | deps: ['jquery'] 14 | }, 15 | 'rangy-selectionsaverestore': { 16 | deps: ['rangy'] 17 | } 18 | }, 19 | deps: [ 20 | './start' 21 | ] 22 | }); 23 | -------------------------------------------------------------------------------- /test/dom/has_element_with_tag_name_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.dom.hasElementWithTagName", { 2 | teardown: function() { 3 | var iframe; 4 | while (iframe = document.querySelector("iframe.wysihtml5-sandbox")) { 5 | iframe.parentNode.removeChild(iframe); 6 | } 7 | } 8 | }); 9 | 10 | 11 | asyncTest("Basic test", function() { 12 | expect(3); 13 | 14 | new wysihtml5.dom.Sandbox(function(sandbox) { 15 | var doc = sandbox.getDocument(), 16 | tempElement = doc.createElement("i"); 17 | ok(!wysihtml5.dom.hasElementWithTagName(doc, "I")); 18 | doc.body.appendChild(tempElement); 19 | ok(wysihtml5.dom.hasElementWithTagName(doc, "I")); 20 | tempElement.parentNode.removeChild(tempElement); 21 | ok(!wysihtml5.dom.hasElementWithTagName(doc, "I")); 22 | 23 | start(); 24 | }).insertInto(document.body); 25 | }); -------------------------------------------------------------------------------- /test/dom/rename_element_test.js: -------------------------------------------------------------------------------- 1 | module("wysihtml5.dom.renameElement", { 2 | equal: function(actual, expected, message) { 3 | return QUnit.assert.htmlEqual(actual, expected, message); 4 | }, 5 | 6 | renameElement: function(html, newNodeName) { 7 | var container = wysihtml5.dom.getAsDom(html); 8 | wysihtml5.dom.renameElement(container.firstChild, newNodeName); 9 | return container.innerHTML; 10 | } 11 | }); 12 | 13 | test("Basic tests", function() { 14 | this.equal( 15 | this.renameElement("foo
", "div"), 16 | "TEXT " + JSON.stringify(context) + "
" + 18 | "" + 19 | "" + 20 | "39 | bootstrap-wysihtml5 is a javascript plugin that makes it easy to create simple, beautiful wysiwyg editors with the help of wysihtml5 and Twitter Bootstrap 3 40 |
41 | 42 |43 | View project on Github 44 |
45 |50 |
$('.textarea').wysihtml5();
51 |
52 |
53 | foo
" 52 | ); 53 | 54 | this.equal( 55 | this.resolveList("foo
bar
" 57 | ); 58 | 59 | this.equal( 60 | this.resolveList("foo
bar
" 62 | ); 63 | 64 | this.equal( 65 | this.resolveList("bar
" 67 | ); 68 | 69 | this.equal( 70 | this.resolveList("foo
bar
" 72 | ); 73 | 74 | this.equal( 75 | this.resolveList("baz
" 77 | ); 78 | }); 79 | -------------------------------------------------------------------------------- /index-all.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 |39 | bootstrap-wysihtml5 is a javascript plugin that makes it easy to create simple, beautiful wysiwyg editors with the help of wysihtml5 and Twitter Bootstrap 3 40 |
41 | 42 |43 | View project on Github 44 |
45 |50 |
$('.textarea').wysihtml5();
51 |
52 |
53 | 39 | bootstrap-wysihtml5 is a javascript plugin that makes it easy to create simple, beautiful wysiwyg editors with the help of wysihtml5 and Twitter Bootstrap 3 40 |
41 | 42 |43 | View project on Github 44 |
45 |50 |
$('.textarea').wysihtml5();
51 |
52 |
53 | 53 | bootstrap-wysihtml5 is a javascript plugin that makes it easy to create simple, beautiful wysiwyg editors with the help of wysihtml5 and Twitter Bootstrap 3 54 |
55 | 56 |57 | View project on Github 58 |
59 |64 |
$('.textarea').wysihtml5();
65 |
66 |
67 | 72 | Set text dynamically with javascript: 73 |
74 |75 | 76 |
77 |yeah
", "ul"), 39 | "yeah
yeah
", "ol"), 81 | "yeah
', 'Class should be inserted into image tag.');
89 | start();
90 | }, 200);
91 | };
92 |
93 | var editor = this.editableArea.wysihtml5({
94 | toolbar: {
95 | html: true
96 | },
97 | events: {
98 | 'load': onLoad,
99 | 'show:dialog': onShow,
100 | 'save:dialog': onHide
101 | },
102 | parserRules: {
103 | classes: { 'mytxtimg': 1 },
104 | tags: { 'img':
105 | { 'set_class': 'mytxtimg' }
106 | }
107 | }
108 | });
109 |
110 | });
111 | */
112 | }
113 |
--------------------------------------------------------------------------------
/karma.conf.js:
--------------------------------------------------------------------------------
1 | // Karma configuration
2 | // Generated on Thu Jun 26 2014 23:11:33 GMT+0200 (CEST)
3 |
4 | module.exports = function(config) {
5 | config.set({
6 |
7 | // base path that will be used to resolve all patterns (eg. files, exclude)
8 | basePath: '',
9 |
10 |
11 | // frameworks to use
12 | // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
13 | frameworks: ['qunit'],
14 | plugins: ['karma-qunit',
15 | 'karma-coverage',
16 | 'karma-chrome-launcher',
17 | 'karma-phantomjs-launcher'],
18 |
19 | // list of files / patterns to load in the browser
20 | files: [
21 | // Bower deps
22 | {pattern: 'components/wysihtml5x/dist/wysihtml5x-toolbar.js', watched: false, included: true, served: true},
23 | {pattern: 'components/jquery/dist/jquery.js', watched: false, included: true, served: true},
24 | {pattern: 'components/bootstrap/dist/js/bootstrap.min.js', watched: false, included: true, served: true},
25 | {pattern: 'components/handlebars/handlebars.runtime.min.js', watched: false, included: true, served: true},
26 |
27 | // Node deps
28 | {pattern: 'node_modules/qunitjs/qunit/qunit.js', watched: false, included: true, served: true},
29 | {pattern: 'node_modules/happen/happen.js', watched: false, included: true, served: true},
30 | {pattern: 'node_modules/qunit-assert-html/dist/qunit-assert-html.js', watched: false, included: true, served: true},
31 |
32 | // Source
33 | {pattern: 'src/generated/templates.js', watched: true, included: true, served: true},
34 | {pattern: 'src/bootstrap3-wysihtml5.js', watched: true, included: true, served: true},
35 | {pattern: 'src/locales/bootstrap-wysihtml5.en-US.js', watched: true, included: true, served: true},
36 | {pattern: 'src/generated/commands.js', watched: true, included: true, served: true},
37 |
38 | //CSS
39 | {pattern: 'components/bootstrap/dist/css/*.min.css', watched: false, included: true, served: true},
40 | {pattern: 'components/bootstrap/dist/fonts/*', watched: false, included: false, served: true},
41 | {pattern: 'src/*.css', watched: false, included: true, served: true},
42 |
43 | // Test helpers
44 | {pattern: 'test/testhelper.js', watched: true, included: true, served: true},
45 | {pattern: 'test/karma/test-main.js', watched: true, included: true, served: true},
46 |
47 | // Tests
48 | {pattern: 'test/**/*test.js', watched: true, included: true, served: true}
49 | ],
50 |
51 |
52 | // list of files to exclude or ignored tests
53 | exclude: [
54 | //small doesn't work at the moment. see https://github.com/Edicy/wysihtml5/issues/59
55 | //'test/bs/bootstrap_editor_commands_test.js'
56 | ],
57 |
58 |
59 | // preprocess matching files before serving them to the browser
60 | // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
61 | preprocessors: {
62 | 'src/**/*.js': 'coverage'
63 | },
64 |
65 |
66 | // test results reporter to use
67 | // possible values: 'dots', 'progress'
68 | // available reporters: https://npmjs.org/browse/keyword/karma-reporter
69 | reporters: ['progress', 'coverage'],
70 |
71 |
72 | // web server port
73 | port: 9876,
74 |
75 |
76 | // enable / disable colors in the output (reporters and logs)
77 | colors: true,
78 |
79 |
80 | // level of logging
81 | // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
82 | logLevel: config.LOG_INFO,
83 |
84 |
85 | // enable / disable watching file and executing tests whenever any file changes
86 | autoWatch: true,
87 |
88 |
89 | // start these browsers
90 | // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
91 | //browsers: ['Chrome', 'PhantomJS'],
92 | browsers: ['Chrome'],
93 |
94 | // Continuous Integration mode
95 | // if true, Karma captures browsers, runs the tests and exits
96 | singleRun: false
97 | });
98 | };
99 |
--------------------------------------------------------------------------------
/test/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | 51 | bootstrap-wysihtml5 is a javascript plugin that makes it easy to create simple, beautiful wysiwyg editors with the help of wysihtml5 and Twitter Bootstrap 3 52 |
53 | 54 |55 | View project on Github 56 |
57 |62 |
$('.textarea').wysihtml5();
63 |
64 |
65 |