All Projects → NARKOZ → wysihtml5-rails

NARKOZ / wysihtml5-rails

Licence: BSD-2-Clause license
A wysiwyg text editor for use in the Rails asset pipeline

Programming Languages

ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to wysihtml5-rails

Flutter Quill
Rich text editor for Flutter
Stars: ✭ 177 (+532.14%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
wysiwyg-editor-python-sdk
Python SDK to ease the integration of Froala WYSIWYG Editor on server side.
Stars: ✭ 20 (-28.57%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Wysiwyg Editor
The next generation Javascript WYSIWYG HTML Editor.
Stars: ✭ 4,756 (+16885.71%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Ckeditor5
Powerful rich text editor framework with a modular architecture, modern integrations, and features like collaborative editing.
Stars: ✭ 5,406 (+19207.14%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Jodit
Jodit - Best WYSIWYG Editor for You
Stars: ✭ 947 (+3282.14%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Pell
📝 the simplest and smallest WYSIWYG text editor for web, with no dependencies
Stars: ✭ 11,653 (+41517.86%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Awesome Wysiwyg
A curated list of awesome WYSIWYG editors.
Stars: ✭ 1,801 (+6332.14%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Re Editor
一个开箱即用的React富文本编辑器 🚀re-editor
Stars: ✭ 367 (+1210.71%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
ngx-wall
Helps build content editor for note-taking application
Stars: ✭ 78 (+178.57%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Angular Froala Wysiwyg
Angular 4, 5, 6, 7, 8 and 9 plugin for Froala WYSIWYG HTML Rich Text Editor.
Stars: ✭ 696 (+2385.71%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Element Tiptap
🌸A modern WYSIWYG rich-text editor using tiptap and Element UI for Vue.js
Stars: ✭ 481 (+1617.86%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Canner Slate Editor
📝Rich Text / WYSIWYG Editor built for Modularity and Extensibility.
Stars: ✭ 1,071 (+3725%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Angular Editor
A simple native WYSIWYG editor component for Angular 6 -10+
Stars: ✭ 428 (+1428.57%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Textbus
基于组件 + 数据驱动的现代富文本编辑器
Stars: ✭ 242 (+764.29%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Slate Plugins
🔌 Next-gen slate plugins
Stars: ✭ 399 (+1325%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Wysiwyg.js
wysiwyg contenteditable editor (minified+compression: 6kb)
Stars: ✭ 520 (+1757.14%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Awesome Web Editor
🔨 Open source WEB editor summary
Stars: ✭ 306 (+992.86%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Trumbowyg
A lightweight and amazing WYSIWYG JavaScript editor under 10kB
Stars: ✭ 3,664 (+12985.71%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Simditor
An Easy and Fast WYSIWYG Editor
Stars: ✭ 4,926 (+17492.86%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor
Megadraft
Megadraft is a Rich Text editor built on top of Facebook's Draft.JS featuring a nice default base of components and extensibility
Stars: ✭ 982 (+3407.14%)
Mutual labels:  wysiwyg, rich-text-editor, wysiwyg-editor

wysihtml5 for rails

A wysiwyg text editor for use in the Rails 3 asset pipeline.

Installation

Add to your Gemfile:

gem 'wysihtml5-rails'

and run:

bundle install

Usage

Require it in your JS manifest's file:

//= require wysihtml5

Additionally include advanced or simple parser rule:

//= require parser_rules/simple

Add to your template before closing body html tag:

<script>
  var editor = new wysihtml5.Editor("wysihtml5-textarea", { // id of textarea element
    toolbar:      "wysihtml5-toolbar", // id of toolbar element
    stylesheets:  "<%= stylesheet_path('wysiwyg') %>", // optional, css to style the editor's content
    parserRules:  wysihtml5ParserRules // defined in parser rules set
  });
</script>

Usage example

Add to application.js

//= require wysihtml5
//= require parser_rules/advanced

Create form with wysihtml5 textarea:

<div id="wysihtml5-toolbar" style="display: none;">
  <a data-wysihtml5-command="bold">bold</a>
  <a data-wysihtml5-command="italic">italic</a>
  <a data-wysihtml5-command="underline">underline</a>

  <a data-wysihtml5-command="insertOrderedList">insert ordered list</a>
  <a data-wysihtml5-command="insertUnorderedList">insert unordered list</a>

  <a data-wysihtml5-command="foreColor" data-wysihtml5-command-value="red">red</a>
  <a data-wysihtml5-command="foreColor" data-wysihtml5-command-value="green">green</a>
  <a data-wysihtml5-command="foreColor" data-wysihtml5-command-value="blue">blue</a>

  <a data-wysihtml5-command="createLink">insert link</a>
  <div data-wysihtml5-dialog="createLink" style="display: none;">
    <label>
      Link: <input data-wysihtml5-dialog-field="href" value="http://" class="text">
    </label>
    <a data-wysihtml5-dialog-action="save">OK</a>
    <a data-wysihtml5-dialog-action="cancel">Cancel</a>
  </div>
</div>

<%= form_for @post do |f| %>
  <p><%= f.text_area :content, :id => 'wysihtml5-textarea' %></p>
  <p><%= f.submit %></p>
<% end %>

<script>
  var editor = new wysihtml5.Editor("wysihtml5-textarea", {
    toolbar:      "wysihtml5-toolbar",
    stylesheets:  "<%= stylesheet_path('wysiwyg') %>",
    parserRules:  wysihtml5ParserRules
  });
</script>

For more information, check out wysihtml5 wiki.

License

wysihtml5 is distributed under the MIT License.
wysihtml5-rails is licensed under BSD License.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].