mirror of
https://github.com/codex-team/editor.js
synced 2026-03-15 23:25:47 +01:00
New Tools module
This commit is contained in:
parent
ed28a85db6
commit
8f9809dae7
6 changed files with 538 additions and 48 deletions
|
|
@ -53,21 +53,39 @@
|
|||
<!--<script src="plugins/attaches/attaches.js"></script>-->
|
||||
<!--<link rel="stylesheet" href="plugins/attaches/attaches.css">-->
|
||||
|
||||
<script src="codex-editor.js?v=108"></script>
|
||||
<link rel="stylesheet" href="codex-editor.css?v=11000">
|
||||
<script src="../build/codex-editor.js?v=108"></script>
|
||||
<link rel="stylesheet" href="../build/codex-editor.css?v=11000">
|
||||
|
||||
<script>
|
||||
|
||||
class Quote {
|
||||
|
||||
render() {
|
||||
console.log("Quote rendering");
|
||||
}
|
||||
|
||||
save() {
|
||||
console.log("Quote saving");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
console.log("This is Quote", Quote);
|
||||
codex = {};
|
||||
codex.editor = 1;
|
||||
var editor = new CodexEditor({
|
||||
holderId : 'codex-editor',
|
||||
inittialBlock : 'paragraph',
|
||||
// tools: {
|
||||
// quote: Quote
|
||||
// },
|
||||
// toolsConfig: {
|
||||
// quote: {}
|
||||
// }
|
||||
tools: {
|
||||
quote: Quote
|
||||
},
|
||||
toolsConfig: {
|
||||
quote: {
|
||||
iconClassname : 'quote-icon',
|
||||
displayInToolbox : true,
|
||||
enableLineBreaks : true
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue