Skip to content

Commit

Permalink
Merge branch 'feature/iconpicker'
Browse files Browse the repository at this point in the history
  • Loading branch information
MickeyKay committed Jun 11, 2015
2 parents 6bfc7c7 + 33bad89 commit c804fd4
Show file tree
Hide file tree
Showing 8 changed files with 58 additions and 22 deletions.
15 changes: 6 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,24 @@ __License:__ [GPL-2.0+](http://www.gnu.org/licenses/gpl-2.0.html)
Better Font Awesome allows you to automatically integrate the latest available version of [Font Awesome](http://fontawesome.io/) into your WordPress project, along with accompanying CSS, shortcode, and TinyMCE icon shortcode generator. Furthermore, it generates all the data you need to create new functionality of your own.

## Screenshots ##
![The Better Font Awesome settings page](/../testing/assets/screenshot-1.png?raw=true)
_The Better Font Awesome settings page_
![The Better Font Awesome settings page](https://raw.githubusercontent.com/MickeyKay/better-font-awesome/master/assets/screenshot-1.gif?raw=true)
_The icon shortcode dropdown selector_

---

![The icon shortcode dropdown selector](/../testing/assets/screenshot-2.png?raw=true)
_The icon shortcode dropdown selector_
![The icon shortcode dropdown selector](https://raw.githubusercontent.com/MickeyKay/better-font-awesome/master/assets/screenshot-2.png?raw=true)
_The Better Font Awesome settings page_

## Installation ##
The Better Font Awesome plugin contains some [Git submodules](http://git-scm.com/book/en/Git-Tools-Submodules) that will require you to recursively clone this repo:
```
git clone --recursive https://github.com/MickeyKay/better-font-awesome.git
```

Alternately, if you've already cloned the repo and need to add the submodules, you can run the following commands:
Alternately, if you've already cloned the repo and need to add the submodules, you can run the following command:
```
// Initialize all submodules.
git submodule init
// Pull in updated copies of all submodules.
git submodule update
git submodule update --init --recursive
```

## The Better Font Awesome Library ##
Expand Down
20 changes: 11 additions & 9 deletions better-font-awesome.php
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
* Plugin Name: Better Font Awesome
* Plugin URI: http://wordpress.org/plugins/better-font-awesome
* Description: The ultimate Font Awesome icon plugin for WordPress.
* Version: 1.1.0
* Version: 1.3.0
* Author: MIGHTYminnow & Mickey Kay
* Author URI: [email protected]
* License: GPLv2+
Expand Down Expand Up @@ -129,13 +129,15 @@ class Better_Font_Awesome_Plugin {
*
* @return Better_Font_Awesome The BFA object.
*/
public static function get_instance( $args = '' ) {
static $instance = null;
if ( null === $instance ) {
$instance = new static( $args );
public static function get_instance( $args = array() ) {

// If the single instance hasn't been set, set it now.
if ( null == self::$instance ) {
self::$instance = new self( $args );
}

return $instance;
return self::$instance;

}

/**
Expand Down Expand Up @@ -602,9 +604,9 @@ public function get_usage_text() {
<i class="icon-coffee fa fa-coffee icon-2x fa-2x"></i> <code>[icon name="coffee" class="fa-2x"]</code> or <code>&lt;i class="fa-coffee fa-2x"&gt;&lt;/i&gt;</code><br /><br />
<i class="icon-coffee fa fa-coffee icon-2x fa-2x icon-rotate-90 fa-rotate-90"></i> <code>[icon name="coffee" class="fa-2x fa-rotate-90"]</code> or <code>&lt;i class="fa-coffee fa-2x fa-rotate-90"&gt;&lt;/i&gt;</code><br /><br /><br />
<b>Font Awesome version 3.x</b>&nbsp;&nbsp;&nbsp;<small><a href="http://fontawesome.io/3.2.1/examples/">See all available options &raquo;</a></small><br /><br />
<i class="icon-coffee fa fa-coffee"></i> <code>[icon name="coffee"]</code> or <code>&lt;i class="icon-coffee"&gt;&lt;/i&gt;</code><br /><br />
<i class="icon-coffee fa fa-coffee icon-2x fa-2x"></i> <code>[icon name="coffee" class="icon-2x"]</code> or <code>&lt;i class="icon-coffee icon-2x"&gt;&lt;/i&gt;</code><br /><br />
<i class="icon-coffee fa fa-coffee icon-2x fa-2x icon-rotate-90 fa-rotate-90"></i> <code>[icon name="coffee" class="icon-2x icon-rotate-90"]</code> or <code>&lt;i class="icon-coffee icon-2x icon-rotate-90"&gt;&lt;/i&gt;</code>',
<i class="icon-coffee fa fa-coffee"></i> <code>[icon name="coffee"]</code> or <code>&lt;i class="icon icon-coffee"&gt;&lt;/i&gt;</code><br /><br />
<i class="icon-coffee fa fa-coffee icon-2x fa-2x"></i> <code>[icon name="coffee" class="icon-2x"]</code> or <code>&lt;i class="icon icon-coffee icon-2x"&gt;&lt;/i&gt;</code><br /><br />
<i class="icon-coffee fa fa-coffee icon-2x fa-2x icon-rotate-90 fa-rotate-90"></i> <code>[icon name="coffee" class="icon-2x icon-rotate-90"]</code> or <code>&lt;i class="icon icon-coffee icon-2x icon-rotate-90"&gt;&lt;/i&gt;</code>',
'better-font-awesome' ) .
'</div>';
}
Expand Down
16 changes: 16 additions & 0 deletions css/admin.css
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,19 @@
margin: 0;
}

.bfa-usage-text {
padding: 20px;
background-color: #fff;
border: 1px solid #efefef;
}

.bfa-usage-text h3 {
margin-top: 0;
}

.bfa-usage-text .fa,
.bfa-usage-text .icon {
width: 40px;
text-align: center;
box-sizing: border-box;
}
Empty file modified js/admin.js
100644 → 100755
Empty file.
Empty file modified languages/better-font-awesome-fr_FR.mo
100644 → 100755
Empty file.
Empty file modified languages/better-font-awesome-fr_FR.po
100644 → 100755
Empty file.
Empty file modified languages/better-font-awesome.pot
100644 → 100755
Empty file.
29 changes: 25 additions & 4 deletions readme.txt
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: better, font, awesome, icon, icons, bootstrap, fontstrap, cdn, shortcode
Donate link: http://mightyminnow.com
Requires at least: 3.0
Tested up to: 4.3
Stable tag: 1.1.0
Stable tag: 1.3.0
License: GPLv2+
License URI: http://www.gnu.org/licenses/gpl-2.0.html

Expand Down Expand Up @@ -101,13 +101,23 @@ Better Font Awesome does it's best to load after any existing Font Awesome CSS,


== Screenshots ==

1. Better Font Awesome settings, accessed via Settings &rarr; Better Font Awesome
2. Using Better Font Awesome via TinyMCE
1. The icon shortcode dropdown selector
2. Better Font Awesome settings, accessed via Settings &rarr; Better Font Awesome


== Changelog ==

= 1.3.0 =
* Replace outdated TinyMCE shortcode selector brand new jQuery dropdown selector that works in both the visual and text editor
* Clean up CSS and JS

= 1.2.1 =
* Update get_instance() call to work for older versions of PHP (< 5.3)

= 1.2.0 =
* Attach load functionality to after_theme_setup hook to allow themes to filter options
* Update fallback Font Awesome to version 4.3.0

= 1.1.0 =
* Implement Ajax to save plugin settings (thanks [Braad](https://profiles.wordpress.org/braad))

Expand Down Expand Up @@ -181,6 +191,17 @@ Better Font Awesome does it's best to load after any existing Font Awesome CSS,

== Upgrade Notice ==

= 1.3.0 =
* Replace outdated TinyMCE shortcode selector brand new jQuery dropdown selector that works in both the visual and text editor
* Clean up CSS and JS

= 1.2.1 =
* Update get_instance() call to work for older versions of PHP (< 5.3)

= 1.2.0 =
* Attach load functionality to after_theme_setup hook to allow themes to filter options
* Update fallback Font Awesome to version 4.3.0

= 1.1.0 =
* Implement Ajax to save plugin settings (thanks [Braad](https://profiles.wordpress.org/braad))

Expand Down

0 comments on commit c804fd4

Please sign in to comment.