Skip to content

Commit

Permalink
Syncing
Browse files Browse the repository at this point in the history
  • Loading branch information
danielchatfield committed Feb 24, 2013
1 parent 76170da commit 3a70f4d
Show file tree
Hide file tree
Showing 136 changed files with 21,332 additions and 166 deletions.
6 changes: 6 additions & 0 deletions _classes/lavaPrivateBlogAccessLogsPage.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<?php
class lavaPrivateBlogAccessLogsPage extends lavaTablePage
{

}
?>
30 changes: 30 additions & 0 deletions _classes/lavaVolcanicPixelsLicensingAjax.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?php
/**
* The Volcanic Pixels licensing ajax class
*
*
* @package Lava
* @subpackage lavaVolcanicPixelsLicensingAjax
*
* @author Daniel Chatfield
* @copyright 2012
* @version 1.0.0
*/
class lavaVolcanicPixelsLicensingAjax extends lavaAjax {
public $targetAction = "licensing";

function doAjax() {
$private_key = $_REQUEST['private_key'];
$public_key = $_REQUEST['public_key'];
$this->_settings()->fetchSetting('license_public', 'vendor')->updateValue( $public_key );
$this->_settings()->fetchSetting('license_private', 'vendor')->updateValue( $private_key );

$return = array(
"status" => "complete"
);

$this->returnData( $return );
$this->doReturn();
}
}
?>
Binary file added _static/images/logout-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
126 changes: 126 additions & 0 deletions _static/scripts.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
var passwordFieldAnimationSpeed = 0;
jQuery( document ).ready( function(){
makeLabels();
jQuery('#private_blog-settings-multiple_passwords').change( function(){
if( jQuery(this).hasAttr( 'checked' ) )
{
enableMultiPass();
}
else
{
disableMultiPass();
}
}).change();
passwordFieldAnimationSpeed = 100;
});

function enableMultiPass()
{
if(passwordFieldAnimationSpeed == 0)
{
jQuery( '.setting.tag-multi-password' ).fadeIn(passwordFieldAnimationSpeed);
}
var theSetting = jQuery( '#setting-cntr_private_blog-settings-password1_value' );
var pluralName = jQuery( theSetting ).attr( 'data-name-plural' );
jQuery( theSetting ).find( ".setting-name" ).html( pluralName );

slideInAndFadePassword( theSetting );

}

function disableMultiPass()
{
if(passwordFieldAnimationSpeed == 0)
{
jQuery( '.setting.tag-multi-password' ).fadeOut(passwordFieldAnimationSpeed);
}
var theSetting = jQuery( '#setting-cntr_private_blog-settings-password1_value' );
var singleName = jQuery( theSetting ).attr( 'data-name-singular' );
jQuery( theSetting ).find( ".setting-name" ).html( singleName );

theSetting = jQuery( '#setting-cntr_private_blog-settings-password10_value' );
slideOutAndFadePassword( theSetting );
}

function slideOutAndFadePassword( selector )
{
var shortName = jQuery(selector).attr( 'data-pass-short-name' );
var labelWidth = jQuery(selector).find('.custom-password-label').width();
var newOpacity = 0;
var newOpacityRev = 1;
if( shortName == "password1")
{
newOpacity = 1;
newOpacityRev = 0;
}
jQuery(selector).find('.custom-password-label').animate({marginLeft: -(labelWidth + 10 ),opacity:newOpacityRev}, passwordFieldAnimationSpeed, function(){
jQuery(this).css({'display':'none'});

});
jQuery(selector).animate({opacity: newOpacity}, passwordFieldAnimationSpeed, function(){
var shortName = jQuery(this).attr( 'data-pass-short-name' );
if( shortName == "password1")
{
var newName = shortName.substring( 8 );
newName = parseInt(newName) - 1;
var nextInput = jQuery('#setting-cntr_private_blog-settings-password' + newName + '_value');
if( jQuery(nextInput).length > 0 )
{
slideOutAndFadePassword( jQuery(nextInput) );
}
}
else
{
jQuery(this).slideUp( passwordFieldAnimationSpeed, function(){
var shortName = jQuery(this).attr( 'data-pass-short-name' );
var newName = shortName.substring( 8 );
newName = parseInt(newName) - 1;
var nextInput = jQuery('#setting-cntr_private_blog-settings-password' + newName + '_value');
if( jQuery(nextInput).length > 0 )
{
slideOutAndFadePassword( jQuery(nextInput) );
}
});
}
});
}

function slideInAndFadePassword( selector )
{
var shortName = jQuery(selector).attr( 'data-pass-short-name' );
jQuery(selector).slideDown( passwordFieldAnimationSpeed, function(){
jQuery(this).find( '.custom-password-label' ).css({'display':'block'}).animate({marginLeft:0,opacity:1}, passwordFieldAnimationSpeed, function(){

});
jQuery(this).animate({opacity: 1}, passwordFieldAnimationSpeed, function(){
var shortName = jQuery(this).attr( 'data-pass-short-name' );
var newName = shortName.substring( 8 );
newName = parseInt(newName) + 1;
var nextInput = jQuery('#setting-cntr_private_blog-settings-password' + newName + '_value');
if( jQuery(nextInput).length > 0 )
{
slideInAndFadePassword( jQuery(nextInput) );
}
});
});
}

