Skip to content

Commit

Permalink
skeleton update
Browse files Browse the repository at this point in the history
  • Loading branch information
dipeshkakadiya committed May 26, 2015
1 parent a551519 commit 3eea7dc
Show file tree
Hide file tree
Showing 959 changed files with 16,880 additions and 24,660 deletions.
1 change: 0 additions & 1 deletion .gitattributes

This file was deleted.

1 change: 0 additions & 1 deletion .jshintignore

This file was deleted.

1 change: 0 additions & 1 deletion .jshintrc

This file was deleted.

1 change: 0 additions & 1 deletion .travis.yml

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
75 changes: 75 additions & 0 deletions admin/helper/class-rt-biz-text-diff.php
@@ -0,0 +1,75 @@
<?php
/**
* Don't load this file directly!
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}

if ( ! class_exists( 'Rt_Biz_Text_Diff' ) ) {

if ( ! class_exists( 'WP_Text_Diff_Renderer_Table' ) ) {
require( ABSPATH . WPINC . '/wp-diff.php' );
}

/**
* Class Rt_Biz_Text_Diff
* Email Diff text generator
*
* @since 0.1
*
* @author udit
*/
class Rt_Biz_Text_Diff extends WP_Text_Diff_Renderer_Table {

/**
* @var int
*/
var $_leading_context_lines = 2;
/**
* @var int
*/
var $_trailing_context_lines = 2;

/**
* Added Content format for Email Diff Content
*
* @since 0.1
*
* @param string $line
*
* @return string
*/
function addedLine( $line ) {
return "<td style='padding: .5em;border: 0;width:25px;'>+</td><td style='padding: .5em;border: 0;background-color: #dfd; width: auto;'>{$line}</td>";
}

/**
* Delete Content format for Email Diff Content
*
* @since 0.1
*
* @param string $line HTML-escape the value.
*
* @return string
*/
function deletedLine( $line ) {
return "<td style='padding: .5em;border: 0;width:25px;' >-</td><td style='padding: .5em;border: 0;background-color: #fdd; width: 40%;' >{$line}</td>";
}

/**
* Content format for Email Diff Content
*
* @since 0.1
*
* @param string $line HTML-escape the value.
*
* @return string
*/
function contextLine( $line ) {
return "<td style='padding: .5em;border: 0;' > </td><td style='padding: .5em;border: 0; width: auto;'>{$line}</td>";

}
}
}

0 comments on commit 3eea7dc

Please sign in to comment.