All Projects → micc83 → Fonticonpicker

micc83 / Fonticonpicker

Licence: mit
🌈 jQuery fontIconPicker v2 is a small (3.22kb gzipped) jQuery plugin which allows you to include a simple icon picker with search and pagination inside your administration forms.

Projects that are alternatives of or similar to Fonticonpicker

font-apex
Font APEX is an open source icon library from the Oracle APEX team.
Stars: ✭ 85 (-67.68%)
Mutual labels:  font-icons
leaflet-locationpicker
Simple location picker on Leaflet map
Stars: ✭ 31 (-88.21%)
Mutual labels:  jquery-plugin
MeeInk
Material Design click effect
Stars: ✭ 33 (-87.45%)
Mutual labels:  jquery-plugin
jquery-xhr-upload-queue
📂 A jQuery queued file uploading plugin.
Stars: ✭ 17 (-93.54%)
Mutual labels:  jquery-plugin
jquery-steps
✅ Lightweight jQuery step wizard plugin.
Stars: ✭ 93 (-64.64%)
Mutual labels:  jquery-plugin
personJudge
personJudge System 网站预览---->http://47.106.235.227 (账号111,密码12345) 后端:SpringBoot/JPA/mysql/cache/前后端分离(nginx做静态转发)/swagger 前端:bootstrap+Jquery及其插件:jquery-cookie,toastr,steps,validate,wnumb,nouislider,DataTables,layer,chosen,echarts
Stars: ✭ 35 (-86.69%)
Mutual labels:  jquery-plugin
LineProgressbar
A light weight jquery progressbar plugin
Stars: ✭ 34 (-87.07%)
Mutual labels:  jquery-plugin
Jquery Tablesort
A tiny & dead-simple jQuery plugin for sortable tables.
Stars: ✭ 254 (-3.42%)
Mutual labels:  jquery-plugin
Github-Contribution-Graph
Jquery plugin to render like contribution graph on Github.
Stars: ✭ 43 (-83.65%)
Mutual labels:  jquery-plugin
Web-Time-Tracker
Plugin named Timetracker is a time counter that works in both increase and decrease directions.
Stars: ✭ 21 (-92.02%)
Mutual labels:  jquery-plugin
vaadin-icons
Vaadin Icons is a collection of 600+ unique icons designed for web applications
Stars: ✭ 59 (-77.57%)
Mutual labels:  font-icons
jQuery-plugins
jQuery-plugins
Stars: ✭ 36 (-86.31%)
Mutual labels:  jquery-plugin
menu
基于jQuery的轻量级响应式菜单插件
Stars: ✭ 18 (-93.16%)
Mutual labels:  jquery-plugin
natural js
Natural-JS : Javascript Front-End Architecture Framework
Stars: ✭ 35 (-86.69%)
Mutual labels:  jquery-plugin
jquery-skeduler
This is jQuery plugin which provides you simple scheduler with some items on OX and 24-hours timeline on OY.
Stars: ✭ 23 (-91.25%)
Mutual labels:  jquery-plugin
jquery.random-fade-in
jQuery plugin to fade-in at random.
Stars: ✭ 13 (-95.06%)
Mutual labels:  jquery-plugin
image-uploader
Simple Drag & Drop image uploader plugin to static forms, without using AJAX
Stars: ✭ 70 (-73.38%)
Mutual labels:  jquery-plugin
Smartscroll
jQuery plugin for scrolljacking and auto-hashing
Stars: ✭ 255 (-3.04%)
Mutual labels:  jquery-plugin
scrupulous
Simple inline form validation using HTML5 attributes that plays nicely with Bootstrap
Stars: ✭ 12 (-95.44%)
Mutual labels:  jquery-plugin
jquery.simple-scroll-follow
jQuery plugin to move the element according to the scrolling window.
Stars: ✭ 34 (-87.07%)
Mutual labels:  jquery-plugin

jQuery fontIconPicker v3.0 is out

Version 2.0 of jQuery fontIconPicker will no more receive updates nor support. You can find Version 3.0 right here:

Click here to get jQuery fontIconPicker v3.0

jQuery fontIconPicker v2.0

jQuery fontIconPicker is a small (3.22KB gzipped) jQuery plugin which allows you to include an elegant icon picker with categories, search and pagination inside your administration forms. The list of icons can be loaded manually using a SELECT field, an Array or Object of icons or directly from a Fontello config.json or IcoMoon selection.json file. Go to the official plugin page for examples and documentation.

