Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Publicious.org
Plugins
Pretty Filters
Commits
cde922fa
Commit
cde922fa
authored
Nov 18, 2015
by
John James Jacoby
Browse files
First pass at pretty comment filters.
parent
0af5d0d2
Changes
3
Hide whitespace changes
Inline
Side-by-side
assets/js/pretty-filters.js
View file @
cde922fa
...
...
@@ -2,12 +2,21 @@ jQuery( document ).ready( function( $ ) {
'
use strict
'
;
// Get the filters
var
toptablenav
=
$
(
'
#posts-filter .tablenav.top
'
),
filters
=
toptablenav
.
find
(
'
.actions:not(.bulkactions)
'
);
var
toptablenav
=
$
(
'
#posts-filter .tablenav.top
'
);
// Add a class for custom styling
filters
.
addClass
(
'
wp-pretty-filters
'
);
// Maybe try comments
if
(
'
undefined
'
===
typeof
(
toptablenav
)
)
{
toptablenav
=
$
(
'
#commentsform .tablenav.top
'
);
}
// Relocate
toptablenav
.
before
(
filters
);
// Only proceed if toptablenav was found
if
(
'
undefined
'
!==
typeof
(
toptablenav
)
)
{
var
filters
=
toptablenav
.
find
(
'
.actions:not(.bulkactions)
'
);
// Add a class for custom styling
filters
.
addClass
(
'
wp-pretty-filters
'
);
// Relocate
toptablenav
.
before
(
filters
);
}
}
);
readme.txt
View file @
cde922fa
=== WP Pretty Filters ===
Contributors: johnjamesjacoby, stuttter
Tags: jquery, filter, select,
chosen
Tags: jquery, filter, select,
filters
Requires at least: 4.3
Tested up to: 4.4
Stable tag: 0.1.
0
Stable tag: 0.1.
1
Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9Q4F4EL5YJ62J
== Description ==
...
...
@@ -13,6 +13,7 @@ WP Pretty Filters makes post filters better match what's already in Media & Atta
= Also checkout =
* [WP Chosen](https://wordpress.org/plugins/wp-chosen/ "Make long, unwieldy select boxes much more user-friendly.")
* [WP Reset Filters](https://wordpress.org/plugins/wp-reset-filters/ "Adds a 'Reset' button to filters.")
* [WP Event Calendar](https://wordpress.org/plugins/wp-event-calendar/ "The best way to manage events in WordPress.")
* [WP Term Meta](https://wordpress.org/plugins/wp-term-meta/ "Metadata, for taxonomy terms.")
* [WP Term Order](https://wordpress.org/plugins/wp-term-order/ "Sort taxonomy terms, your way.")
...
...
@@ -56,5 +57,8 @@ http://github.com/stuttter/wp-pretty-filters/
== Changelog ==
= 0.1.1 =
* Support for Comments
= 0.1.0 =
* Initial release
wp-pretty-filters.php
View file @
cde922fa
...
...
@@ -5,7 +5,7 @@
* Plugin URI: http://wordpress.org/extend/plugins/wp-pretty-filters/
* Author: John James Jacoby
* Author URI: http://jjj.me
* Version: 0.1.
0
* Version: 0.1.
1
* Description: Makes post filters match Media & Attachments
* License: GPLv2 or later
*/
...
...
@@ -46,5 +46,5 @@ function wp_pretty_filters_get_plugin_url() {
* @return int
*/
function
wp_pretty_filters_get_asset_version
()
{
return
201511
05
000
3
;
return
201511
18
000
1
;
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment