All Projects → StevenDevooght → Tinymce Mention

StevenDevooght / Tinymce Mention

Mention/Autocomplete plugin for tinyMCE WYSIWYG editor.

Programming Languages

javascript
184084 projects - #8 most used programming language

Labels

Projects that are alternatives of or similar to Tinymce Mention

yii2-tinymce
Yii2 extension, tinymce wysiwyg editor
Stars: ✭ 16 (-91.16%)
Mutual labels:  tinymce
Tinymce Vue
Official TinyMCE Vue component
Stars: ✭ 1,198 (+561.88%)
Mutual labels:  tinymce
Filemanagerbundle
FileManager is a simple Multilingual File Manager Bundle for Symfony
Stars: ✭ 105 (-41.99%)
Mutual labels:  tinymce
Tinymce React
Offical TinyMCE React component
Stars: ✭ 448 (+147.51%)
Mutual labels:  tinymce
Angular2 Tinymce
Angular 2 component for TinyMCE MCE WYSIWYG editor
Stars: ✭ 66 (-63.54%)
Mutual labels:  tinymce
Plugin.wordpress
📦 Official WordPress Plugin of EnlighterJS
Stars: ✭ 93 (-48.62%)
Mutual labels:  tinymce
html-integrations
The official JavaScript library for MathType, the leading formula editor and equation writer for the web by Wiris
Stars: ✭ 36 (-80.11%)
Mutual labels:  tinymce
Laravel Filemanager
Media gallery with CKEditor, TinyMCE and Summernote support. Built on Laravel file system.
Stars: ✭ 1,688 (+832.6%)
Mutual labels:  tinymce
Laravel Tinymce Simple Imageupload
Simple image upload for TinyMCE in Laravel.
Stars: ✭ 66 (-63.54%)
Mutual labels:  tinymce
Laravel Filemanager Example 5.3
Demo integration for laravel-filemanager (https://github.com/UniSharp/laravel-filemanager).
Stars: ✭ 100 (-44.75%)
Mutual labels:  tinymce
Ui Tinymce
AngularUI wrapper for TinyMCE
Stars: ✭ 499 (+175.69%)
Mutual labels:  tinymce
Grav Plugin Tinymce Editor
TinyMCE Editor Integration Plugin for Grav
Stars: ✭ 44 (-75.69%)
Mutual labels:  tinymce
Tinymce
The world's #1 JavaScript library for rich text editing. Available for React, Vue and Angular
Stars: ✭ 10,179 (+5523.76%)
Mutual labels:  tinymce
jce
JCE - A Content Editor for Joomla
Stars: ✭ 29 (-83.98%)
Mutual labels:  tinymce
Tinymce Dist
Official TinyMCE repository for production usage in package managers
Stars: ✭ 106 (-41.44%)
Mutual labels:  tinymce
vite-vue-admin
🎉🎉使用Vite + Vue3 + TypeScript + Element-plus + Mock开发的后台管理系统🎉🎉
Stars: ✭ 97 (-46.41%)
Mutual labels:  tinymce
Filemanager Laravel
FileManager for Laravel integrated with TinyMCE
Stars: ✭ 87 (-51.93%)
Mutual labels:  tinymce
Vue Tinymce
提供给 vue 开发者使用的 TinyMCE 组件
Stars: ✭ 124 (-31.49%)
Mutual labels:  tinymce
Django Tinymce4 Lite
TinyMCE 4 editor widget for Django
Stars: ✭ 121 (-33.15%)
Mutual labels:  tinymce
2sxc
DNN + 2sxc = #DNNCMS - This tool helps web designers and developers prepare great looking content in DNN (DotNetNuke). It's like mixing DNN with Umbraco and Drupal :)
Stars: ✭ 98 (-45.86%)
Mutual labels:  tinymce

tinyMCE mention

Travis

Mentions plugin for tinyMCE WYSIWYG editor.

preview

Browser compatibility

  • IE7+
  • Chrome
  • Safari
  • Firefox
  • Opera

Dependencies

NOTE: Use v3.x if you're using tinyMCE v3.5.x, use v4.x if you're using tinyMCE v4.x

Usage

Install using bower.

bower install tinymce-mention

Or copy the source of the plugin to the plugins directory of your tinyMCE installation. Add the mention plugin to your tinyMCE configuration.

plugins : "advlink, paste, mention",

Add configuration options for the mention plugin. source is the only required setting.

NOTE: source can also be a function. see the options section below.

mentions: {
    source: [
        { name: 'Tyra Porcelli' }, 
        { name: 'Brigid Reddish' },
        { name: 'Ashely Buckler' },
        { name: 'Teddy Whelan' }
    ]
},

Configuration

source (required)

The source parameter can be configured as an array or a function.

array

source: [
    { name: 'Tyra Porcelli' }, 
    { name: 'Brigid Reddish' },
    { name: 'Ashely Buckler' },
    { name: 'Teddy Whelan' }
]

function

source: function (query, process, delimiter) {
    // Do your ajax call
    // When using multiple delimiters you can alter the query depending on the delimiter used
    if (delimiter === '@') {
       $.getJSON('ajax/users.json', function (data) {
          //call process to show the result
          process(data)
       });
    }
}

queryBy

The name of the property used to do the lookup in the source.

Default: 'name'.

delimiter

Character that will trigger the mention plugin. Can be configured as a character or an array of characters.

character

delimiter: '@'

array

delimiter: ['@', '#']

Default: '@'.

delay

Delay of the lookup in milliseconds when typing a new character.

Default: 500.

items

Maximum number of items displayed in the dropdown.

Default: 10

matcher

Checks for a match in the source collection.

matcher: function(item) {
    //only match Peter Griffin
    if(item[this.options.queryBy] === 'Peter Griffin') {
        return true;
    }
}

highlighter

Highlights the part of the query in the matched result.

highlighter: function(text) {
    //make matched block italic
    return text.replace(new RegExp('(' + this.query + ')', 'ig'), function ($1, match) {
        return '<i>' + match + '</i>';
    });
}

insertFrom

Key used in the default insert implementation.

Default: queryBy value

NOTE: key can be any property defined insource option.

insert

Callback to set the content you want to insert in tinyMCE.

insert: function(item) {
    return '<span>' + item.name + '</span>';
}

NOTE: item parameter has all properties defined in the source option.

render

Callback to set the HTML of an item in the autocomplete dropdown.

render: function(item) {
    return '<li>' +
               '<a href="javascript:;"><span>' + item.name + '</span></a>' +
           '</li>';
}

NOTE: item parameter has all properties defined in the source option.

renderDropdown

Callback to set the wrapper HTML for the autocomplete dropdown.

renderDropdown: function() {
    //add twitter bootstrap dropdown-menu class
    return '<ul class="rte-autocomplete dropdown-menu"></ul>';
}

License

MIT licensed

Copyright (C) 2013 Cognistreamer, http://cognistreamer.com

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