This repository has been archived by the owner on May 27, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #59 from chrishumboldt/dev-chris
Dev chris
- Loading branch information
Showing
47 changed files
with
606 additions
and
1,311 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
/** | ||
* jQuery File: buttonplate.js | ||
* Type: plugin | ||
* Author: Chris Humboldt | ||
* Last Edited: 1 October 2014 | ||
*/ | ||
|
||
|
||
// Plugin | ||
;(function($, window, document, undefined) | ||
{ | ||
// Plugin setup & settings | ||
var $plugin_name = 'buttonplate', $defaults = | ||
{ | ||
}; | ||
|
||
// The actual plugin constructor | ||
function Plugin($element, $options) | ||
{ | ||
this.element = $element; | ||
this.settings = $.extend({}, $defaults, $options); | ||
this._defaults = $defaults; | ||
this._name = $plugin_name; | ||
|
||
// Initilize plugin | ||
this.init(); | ||
} | ||
|
||
// Plugin | ||
// --------------------------------------------------------------------------------------- | ||
Plugin.prototype = | ||
{ | ||
init : function() | ||
{ | ||
// Variables | ||
// --------------------------------------------------------------------------------------- | ||
var $this = this; | ||
var $settings = $this.settings; | ||
var $button = $($this.element); | ||
|
||
|
||
// Execute | ||
// --------------------------------------------------------------------------------------- | ||
fc_button_setup(); | ||
|
||
|
||
// Functions | ||
// --------------------------------------------------------------------------------------- | ||
// Button drop size | ||
function fc_button_setup() | ||
{ | ||
if($button.find('ul').length > 0) | ||
{ | ||
$button.addClass('button-drop-down'); | ||
} | ||
}; | ||
} | ||
}; | ||
|
||
|
||
// Global calls | ||
// --------------------------------------------------------------------------------------- | ||
// On click show | ||
$(document).on('click', '.button-drop-down', function() | ||
{ | ||
var $button = $(this); | ||
var $button_w = $button.outerWidth(); | ||
|
||
// Show drop down | ||
$button.find('ul').width($button_w).fadeIn('fast', function() | ||
{ | ||
$button.addClass('button-drop-down-open'); | ||
}); | ||
}); | ||
|
||
// Close drop-downs | ||
$(document).on('click', function(){ | ||
|
||
$('.button-drop-down-open').removeClass('button-drop-down-open').find('ul').hide(); | ||
}); | ||
|
||
// On resize | ||
$(window).resize(function() | ||
{ | ||
$('.button-drop-down-open').removeClass('button-drop-down-open').find('ul').hide(); | ||
}); | ||
|
||
|
||
// Plugin wrapper | ||
// --------------------------------------------------------------------------------------- | ||
$.fn[$plugin_name] = function($options) | ||
{ | ||
var $plugin; | ||
|
||
this.each(function() | ||
{ | ||
$plugin = $.data(this, 'plugin_' + $plugin_name); | ||
|
||
if(!$plugin) | ||
{ | ||
$plugin = new Plugin(this, $options); | ||
$.data(this, 'plugin_' + $plugin_name, $plugin); | ||
} | ||
}); | ||
|
||
return $plugin; | ||
}; | ||
})(jQuery, window, document); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
0
core/js/min/web-less.min.js → core/js/min/less.min.js
100755 → 100644
File renamed without changes.
0
core/js/min/web-penplate.min.js → core/js/min/penplate.min.js
100755 → 100644
File renamed without changes.
0
core/js/min/web-touch.min.js → core/js/min/touch.min.js
100755 → 100644
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
core/js/min/web-imports.min.js → core/js/min/webplate.min.js
100755 → 100644
Large diffs are not rendered by default.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.