Skip to content
This repository has been archived by the owner on Jun 5, 2020. It is now read-only.

adresses many open PRs and Issues #68

Merged
merged 8 commits into from
Mar 28, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ Thumbs.db
/ignore/
/ignored/
/node_modules/
/bower_components/
/nbproject/
static_server.js
*.php
.idea/
prod/
.icons.temp
/bower_components/
.icons.temp
4 changes: 4 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
extension
*.psd
composer.json
.travis.yml
8 changes: 6 additions & 2 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,12 @@ module.exports = function(grunt) {
distMin: {
options: {
compress: {},
beautify: false
beautify: false,
preserveComments: 'some'
},
files: {
'dist/js/fontawesome-iconpicker.min.js': [
'src/js/license.js',
'src/js/jquery.ui.pos.js',
parsedIconPicker
]
Expand All @@ -113,10 +115,12 @@ module.exports = function(grunt) {
dist: {
options: {
compress: false,
beautify: true
beautify: true,
preserveComments: 'some'
},
files: {
'dist/js/fontawesome-iconpicker.js': [
'src/js/license.js',
'src/js/jquery.ui.pos.js',
parsedIconPicker
]
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Here are all the possibilities in detail:
## Available options

```javascript
var defaults = {
var options = {
title: false, // Popover title (optional) only if specified in the template
selected: false, // use this value as the current item and ignore the original
defaultValue: false, // use this value as the current item if input or element value is empty
Expand All @@ -102,7 +102,7 @@ var defaults = {
searchInFooter: false, // If true, the search will be added to the footer instead of the title
mustAccept: false, // only applicable when there's an iconpicker-btn-accept button in the popover footer
selectedCustomClass: 'bg-primary', // Appends this class when to the selected item
icons: [], // list of icon classes (declared at the bottom of this script for maintainability)
icons: [], // list of icon objects [{title:String, searchTerms:String}]. By default, all Font Awesome icons are included.
fullClassFormatter: function(val) {
return 'fa ' + val;
},
Expand Down
21 changes: 0 additions & 21 deletions bower.json

This file was deleted.

20 changes: 1 addition & 19 deletions dist/css/fontawesome-iconpicker.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,6 @@
* https://github.com/farbelous/fontawesome-iconpicker/blob/master/LICENSE
*
*/
/*
* Font Awesome Icon Picker
* https://farbelous.github.io/fontawesome-iconpicker/
*
* Originally written by (c) 2016 Javi Aguilar
* Licensed under the MIT License
* https://github.com/farbelous/fontawesome-iconpicker/blob/master/LICENSE
*
*/
/*
* Font Awesome Icon Picker
* https://farbelous.github.io/fontawesome-iconpicker/
*
* Originally written by (c) 2016 Javi Aguilar
* Licensed under the MIT License
* https://github.com/farbelous/fontawesome-iconpicker/blob/master/LICENSE
*
*/
.iconpicker-popover.popover {
position: absolute;
top: 0;
Expand All @@ -33,7 +15,7 @@
max-width: none;
padding: 1px;
text-align: left;
width: 216px;
width: 234px;
background: #f7f7f7;
z-index: 9;
}
Expand Down
2 changes: 1 addition & 1 deletion dist/css/fontawesome-iconpicker.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 19 additions & 8 deletions dist/js/fontawesome-iconpicker.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
/*!
* Font Awesome Icon Picker
* https://farbelous.github.io/fontawesome-iconpicker/
*
* Originally written by (c) 2016 Javi Aguilar
* Licensed under the MIT License
* https://github.com/farbelous/fontawesome-iconpicker/blob/master/LICENSE
*
*/
(function(a) {
if (typeof define === "function" && define.amd) {
define([ "jquery" ], a);
Expand All @@ -7,6 +16,16 @@
})(function(a) {
a.ui = a.ui || {};
var b = a.ui.version = "1.12.1";
/*!
* jQuery UI Position 1.12.1
* http://jqueryui.com
*
* Copyright jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*
* http://api.jqueryui.com/position/
*/
(function() {
var b, c = Math.max, d = Math.abs, e = /left|center|right/, f = /top|center|bottom/, g = /[\+\-]\d+(\.[\d]+)?%?/, h = /^\w+/, i = /%$/, j = a.fn.pos;
function k(a, b, c) {
Expand Down Expand Up @@ -401,8 +420,6 @@
}
this.container.addClass("iconpicker-container");
if (this.isDropdownMenu()) {
this.options.templates.search = false;
this.options.templates.buttons = false;
this.options.placement = "inline";
}
this.input = this.element.is("input,textarea") ? this.element.addClass("iconpicker-input") : false;
Expand Down Expand Up @@ -536,8 +553,6 @@
if (b.options.hideOnSelect && b.options.mustAccept === false) {
b.hide();
}
c.preventDefault();
return false;
};
for (var d in this.options.icons) {
if (typeof this.options.icons[d].title === "string") {
Expand Down Expand Up @@ -621,12 +636,8 @@
if (!c._isEventInsideIconpicker(a) && !c.isInline()) {
c.hide();
}
a.stopPropagation();
a.preventDefault();
return false;
});
}
return false;
},
_unbindElementEvents: function() {
this.popover.off(".iconpicker");
Expand Down
21 changes: 20 additions & 1 deletion dist/js/fontawesome-iconpicker.min.js

Large diffs are not rendered by default.

Loading