diff --git a/admin/css/lbry-admin.css b/admin/css/lbry-admin.css index 7763519..a0d2dce 100644 --- a/admin/css/lbry-admin.css +++ b/admin/css/lbry-admin.css @@ -61,10 +61,10 @@ margin-right: 1em; } .post-lbry-display-before { - color: darkgreen; + color: green; } .post-lbry-display { - color: green; + color: #135548; } .lbry-pub-metabox { @@ -86,38 +86,36 @@ .lbry-meta-bx-content-last { padding: .2em .8em 1em .1em; } - +/*--------------------- + Channels Table + -------------------*/ table.lbry-channel-table { width: 100%; border-collapse: collapse; font-family: Georgia; } - .lbry-channel-table th, .lbry-channel-table td { padding: .4em 1.6em; border: 2px solid #fff; - background: #fbd7b4; + background: #97eb9d; font-size: 1em; } .lbry-channel-table thead th { padding: .5em 2em; - background: #f69546; + background: #135548; text-align: left; font-weight: normal; font-size: 1.2em; color: #fff; } -.lbry-channel-table tbody tr:nth-child(odd) *:nth-child(even), .lbry-channel-table tbody tr:nth-child(even) *:nth-child(odd) { - background: #f3eddd; +.lbry-channel-table tbody tr:nth-child(odd) td { + background: #e1fafa; } .lbry-channel-table tfoot th { - padding: .5em 2em; - background: #f69546; + padding: .5em 1.8em; + background: #175248; text-align: left; font-weight: normal; font-size: .9em; color: #fff; } -.lbry-channel-table tr *:nth-child(3), .lbry-channel-table tr *:nth-child(4) { - /* text-align: right; */ -} \ No newline at end of file diff --git a/admin/js/table-sort.js b/admin/js/table-sort.js index 7912668..d418778 100644 --- a/admin/js/table-sort.js +++ b/admin/js/table-sort.js @@ -1,8 +1,8 @@ jQuery(document).ready(function($) { var compare = { - name: function(a, b) { - a = a.replace(/^@/, '') && a.replace(/-/g, ''); - b = b.replace(/^@/, '') && b.replace(/-/g, ''); + channel: function(a, b) { + a = a.replace(/^@/i, '') && a.replace(/[-]/gi, ''); + b = b.replace(/^@/i, '') && b.replace(/[-]/gi, ''); if (a < b) { return -1; @@ -20,16 +20,23 @@ jQuery(document).ready(function($) { return a > b ? 1 : 0; } }, - amount: function(a, b) { - a = a.split('.'); - b = b.split('.'); - - a = Number(a[0]) + Number(a[1]); - b = Number(b[0]) + Number(b[1]); + claim: function(a, b) { + if (a < b) { + return -1; + } else { + return a > b ? 1 : 0; + } + }, + posts: function(a, b) { + a = Number(a); + b = Number(b); return a - b; }, - number: function(a, b) { + support: function(a, b) { + a = a.replace(/,/g, ''); + b = b.replace(/,/g, ''); + a = Number(a); b = Number(b); diff --git a/classes/LBRY_Admin.php b/classes/LBRY_Admin.php index 3371f38..575be85 100644 --- a/classes/LBRY_Admin.php +++ b/classes/LBRY_Admin.php @@ -52,7 +52,7 @@ class LBRY_Admin } add_action( 'admin_enqueue_scripts', 'load_admin_stylesheet' ); - // Admin JS enqueue + // Admin channel sort JS enqueue function load_admin_script() { if ( ( $_GET['page'] == 'lbrypress') && ( $_GET['tab'] == 'channels' ) ) { wp_enqueue_script( @@ -272,10 +272,12 @@ class LBRY_Admin - + - - + + + + @@ -286,6 +288,8 @@ class LBRY_Admin if ( $lbry_url ) { $open_url = str_replace( 'lbry://', 'open.lbry.com/', $lbry_url ); } + $timestamp = $results->items[0]->meta->creation_timestamp; + $created_date = date( 'm-d-y', $timestamp ); $support_amount = $results->items[0]->meta->support_amount; $claims_published = $results->items[0]->meta->claims_in_channel; if ( ( $support_amount < 0.001 ) ) { @@ -303,14 +307,16 @@ class LBRY_Admin + + - + - +
ChannelChannel LBRY URLPostsSupportsClaim ID~ Date CreatedPostsSupports
name, 'lbrypress' ); ?> AddAdd
LBRYPress
LBRYPress