Notice : Many of the features introduced with release 2.0.0 were the result of a collaboration. Unfortunately the developer of those features is not actively following the project anymore so you're more than welcome to step in. The problem is that since version 1.0.0 jQuery fontIconPicker has grown much and it's not mantainable anymore without writing first a carefully drafted test suite. So the first stage of any collaboration would be about writing unit and integration testing for everything implemented up to now (I know it's a pain in the ...). Until then unfortunately It won't be possible to me to address any bug or add new features. Thx for the understanding.

fontIconPickers

How it works

Just include a copy of jQuery, the fontIconPickers script, the fontIconPickers theme and your Font Icons. Now you can trigger it on a SELECT or INPUT[type="text"] element.

Include the JavaScript

<!-- jQuery -->
<script type="text/javascript" src="jquery-1.7.1.min.js"></script>

<!-- fontIconPicker JS -->
<script type="text/javascript" src="jquery.fonticonpicker.min.js"></script>

Include the CSS

<!-- fontIconPicker core CSS -->
<link rel="stylesheet" type="text/css" href="jquery.fonticonpicker.min.css" />

<!-- required default theme -->
<link rel="stylesheet" type="text/css" href="themes/grey-theme/jquery.fonticonpicker.grey.min.css" />

<!-- optional themes -->
<link rel="stylesheet" type="text/css" href="themes/dark-grey-theme/jquery.fonticonpicker.darkgrey.min.css" />
<link rel="stylesheet" type="text/css" href="themes/bootstrap-theme/jquery.fonticonpicker.bootstrap.min.css" />
<link rel="stylesheet" type="text/css" href="themes/inverted-theme/jquery.fonticonpicker.inverted.min.css" />

Include Font Icons

<!-- Font -->
<link rel="stylesheet" type="text/css" href="fontello-7275ca86/css/fontello.css" />
<link rel="stylesheet" type="text/css" href="icomoon/icomoon.css" />

Initialize with jQuery

Finally call the fontIconPicker on a SELECT or INPUT[type="text"] element.

<!-- SELECT element -->
<select id="myselect" name="myselect" class="myselect">
	<option value="">No icon</option>
	<option>icon-user</option>
	<option>icon-search</option>
	<option>icon-right-dir</option>
	<option>icon-star</option>
	<option>icon-cancel</option>
	<option>icon-help-circled</option>
	<option>icon-info-circled</option>
	<option>icon-eye</option>
	<option>icon-tag</option>
	<option>icon-bookmark</option>
	<option>icon-heart</option>
	<option>icon-thumbs-down-alt</option>
	<option>icon-upload-cloud</option>
	<option>icon-phone-squared</option>
	<option>icon-cog</option>
	<option>icon-wrench</option>
	<option>icon-volume-down</option>
	<option>icon-down-dir</option>
	<option>icon-up-dir</option>
	<option>icon-left-dir</option>
	<option>icon-thumbs-up-alt</option>
</select>
<!-- JavaScript -->
<script type="text/javascript">
	// Make sure to fire only when the DOM is ready
	jQuery(document).ready(function($) {
		$('#myselect').fontIconPicker(); // Load with default options
	});
</script>
<!-- INPUT element -->
<input type="text" name="mytext" id="mytext" />
<script type="text/javascript">
	jQuery(document).ready(function($) {
		$('#mytext').fontIconPicker({
			source:    ['icon-heart', 'icon-search', 'icon-user', 'icon-tag', 'icon-help'],
			emptyIcon: false,
			hasSearch: false
		});
	});
</script>

Plugin Options

Here's fontIconPicker options:

var $picker = $('.picker').fontIconPicker({
	theme             : 'fip-grey',              // The CSS theme to use with this fontIconPicker. You can set different themes on multiple elements on the same page
	source            : false,                   // Icons source (array|false|object)
	emptyIcon         : true,                    // Empty icon should be shown?
	emptyIconValue    : '',                      // The value of the empty icon, change if you select has something else, say "none"
	iconsPerPage      : 20,                      // Number of icons per page
	hasSearch         : true,                    // Is search enabled?
	searchSource      : false,                   // Give a manual search values. If using attributes then for proper search feature we also need to pass icon names under the same order of source
	useAttribute      : false,                   // Whether to use attribute selector for printing icons
	attributeName     : 'data-icon',             // HTML Attribute name
	convertToHex      : true,                    // Whether or not to convert to hexadecimal for attribute value. If true then please pass decimal integer value to the source (or as value="" attribute of the select field)
	allCategoryText   : 'From all categories',   // The text for the select all category option
	unCategorizedText : 'Uncategorized'          // The text for the select uncategorized option
});

Plugin APIs

fontIconPicker provides three public APIs to manipulating the icon picker.

setIcons( Array|Object newIcons, Array|Object iconSearch )

Use this method to dynamically change icons on the fly. newIcons and iconSearch (optional) have same datatypes as source and searchSource options.

$picker.setIcons(['icon-one', 'icon-two']);
$picker.setIcons(['icon-one', 'icon-two'], ['Icon one will be searched by this', 'Icon two will be searched by this']);

destroyPicker()

Use this to remove the icon picker and restore the original element.

$picker.destroyPicker();

refreshPicker( Object|Boolean newOptions )

Refresh the icon picker from DOM or passed options. Useful when DOM has been changed or reinitializing after calling the destroy method or changing the options values.

$picker.refreshPicker({
	theme: 'fip-bootstrap',
	hasSearch: false
});

Options and APIs are discussed in details with live examples at the project page.

Important notes for local demo

Only when loading demo locally: In firefox fontIconPicker icons won't be shown correctly because of CORS. For the same reason "Load icons from Fontello JSON config file" won't work on Chrome or IE 10. If you need to do some local testing you can disable strict_origin_policy at your risk.

Browser Compatibility

jQuery iconPicker has been successfully tested on: Firefox (edge), Safari (edge), Chrome (edge), IE8+ and Opera (edge).

Credits

jQuery fontIconPicker has been made by me & swashata. You can contact me at [email protected] or twitter for any issue or feauture request.

I really have to thank miniMAC for the idea, Zeno Rocha for jQuery plugin boilerplate, Dave Gandy & KeyaMoon for the beautiful sets of icons and Elliot Condon for the amazing Advanced Custom Field WordPress plugin.

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