function makeLabels()
{
jQuery( '.setting.tag-password-label').each(function(){
var shortName = jQuery(this).attr( 'data-pass-short-name' );
var labelColor = jQuery( '#private_blog-settings-' + shortName + '_colour').val();
var labelName = jQuery( '#private_blog-settings-' + shortName + '_name').val();

jQuery(this).find( '.custom-password-label span' ).html( labelName ).css({backgroundColor: labelColor});

jQuery(this).find('.custom-password-label').click(function() {
var current = jQuery( '#private_blog-settings-' + shortName + '_name').val();
var newLabel = prompt( 'Enter password label', current );
if(newLabel != null) {
jQuery( '#private_blog-settings-' + shortName + '_name').val(newLabel);
jQuery(this).find( 'span' ).html( newLabel )
}
});
});
}
102 changes: 102 additions & 0 deletions _static/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
/* This beautiful CSS-File has been crafted with LESS (lesscss.org) and compiled by simpLESS (wearekiss.com/simpless) */
.setting.tag-multi-password {
margin-top: -10px;
}
.setting.tag-password-labels .setting-inner .custom-password-label {
float: left;
line-height: 30px;
padding: 0px 8px;
background-color: yellow;
margin-right: 10px;
border-radius: 15px;
cursor: pointer;
min-width: 14px;
text-align: center;
font-size: 16px;
color: white;
text-shadow: 0 -1px 0px #000000;
position: relative;
}
.setting.tag-password-labels .setting-inner .custom-password-label::before {
content: " ";
position: absolute;
top: 0px;
left: 0px;
right: 0px;
bottom: 0px;
z-index: 5;
border-radius: 15px;
background: -moz-linear-gradient(top, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.01) 2%, rgba(0, 0, 0, 0.14) 49%, rgba(0, 0, 0, 0.18) 51%, rgba(0, 0, 0, 0.2) 52%, rgba(0, 0, 0, 0) 100%);
/* FF3.6+ */

background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, rgba(0, 0, 0, 0)), color-stop(2%, rgba(0, 0, 0, 0.01)), color-stop(49%, rgba(0, 0, 0, 0.14)), color-stop(51%, rgba(0, 0, 0, 0.18)), color-stop(52%, rgba(0, 0, 0, 0.2)), color-stop(100%, rgba(0, 0, 0, 0)));
/* Chrome,Safari4+ */

background: -webkit-linear-gradient(top, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.01) 2%, rgba(0, 0, 0, 0.14) 49%, rgba(0, 0, 0, 0.18) 51%, rgba(0, 0, 0, 0.2) 52%, rgba(0, 0, 0, 0) 100%);
/* Chrome10+,Safari5.1+ */

background: -o-linear-gradient(top, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.01) 2%, rgba(0, 0, 0, 0.14) 49%, rgba(0, 0, 0, 0.18) 51%, rgba(0, 0, 0, 0.2) 52%, rgba(0, 0, 0, 0) 100%);
/* Opera 11.10+ */

background: -ms-linear-gradient(top, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.01) 2%, rgba(0, 0, 0, 0.14) 49%, rgba(0, 0, 0, 0.18) 51%, rgba(0, 0, 0, 0.2) 52%, rgba(0, 0, 0, 0) 100%);
/* IE10+ */

background: linear-gradient(top, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.01) 2%, rgba(0, 0, 0, 0.14) 49%, rgba(0, 0, 0, 0.18) 51%, rgba(0, 0, 0, 0.2) 52%, rgba(0, 0, 0, 0) 100%);
/* W3C */

}
.setting.tag-password-label:hover .setting-inner .custom-password-label span {
opacity: 1;
}
.setting.tag-password-label .setting-inner .custom-password-label {
float: left;
line-height: 28px;
margin-right: 10px;
text-align: center;
font-size: 16px;
color: white;
position: relative;
overflow: hidden;
}
.setting.tag-password-label .setting-inner .custom-password-label span {
-webkit-user-select: none;
text-decoration: none;
display: inline-block;
background: #40454D;
padding: 1px 5px;
text-align: center;
font-size: 14px;
text-transform: uppercase;
color: white;
margin: 0 2px;
opacity: 0.6;
-webkit-transition: all 250ms ease-in-out;
-moz-transition: all 250ms ease-in-out;
-o-transition: all 250ms ease-in-out;
transition: all 250ms ease-in-out;
cursor: pointer;
min-width: 28px;
}
.lava-table-viewer[data-data-source="access_logs"] .cell-id,
.lava-table-viewer[data-data-source="access_logs"] .cell-password,
.lava-table-viewer[data-data-source="access_logs"] .cell-password_color,
.lava-table-viewer[data-data-source="access_logs"] .cell-user_agent {
display: none;
}
.lava-table-viewer[data-data-source="access_logs"] .cell-timestamp {
text-align: center;
}
.lava-table-viewer[data-data-source="access_logs"] .cell-action.value-loginAccepted, .lava-table-viewer[data-data-source="access_logs"] .cell-action.value-doLogout, .lava-table-viewer[data-data-source="access_logs"] .cell-action.value-loginRejected {
text-align: center;
color: white;
text-shadow: 0px -1px 0px rgba(0, 0, 0, 0.5);
}
.lava-table-viewer[data-data-source="access_logs"] .cell-action.value-doLogout {
background: #69AEB4;
}
.lava-table-viewer[data-data-source="access_logs"] .cell-action.value-loginAccepted {
background-color: #7cd05b;
}
.lava-table-viewer[data-data-source="access_logs"] .cell-action.value-loginRejected {
background: red;
}
Loading

0 comments on commit 3a70f4d

Please sign in to comment.