All Projects → Friendly-Pixel → Grid Editor

Friendly-Pixel / Grid Editor

Licence: mit
Visual javascript editor for the bootstrap 4 grid system, written as a jQuery plugin.

Programming Languages

javascript
184084 projects - #8 most used programming language

Labels

Projects that are alternatives of or similar to Grid Editor

Artdialog
经典的网页对话框组件
Stars: ✭ 3,110 (+793.68%)
Mutual labels:  jquery
Calendar
This library is a jQuery plugin for Bootstrap that lets you add a month calendar to your web page.
Stars: ✭ 315 (-9.48%)
Mutual labels:  jquery
Wondercms
WonderCMS - fast and small flat file CMS (5 files)
Stars: ✭ 330 (-5.17%)
Mutual labels:  jquery
Hulk
In-browser JSON editor
Stars: ✭ 302 (-13.22%)
Mutual labels:  jquery
Web
📚 从零开始学 Web 前端系列图文教程。从零基础开始,手把手教你进入前端开发的世界。公众号「前端队长」作者。
Stars: ✭ 313 (-10.06%)
Mutual labels:  jquery
Bootstrap Rating Input
Another plugin that eases the generation of rating stars for jQuery and Bootstrap
Stars: ✭ 318 (-8.62%)
Mutual labels:  jquery
Validate
A simple jQuery plugin to validate forms.
Stars: ✭ 298 (-14.37%)
Mutual labels:  jquery
Zoomove
🔍 🎆 Enlarges the image with the mouse hover and move
Stars: ✭ 339 (-2.59%)
Mutual labels:  jquery
Tweetie
Simple jQuery Twitter feed plugin
Stars: ✭ 314 (-9.77%)
Mutual labels:  jquery
Jquery Fullscreen Plugin
This jQuery plugin provides a simple to use mechanism to control the new fullscreen mode of modern browsers
Stars: ✭ 327 (-6.03%)
Mutual labels:  jquery
Manong Ssm
基于SSM框架的Java电商项目
Stars: ✭ 306 (-12.07%)
Mutual labels:  jquery
Tilt.js
A tiny 60+fps parallax tilt hover effect for jQuery.
Stars: ✭ 3,442 (+889.08%)
Mutual labels:  jquery
Roncoo Adminlte
RonCoo AdminLTE --是一个完全响应式的免费开源后台管理模板。基于 AdminLTE 框架(后续会随着版本更新而更新);使用jQuery 2.2.3版本,并引入很多优秀的第三方jQuery插件,开发者也可以改用自己熟悉的第三方插件,易于使用,并高度可定制,适合许多屏幕分辨率从小型移动设备到大型台式机,这是国内的开源模板未支持的。
Stars: ✭ 320 (-8.05%)
Mutual labels:  jquery
Waitme
jquery plugin for easy creating loading css3/images animations
Stars: ✭ 302 (-13.22%)
Mutual labels:  jquery
Datetimepicker
jQuery Plugin Date and Time Picker
Stars: ✭ 3,402 (+877.59%)
Mutual labels:  jquery
Jquery Match Height
a responsive equal heights plugin
Stars: ✭ 3,100 (+790.8%)
Mutual labels:  jquery
Hover3d
Simple jQuery plugin for 3d Hover effect
Stars: ✭ 318 (-8.62%)
Mutual labels:  jquery
Bootstrap Iconpicker
A simple icon picker
Stars: ✭ 344 (-1.15%)
Mutual labels:  jquery
Wpaint
jQuery Paint Plugin
Stars: ✭ 332 (-4.6%)
Mutual labels:  jquery
Jquery Loading
Easily add and manipulate loading states of any element on the page.
Stars: ✭ 321 (-7.76%)
Mutual labels:  jquery

Grid Editor

Grid Editor is a visual javascript editor for the bootstrap 4 grid system, written as a jQuery plugin. You can create, drag, resize and delete rows and columns, and set different column widths for tablets and phones.

(Looking for the bootstrap 3 support? Use version 0 in the bootstrap_3 branch)

It provides integration plugins for the following rich text editors to edit column content: TinyMCE, summernote and CKEditor.

Preview

Try the demo!

