• Stars
    star
    661
  • Rank 67,731 (Top 2 %)
  • Language
    HTML
  • License
    MIT License
  • Created over 10 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Tiny bootstrap-compatible WYSIWYG rich text editor

bootstrap-wysiwyg

GitHub release GitHub license

A tiny Bootstrap and jQuery based WYSIWYG rich text editor based on the browser function execCommand.

This project was originally built for MindMup and has now been adapted and modified to suit a wide range of projects.

Development is active, and ongoing.

Features

  • Automatically binds standard hotkeys for common operations on Mac and Windows
  • Allows a custom built toolbar with no magic markup generators enabling the web site to use all the goodness of Bootstrap
  • Does not force any styling - it's all up to you
  • Uses standard browser features, no magic non-standard code, toolbar and keyboard configurable to execute any supported browser command
  • Does not create a separate frame, backup text areas etc - instead keeps it simple and runs everything inline in a DIV
  • (Optionally) cleans up trailing whitespace and empty divs and spans
  • Requires a modern browser (See SUPPORTED)
  • Supports mobile devices (See SUPPORTED)
  • Supports multiple instances
  • HTML Sanitization
  • Drag and drop files to insert images
  • Supports image upload
  • Supports image capture on mobile devices
  • Events

Styling for mobile devices

This editor should work pretty well with mobile devices, but you'll need to consider the following things when styling it:

  • keyboards on mobile devices take a huge part of the screen
  • having to scroll the screen to touch the toolbar can cause the editing component to lose focus, and the mobile device keyboard might go away
  • mobile devices tend to move the screen viewport around to ensure that the focused element is shown, so it's best that the edit box is glued to the top

For the content attachment editor on MindMup, we apply the following rules to mobile device styling:

  • edit box is glued to the top, so the focus doesn't jump around
  • toolbar is below the edit box
  • on portrait screens, edit box size is 50% of the screen
  • on landscape screens, edit box size is 30% of the screen
  • as the screen gets smaller, non-critical toolbar buttons get hidden into a "other" menu

How to Get Started

To learn the basics of the boostrap-wysiwyg editor, please refer to the project's Getting Started wiki article.

Dependencies

Thanks to

@gojko @mindmup @jordanh @beatnbite @brutuscat @VictorBjelkholm @mrmrs @tilleryd @pnevels

History

The original version of this code (below) appeared to be no longer maintained. There were a number of outstanding changes which needed to be merged in and a few which included performance and feature improvements. These have now been included in this master branch.

I'll keep an eye out for future changes/improvements and pull them in as required.

  • Steve

Original Licence

The original version of this tool can be found here: bootstrap-wysiwyg

The MIT License

Copyright (c) 2013 Damjan Vujnovic, David de Florinier, Gojko Adzic

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

More Repositories

1

GSJSON

JSON Stylesheet for the Google Search Appliance (GSA)
XSLT
24
star
2

cups

Modifications and enhancements to the CUPS system.
C
22
star
3

php-linked-list

My implementation of a Linked List class in PHP
PHP
5
star
4

php-ipp

PHP IPP Client and Server
PHP
5
star
5

Debian-PHP5

Debian Package for PHP5
C
3
star
6

code-examples

Code Examples
PHP
3
star
7

Google-CSE-Class

A simple PHP Google CSE Class
PHP
3
star
8

php-sdk

We have created a new repository for this project: https://github.com/facebook/facebook-php-sdk. Please update anything you have pointing at this repostory to this location before April 1, 2012.
PHP
2
star
9

aws-php-lambda-static-binary

Static PHP Binaries for AWS Lambda
2
star
10

hackth.at

Hack That
PHP
2
star
11

gsa-trendy-frontdoor

Trendy Frontdoor for GSA instead of boring search page.
2
star
12

ubuntu-nginx-rtmp

Package to build Ubuntu NGINX RTMP in a default Ubuntu Style
Shell
2
star
13

rewiredstate-wp-theme

rewiredstate.org WordPress Theme
PHP
2
star
14

Related-Buzz-Results

Get Google Buzz results on your GSA
JavaScript
2
star
15

wp-crowd-sso-login

Atalssian Crowd SSO Plugin for Wordpress
1
star
16

java-xslmin

An xslt minifier for Java
Java
1
star
17

efs-manager-frontend

AWS EFS Manager
1
star
18

Open-Wordstrap

Basic Bootstrap wordpress theme.
PHP
1
star
19

keysafe

PHP KeySafe for Apps
PHP
1
star
20

AFNetworking-legacy

Legacy support for AFNetworking (2.6.3 and earlier)
Objective-C
1
star
21

Google-GSA-Mini-PHP-Handler

PHP handler for working with GSA
1
star
22

php-kml-handler

KML Handler (GIS Tools)
PHP
1
star
23

php-csv-to-json

A light weight CSV to JSON converter
PHP
1
star
24

steveathon.github.io

Web
CSS
1
star
25

NSW-DISABILITY-SERVICES-ACT-1993

DISABILITY SERVICES ACT 1993
1
star
26

php-tesseract

php-tesseract
Groff
1
star
27

php-pre-process

A PHP based input pre-handler.
PHP
1
star
28

telepresence

Automatically exported from code.google.com/p/telepresence
C++
1
star
29

youtube-live-bash

Some of my bash scripts for YT Live
Shell
1
star