add description to each example

This commit is contained in:
Kevin Jahns 2018-11-27 00:57:15 +01:00
parent 01d0825ae6
commit 9bd199a6e7
4 changed files with 23 additions and 13 deletions

View File

@ -10,7 +10,11 @@
</style> </style>
</head> </head>
<body> <body>
<p>This example shows how to bind a YXmlFragment type to an arbitrary DOM element. We set the DOM element to contenteditable so it basically behaves like a very powerful rich-text editor.</p>
<p>The content of this editor is shared with every client who visits this domain.</p>
<hr>
<div class="code-html"> <div class="code-html">
<div id="content" contenteditable=""></div> <div id="content" contenteditable=""></div>
</div> </div>
<script class="code-js" src="./build/dom.js"> <script class="code-js" src="./build/dom.js">

View File

@ -41,7 +41,10 @@
</style> </style>
</head> </head>
<body> <body>
<p>This example shows how to bind a YXmlFragment type to a <a href="http://prosemirror.net">Prosemirror</a> editor.</p>
<p>The content of this editor is shared with every client who visits this domain.</p>
<div class="code-html"> <div class="code-html">
<div id="editor" style="margin-bottom: 23px"></div> <div id="editor" style="margin-bottom: 23px"></div>
<div style="display: none" id="content"></div> <div style="display: none" id="content"></div>
</div> </div>

View File

@ -1,11 +1,12 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<title>Yjs Prosemirror Example</title> <title>Yjs Quill Example</title>
<link rel=stylesheet href="https://prosemirror.net/css/editor.css"> <link rel="stylesheet" href="https://cdn.quilljs.com/1.3.6/quill.snow.css">
</head> </head>
<body> <body>
<link href="https://cdn.quilljs.com/1.3.6/quill.snow.css" rel="stylesheet"> <p>This example shows how to bind a YText type to <a href="https://quilljs.com">Quill</a> editor.</p>
<p>The content of this editor is shared with every client who visits this domain.</p>
<div class="code-html"> <div class="code-html">
<div id="quill-container"> <div id="quill-container">
<div id="quill"> <div id="quill">

View File

@ -2,10 +2,12 @@
<html> <html>
<head> <head>
<title>Yjs Textarea Example</title> <title>Yjs Textarea Example</title>
<link rel=stylesheet href="https://prosemirror.net/css/editor.css">
</head> </head>
<body> <body>
<p>This example shows how to bind a YText type to a DOM Textarea.</p>
<p>The content of this textarea is shared with every client who visits this domain.</p>
<div class="code-html"> <div class="code-html">
<textarea style="width:80%;" rows=40 autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"></textarea> <textarea style="width:80%;" rows=40 autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"></textarea>
</div> </div>
<script class="code-js" src="./build/textarea.js"> <script class="code-js" src="./build/textarea.js">