Installation

  • Dependencies: Grid Editor depends on jQuery, jQuery UI, Font Awesome 4 or 5, and Bootstap 4, so make sure you have included those in the page.
    • If you want to use the tincyMCE integration, include tinyMCE and tinyMCE jQuery plugin as well.
    • If you want to use the summernote integration, include summernote as well.
    • If you want to use the CKEditor integration... you get the point.
  • Download the latest version of Grid Editor and include it in your page:
<!-- Make sure jQuery, jQuery UI, font awesome, and bootstrap 4 are included. TinyMCE is optional. -->
<link rel="stylesheet" type="text/css" href="grid-editor/dist/grideditor.css" />
<script src="grid-editor/dist/jquery.grideditor.min.js"></script>

Usage

$('#myGrid').gridEditor({
    new_row_layouts: [[12], [6,6], [9,3]],
});
// Call this to get the result after the user has done some editing:
var html = $('#myGrid').gridEditor('getHtml');

Methods

getHtml: Returns the clean html.

var html = $('#myGrid').gridEditor('getHtml');

remove: Completely remove grideditor.

$('#myGrid').gridEditor('remove');

Options

General options

new_row_layouts: Set the column layouts that appear in the "new row" buttons at the top of the editor.

$('#myGrid').gridEditor({
    new_row_layouts: [[12], [6,6], [9,3]],
});

row_classes: Set the css classes that the user can toggle on the rows, under the settings button.

$('#myGrid').gridEditor({
    row_classes: [{label: 'Example class', cssClass: 'example-class'}],
});

col_classes: The same as row_classes, but for columns.

row_tools: Add extra tool buttons to the row toolbar.

$('#myGrid').gridEditor({
    row_tools: [{
        title: 'Set background image',
        iconClass: 'glyphicon-picture',
        on: { 
            click: function() {
                $(this).closest('.row').css('background-image', 'url(http://placekitten.com/g/300/300)');
            }
        }
    }]
});

col_tools: The same as row_tools, but for columns.

custom_filter: Allows the execution of a custom function before initialization and after de-initialization. Accepts a functions or a function name as string. Gives the canvas element and isInit (true/false) as parameter.

$('#myGrid').gridEditor({
    'custom_filter': 'functionname',
});

function functionname(canvas, isInit) {
    if(isInit) {
        // do magic on init
    } else {
        // do magic on de-init
    }
}

or

$('#myGrid').gridEditor({
    'custom_filter': function(canvas, isInit) {
        //...
    },
});

valid_col_sizes: Specify the column widths that can be selected using the +/- buttons

$('#myGrid').gridEditor({
    'valid_col_sizes': [2, 5, 8, 10],
});

source_textarea: Allows to set an already existing textarea as input for grid editor.

$('#myGrid').gridEditor({
    source_textarea: 'textarea.myTextarea',
});

You will have write back the content to the textarea before saving, for example in this way:

$('form.myForm').on('submit', function() {
    var html = $('#myGrid').gridEditor('getHtml');
    $('textarea.myTextarea').val(html);
});

Rich text editor options

Grid editor comes bundles with support for the following rich text editors (RTEs):

content_types: Specify the RTE to use. Valid values: ['tinymce'], ['summernote'], ['ckeditor']. Default value: ['tinymce'].

$('#myGrid').gridEditor({
    content_types: ['summernote'],
});

ckeditor.config: Specify ckeditor config, when using the ckeditor content_types. See the CKEditor documentation. Also check out the ckeditor example.

$('#myGrid').gridEditor({
    ckeditor: {
        config: { language: 'fr' }
    }
});

summernote.config: Specify summernote config, when using the summernote content_types. See the summernote documentation. Also check out the summernote example.

$('#myGrid').gridEditor({
    summernote: {
        config: { shortcuts: false }
    }
});

tinymce.config: Specify tinyMCE config, when using the tinymce content_types. See the tinyMCE documentation. Also check out the tinymce example.

$('#myGrid').gridEditor({
    tinymce: {
        config: { paste_as_text: true }
    }
});

Upgrading

See UPGRADING.md for the changes you have to make when upgrading from grid-editor version 0 to 1.

Building

If you want to make your own changes to the source, see BUILDING.md

Contributing

If you want to help out, please first read CONTRIBUTING.md

Attribution

Grid Editor was heavily inspired by Neokoenig's grid manager

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].