Revert equation examples

This commit is contained in:
Brian Miyaji
2016-09-09 14:14:58 +10:00
parent 0302eb25f2
commit 1da48e5acf
5 changed files with 0 additions and 124 deletions

View File

@@ -74,10 +74,3 @@
.sp-equation-formula .button .remove:hover {
color: #d00;
}
.sp-equation-examples .button {
color: #555 !important;
border-color: #ccc !important;
-webkit-box-shadow: 0 1px 0 #ccc !important;
box-shadow: 0 1px 0 #ccc !important;
}

View File

@@ -76,13 +76,6 @@ class SP_Admin_Meta_Boxes {
'context' => 'normal',
'priority' => 'high',
),
'examples' => array(
'title' => __( 'Examples', 'sportspress' ),
'save' => 'SP_Meta_Box_Column_Equation_Examples::save',
'output' => 'SP_Meta_Box_Column_Equation_Examples::output',
'context' => 'normal',
'priority' => 'low',
),
),
'sp_metric' => array(
'details' => array(
@@ -108,13 +101,6 @@ class SP_Admin_Meta_Boxes {
'context' => 'normal',
'priority' => 'high',
),
'examples' => array(
'title' => __( 'Examples', 'sportspress' ),
'save' => 'SP_Meta_Box_Statistic_Equation_Examples::save',
'output' => 'SP_Meta_Box_Statistic_Equation_Examples::output',
'context' => 'normal',
'priority' => 'low',
),
),
'sp_event' => array(
'shortcode' => array(

View File

@@ -1,37 +0,0 @@
<?php
/**
* Column Equation Examples
*
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Meta_Boxes
* @version 1.9
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
if ( ! class_exists( 'SP_Meta_Box_Equation_Examples' ) )
include( 'class-sp-meta-box-equation-examples.php' );
/**
* SP_Meta_Box_Column_Equation_Examples
*/
class SP_Meta_Box_Column_Equation_Examples extends SP_Meta_Box_Equation_Examples {
/**
* Output the metabox
*/
public static function output( $post ) {
$equations = array(
'Games Played' => 'Played',
'Pts' => 'Win &times; 3 + Draw',
'Win %' => 'Win &divide; Played',
'Diff' => 'Points&nbsp;(for) - Points&nbsp;(against)',
'GB' => 'Games&nbsp;Back',
'Home Goals' => 'Goals&nbsp;(for) @Home',
'Strk' => 'Streak',
'L10' => 'Last&nbsp;10',
);
self::examples( $equations );
}
}

View File

@@ -1,31 +0,0 @@
<?php
/**
* Equation examples meta box functions
*
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Meta_Boxes
* @version 1.9.19
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
/**
* SP_Meta_Box_Equation_Examples
*/
class SP_Meta_Box_Equation_Examples {
public static function examples( $equations = array() ) {
?>
<ul class="sp-equation-examples">
<?php foreach ( $equations as $label => $equation ): $parts = explode( ' ', $equation ); ?>
<p>
<strong><?php echo $label; ?> =</strong>
<?php foreach ( $parts as $part ): ?>
<span class="button button-disabled"><?php echo $part; ?></span>
<?php endforeach; ?>
</p>
<?php endforeach; ?>
</div>
<?php
}
}

View File

@@ -1,35 +0,0 @@
<?php
/**
* Statistic Equation Examples
*
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Meta_Boxes
* @version 1.9
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
if ( ! class_exists( 'SP_Meta_Box_Equation_Examples' ) )
include( 'class-sp-meta-box-equation-examples.php' );
/**
* SP_Meta_Box_Statistic_Equation_Examples
*/
class SP_Meta_Box_Statistic_Equation_Examples extends SP_Meta_Box_Equation_Examples {
/**
* Output the metabox
*/
public static function output( $post ) {
$equations = array(
'Appearances' => 'Played',
'Win Ratio' => '( Win &divide; Played ) &times; 100',
'Batting Avg' => 'Hits &divide; At&nbsp;Bats',
'Minutes / Game' => 'Min &divide; Played',
'Goal %' => 'Goals &divide; Attempts',
'Blocks / Set' => 'Blocks &divide; Sets',
);
self::examples( $equations );
}
}