Compare commits

17 Commits

Author SHA1 Message Date
Arnold Daniels
10b81be776 Fixed incorrect version number specified for required Twitter Bootstrap 2014-04-19 19:05:33 +02:00
Arnold Daniels
e822b1b3bf Build v3.1.2 2014-04-19 18:25:38 +02:00
Arnold Daniels
285689081d Use window.jQuery in transition.js 2014-04-19 16:43:27 +02:00
Arnold Daniels
1001ad214d Fixed broken rowlink caused by check on .rowlink-skip. Fixed #221
Thanks @cervengoc
2014-04-19 16:42:25 +02:00
Arnold Daniels
249cb84f6b Updated npm packages 2014-04-19 16:38:06 +02:00
Arnold Daniels
660e376b96 Replace grunt-sed with grunt-text-replace
Set version to 3.1.2
2014-04-19 16:31:53 +02:00
Arnold Daniels
e919330916 Added transitions support check. Fixes #213
This is required to run Jasny Bootrstap standalone.
2014-04-19 16:09:41 +02:00
Arnold Daniels
24f8bffbaf Offcanvas option disablescrolling (lowercase) as alias of disableScrolling (camel cased). Fixes #219 2014-04-19 15:15:46 +02:00
Arnold Daniels
e5b9930599 Don't trigger fileinput.change when fileinput.clear is called manually. Fixes #216
Insert fileinput <input type="hidden"> right before <input type="file">. Fixes #215
Clean up less and scss comment
2014-04-19 15:10:23 +02:00
Arnold Daniels
8fd9aca993 Updated scss for earlier changes
- Move mixins taken from Twitter Bootstrap to build dir.
 - Removed the transformation for file input altogether.
2014-04-16 14:32:12 +02:00
Arnold Daniels
0038dd8c9f Merge origin/master 2014-04-16 13:37:21 +02:00
Arnold Daniels
27794ba4e3 Removed the transformation for file input al together. Should test of this works correctly for IE and Opera. 2014-04-16 13:37:08 +02:00
Arnold Daniels
9e28a9b2bc Move mixins taken from Twitter Bootstrap to build dir. Fixed #221
Move button-label mixin to button-labels.less.
2014-04-13 16:36:59 +02:00
Arnold Daniels
18116c5cd3 Merge pull request #218 from joshjb84/master
Fix to naming in inputmask.js and added some inputmask tests
2014-04-06 22:10:54 +02:00
joshjb84
2336197e3a Fix to naming in inputmask.js and tests
Changed the name of Input.DEFAULS to Input.DEFAULTS and added unit tests
around how the options are set up.
2014-04-05 19:10:24 +08:00
Arnold Daniels
ee5a80a6c3 Merge pull request #208 from inbep/master
adding scss files
2014-03-30 14:15:56 +02:00
Sergio
4dc46204b4 adding scss files 2014-03-28 12:40:26 -03:00
42 changed files with 1010 additions and 107 deletions

View File

@@ -1,8 +1,8 @@
/*!
* Bootstrap's Gruntfile
* http://getbootstrap.com
* Copyright 2013-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Jasny Bootstrap's Gruntfile
* http://jasny.github.io/bootstrap
* Copyright 2013-2014 Arnold Daniels.
* Licensed under Apache License 2.0 (https://github.com/jasny/bootstrap/blob/master/LICENSE)
*/
module.exports = function (grunt) {
@@ -98,6 +98,7 @@ module.exports = function (grunt) {
},
bootstrap: {
src: [
'js/transition.js',
'js/offcanvas.js',
'js/rowlink.js',
'js/inputmask.js',
@@ -298,14 +299,14 @@ module.exports = function (grunt) {
}
},
sed: {
replace: {
versionNumber: {
pattern: (function () {
var old = grunt.option('oldver');
return old ? RegExp.quote(old) : old;
})(),
replacement: grunt.option('newver'),
recursive: true
src: ['*.js', '*.md', '*.json', '*.yml', 'js/*.js'],
overwrite: true,
replacements: [{
from: grunt.option('oldver'),
to: grunt.option('newver')
}]
}
},
@@ -377,7 +378,7 @@ module.exports = function (grunt) {
// Version numbering task.
// grunt change-version-number --oldver=A.B.C --newver=X.Y.Z
// This can be overzealous, so its changes should always be manually reviewed!
grunt.registerTask('change-version-number', 'sed');
grunt.registerTask('change-version-number', 'replace');
// task for building customizer
grunt.registerTask('build-customizer', ['build-customizer-html', 'build-raw-files']);

View File

@@ -19,13 +19,13 @@ exclude:
- "vendor"
# Custom vars
current_version: 3.1.1
current_version: 3.1.2
repo: https://github.com/jasny/bootstrap
download:
source: https://github.com/jasny/bootstrap/archive/v3.1.1.zip
dist: https://github.com/jasny/bootstrap/releases/download/v3.1.1/jasny-bootstrap-3.1.1-dist.zip
source: https://github.com/jasny/bootstrap/archive/v3.1.2.zip
dist: https://github.com/jasny/bootstrap/releases/download/v3.1.2/jasny-bootstrap-3.1.2-dist.zip
cdn:
css: //cdnjs.cloudflare.com/ajax/libs/jasny-bootstrap/3.1.1/css/jasny-bootstrap.min.css
js: //cdnjs.cloudflare.com/ajax/libs/jasny-bootstrap/3.1.1/js/jasny-bootstrap.min.js
css: //cdnjs.cloudflare.com/ajax/libs/jasny-bootstrap/3.1.2/css/jasny-bootstrap.min.css
js: //cdnjs.cloudflare.com/ajax/libs/jasny-bootstrap/3.1.2/js/jasny-bootstrap.min.js

View File

@@ -1,6 +1,6 @@
{
"name": "jasny-bootstrap",
"version": "3.1.1",
"version": "3.1.2",
"main": [
"./dist/css/jasny-bootstrap.css",
"./dist/js/jasny-bootstrap.js"
@@ -16,6 +16,6 @@
],
"dependencies": {
"jquery": ">= 1.9.0",
"bootstrap": ">= 3.0.0"
"bootstrap": ">= 3.1.0"
}
}

View File

@@ -14,6 +14,6 @@
}
, "license": "Apache-2.0"
, "require": {
"twitter/bootstrap" : ">=3.0.0"
"twitter/bootstrap" : ">=3.1.0"
}
}

View File

@@ -1,5 +1,5 @@
/*!
* Jasny Bootstrap v3.1.1 (http://jasny.github.io/bootstrap)
* Jasny Bootstrap v3.1.2 (http://jasny.github.io/bootstrap)
* Copyright 2012-2014 Arnold Daniels
* Licensed under Apache-2.0 (https://github.com/jasny/bootstrap/blob/master/LICENSE)
*/
@@ -530,16 +530,9 @@
cursor: pointer;
filter: alpha(opacity=0);
opacity: 0;
-webkit-transform: translate(-300px, 0) scale(4);
transform: translate(-300px, 0) scale(4);
direction: ltr;
}
@-moz-document url-prefix() {
.btn-file > input {
transform: none;
}
}
.fileinput {
display: inline-block;
margin-bottom: 9px;
@@ -583,6 +576,13 @@
.fileinput.input-group {
display: table;
}
.fileinput.input-group > * {
position: relative;
z-index: 2;
}
.fileinput.input-group > .btn-file {
z-index: 1;
}
.fileinput-new.input-group .btn-file,
.fileinput-new .input-group .btn-file {
border-radius: 0 4px 4px 0;

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,5 +1,5 @@
/*!
* Jasny Bootstrap v3.1.1 (http://jasny.github.io/bootstrap)
* Jasny Bootstrap v3.1.2 (http://jasny.github.io/bootstrap)
* Copyright 2012-2014 Arnold Daniels
* Licensed under Apache-2.0 (https://github.com/jasny/bootstrap/blob/master/LICENSE)
*/
@@ -7,7 +7,58 @@
if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScript requires jQuery') }
/* ========================================================================
* Bootstrap: offcanvas.js v3.1.1
* Bootstrap: transition.js v3.1.2
* http://getbootstrap.com/javascript/#transitions
* ========================================================================
* Copyright 2011-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
+function ($) {
'use strict';
// CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
// ============================================================
function transitionEnd() {
var el = document.createElement('bootstrap')
var transEndEventNames = {
WebkitTransition : 'webkitTransitionEnd',
MozTransition : 'transitionend',
OTransition : 'oTransitionEnd otransitionend',
transition : 'transitionend'
}
for (var name in transEndEventNames) {
if (el.style[name] !== undefined) {
return { end: transEndEventNames[name] }
}
}
return false // explicit for ie8 ( ._.)
}
if ($.support.transition !== undefined) return // Prevent conflict with Twitter Bootstrap
// http://blog.alexmaccaw.com/css-transitions
$.fn.emulateTransitionEnd = function (duration) {
var called = false, $el = this
$(this).one($.support.transition.end, function () { called = true })
var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
setTimeout(callback, duration)
return this
}
$(function () {
$.support.transition = transitionEnd()
})
}(window.jQuery);
/* ========================================================================
* Bootstrap: offcanvas.js v3.1.2
* http://jasny.github.io/bootstrap/javascript/#offcanvas
* ========================================================================
* Copyright 2013-2014 Arnold Daniels
@@ -45,6 +96,11 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
$(document).on('click', $.proxy(this.autohide, this))
if (this.options.toggle) this.toggle()
if (this.options.disablescrolling) {
this.options.disableScrolling = this.options.disablescrolling
delete this.options.disablescrolling
}
}
OffCanvas.DEFAULTS = {
@@ -319,7 +375,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
}(window.jQuery);
/* ============================================================
* Bootstrap: rowlink.js v3.1.1
* Bootstrap: rowlink.js v3.1.2
* http://jasny.github.io/bootstrap/javascript/#rowlink
* ============================================================
* Copyright 2012-2014 Arnold Daniels
@@ -395,7 +451,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
// ==================
$(document).on('click.bs.rowlink.data-api', '[data-link="row"]', function (e) {
if ($(e.target).closest('.rowlink-skip')) return
if ($(e.target).closest('.rowlink-skip').length !== 0) return
var $this = $(this)
if ($this.data('rowlink')) return
@@ -439,7 +495,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
if (isAndroid) return // No support because caret positioning doesn't work on Android
this.$element = $(element)
this.options = $.extend({}, Inputmask.DEFAULS, options)
this.options = $.extend({}, Inputmask.DEFAULTS, options)
this.mask = String(this.options.mask)
this.init()
@@ -448,7 +504,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
this.checkVal() //Perform initial check for existing values
}
Inputmask.DEFAULS = {
Inputmask.DEFAULTS = {
mask: "",
placeholder: "_",
definitions: {
@@ -767,7 +823,7 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
}(window.jQuery);
/* ===========================================================
* Bootstrap: fileinput.js v3.1.1
* Bootstrap: fileinput.js v3.1.2
* http://jasny.github.com/bootstrap/javascript/#fileinput
* ===========================================================
* Copyright 2012-2014 Arnold Daniels
@@ -802,14 +858,15 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
this.$hidden = this.$element.find('input[type=hidden][name="' + this.name + '"]')
if (this.$hidden.length === 0) {
this.$hidden = $('<input type="hidden" />')
this.$element.prepend(this.$hidden)
this.$hidden = $('<input type="hidden">').insertBefore(this.$input)
}
this.$preview = this.$element.find('.fileinput-preview')
var height = this.$preview.css('height')
if (this.$preview.css('display') != 'inline' && height != '0px' && height != 'none') this.$preview.css('line-height', height)
if (this.$preview.css('display') !== 'inline' && height !== '0px' && height !== 'none') {
this.$preview.css('line-height', height)
}
this.original = {
exists: this.$element.hasClass('fileinput-exists'),
preview: this.$preview.html(),
@@ -896,14 +953,14 @@ if (typeof jQuery === 'undefined') { throw new Error('Jasny Bootstrap\'s JavaScr
this.$element.find('.fileinput-filename').text('')
this.$element.addClass('fileinput-new').removeClass('fileinput-exists')
if (e !== false) {
if (e !== undefined) {
this.$input.trigger('change')
this.$element.trigger('clear.bs.fileinput')
}
},
Fileinput.prototype.reset = function() {
this.clear(false)
this.clear()
this.$hidden.val(this.original.hiddenVal)
this.$preview.html(this.original.preview)

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -123,6 +123,12 @@ base_url: "../"
Off canvas
</label>
</div>
<div class="checkbox">
<label>
<input type="checkbox" checked value="transition.js">
Transitions <small>(required for any kind of animation)</small>
</label>
</div>
</div>
</div>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -60,7 +60,7 @@ $.fn.bootstrapBtn = bootstrapButton // give $().bootstrapBtn the Boot
<h3 id="js-events">Events</h3>
<p>Bootstrap provides custom events for most plugin's unique actions. Generally, these come in an infinitive and past participle form - where the infinitive (ex. <code>show</code>) is triggered at the start of an event, and its past participle form (ex. <code>shown</code>) is trigger on the completion of an action.</p>
<p>As of 3.0.0, all Bootstrap events are namespaced.</p>
<p>As of 3.1.2, all Bootstrap events are namespaced.</p>
<p>All infinitive events provide <code>preventDefault</code> functionality. This provides the ability to stop the execution of an action before it starts.</p>
{% highlight js %}
$('#myMenu').on('show.bs.offcanvas', function (e) {

View File

@@ -1,5 +1,5 @@
/* ===========================================================
* Bootstrap: fileinput.js v3.1.1
* Bootstrap: fileinput.js v3.1.2
* http://jasny.github.com/bootstrap/javascript/#fileinput
* ===========================================================
* Copyright 2012-2014 Arnold Daniels
@@ -34,14 +34,15 @@
this.$hidden = this.$element.find('input[type=hidden][name="' + this.name + '"]')
if (this.$hidden.length === 0) {
this.$hidden = $('<input type="hidden" />')
this.$element.prepend(this.$hidden)
this.$hidden = $('<input type="hidden">').insertBefore(this.$input)
}
this.$preview = this.$element.find('.fileinput-preview')
var height = this.$preview.css('height')
if (this.$preview.css('display') != 'inline' && height != '0px' && height != 'none') this.$preview.css('line-height', height)
if (this.$preview.css('display') !== 'inline' && height !== '0px' && height !== 'none') {
this.$preview.css('line-height', height)
}
this.original = {
exists: this.$element.hasClass('fileinput-exists'),
preview: this.$preview.html(),
@@ -128,14 +129,14 @@
this.$element.find('.fileinput-filename').text('')
this.$element.addClass('fileinput-new').removeClass('fileinput-exists')
if (e !== false) {
if (e !== undefined) {
this.$input.trigger('change')
this.$element.trigger('clear.bs.fileinput')
}
},
Fileinput.prototype.reset = function() {
this.clear(false)
this.clear()
this.$hidden.val(this.original.hiddenVal)
this.$preview.html(this.original.preview)

View File

@@ -32,7 +32,7 @@
if (isAndroid) return // No support because caret positioning doesn't work on Android
this.$element = $(element)
this.options = $.extend({}, Inputmask.DEFAULS, options)
this.options = $.extend({}, Inputmask.DEFAULTS, options)
this.mask = String(this.options.mask)
this.init()
@@ -41,7 +41,7 @@
this.checkVal() //Perform initial check for existing values
}
Inputmask.DEFAULS = {
Inputmask.DEFAULTS = {
mask: "",
placeholder: "_",
definitions: {

View File

@@ -1,5 +1,5 @@
/* ========================================================================
* Bootstrap: offcanvas.js v3.1.1
* Bootstrap: offcanvas.js v3.1.2
* http://jasny.github.io/bootstrap/javascript/#offcanvas
* ========================================================================
* Copyright 2013-2014 Arnold Daniels
@@ -37,6 +37,11 @@
$(document).on('click', $.proxy(this.autohide, this))
if (this.options.toggle) this.toggle()
if (this.options.disablescrolling) {
this.options.disableScrolling = this.options.disablescrolling
delete this.options.disablescrolling
}
}
OffCanvas.DEFAULTS = {

View File

@@ -1,5 +1,5 @@
/* ============================================================
* Bootstrap: rowlink.js v3.1.1
* Bootstrap: rowlink.js v3.1.2
* http://jasny.github.io/bootstrap/javascript/#rowlink
* ============================================================
* Copyright 2012-2014 Arnold Daniels
@@ -75,7 +75,7 @@
// ==================
$(document).on('click.bs.rowlink.data-api', '[data-link="row"]', function (e) {
if ($(e.target).closest('.rowlink-skip')) return
if ($(e.target).closest('.rowlink-skip').length !== 0) return
var $this = $(this)
if ($this.data('rowlink')) return

View File

@@ -1,6 +1,13 @@
$(function () {
module('inputmask')
var $body;
module('inputmask', {
setup : function() {
$body = $(document.body);
$body.removeData('inputmask');
}
})
test('should provide no conflict', function () {
var inputmask = $.fn.inputmask.noConflict()
@@ -15,6 +22,60 @@ $(function () {
test('should return element', function () {
ok($(document.body).inputmask()[0] == document.body, 'document.body returned')
})
test('should use default mask', function() {
var expected = ""
$.fn.inputmask.Constructor.DEFAULTS.mask = expected
$body.inputmask()
equal(expected, $body.data('inputmask').options.mask)
})
test('should use default placeholder', function() {
var expected = "_"
$.fn.inputmask.Constructor.DEFAULTS.placeholder = expected
$body.inputmask()
equal(expected, $body.data('inputmask').options.placeholder)
})
test('should use default definitions', function() {
var expected = {
'9': "[0-9]",
'a': "[A-Za-z]"
}
$.fn.inputmask.Constructor.DEFAULTS.definitions = expected
$body.inputmask()
deepEqual(expected, $body.data('inputmask').options.definitions)
})
test('should override mask when options.mask provided', function() {
var expected = '99-99';
$body.inputmask({ mask: expected})
equal(expected, $body.data('inputmask').options.mask)
})
test('should override placeholder when options.placeholder provided', function() {
var expected = '-';
$body.inputmask({ placeholder: expected})
equal(expected, $body.data('inputmask').options.placeholder)
})
test('should override definitions when options.definitions provided', function() {
var expected = {
'9': "[0-9]",
'a': "[A-Za-z]"
}
$body.inputmask({definitions: expected})
deepEqual(expected, $body.data('inputmask').options.definitions)
})
// TODO: add inputmask tests
})

50
js/transition.js Normal file
View File

@@ -0,0 +1,50 @@
/* ========================================================================
* Bootstrap: transition.js v3.1.2
* http://getbootstrap.com/javascript/#transitions
* ========================================================================
* Copyright 2011-2014 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* ======================================================================== */
+function ($) {
'use strict';
// CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/)
// ============================================================
function transitionEnd() {
var el = document.createElement('bootstrap')
var transEndEventNames = {
WebkitTransition : 'webkitTransitionEnd',
MozTransition : 'transitionend',
OTransition : 'oTransitionEnd otransitionend',
transition : 'transitionend'
}
for (var name in transEndEventNames) {
if (el.style[name] !== undefined) {
return { end: transEndEventNames[name] }
}
}
return false // explicit for ie8 ( ._.)
}
if ($.support.transition !== undefined) return // Prevent conflict with Twitter Bootstrap
// http://blog.alexmaccaw.com/css-transitions
$.fn.emulateTransitionEnd = function (duration) {
var called = false, $el = this
$(this).one($.support.transition.end, function () { called = true })
var callback = function () { if (!called) $($el).trigger($.support.transition.end) }
setTimeout(callback, duration)
return this
}
$(function () {
$.support.transition = transitionEnd()
})
}(window.jQuery);

View File

@@ -1,6 +1,6 @@
// Fixed alerts
//
// Position to the top or bottom.
// ------------------------------------------------
.alert-fixed-top,
.alert-fixed-bottom {

View File

@@ -1,4 +1,5 @@
// Jasny Bootstrap with default variables
@import "variables.less";
@import "mixins.less";
@import "../jasny-bootstrap.less";

View File

@@ -1,5 +1,6 @@
//
// Mixins
// These mixins are used when Jasny Bootstrap is
// built without importing Twitter Bootstrap.
// --------------------------------------------------
@@ -29,19 +30,3 @@
-webkit-box-shadow: @shadow; // iOS <4.3 & Android <4.1
box-shadow: @shadow;
}
// BUTTONS
// --------------------------------------------------
.button-label-size(@padding-vertical; @padding-horizontal; @border-radius) {
padding: @padding-vertical @padding-horizontal;
left: (-1 * @padding-horizontal);
border-radius: (@border-radius - 1px) 0 0 (@border-radius - 1px);
&.btn-label-right {
left: auto;
right: (-1 * @padding-horizontal);
border-radius: 0 (@border-radius - 1px) (@border-radius - 1px) 0;
}
}

View File

@@ -1,6 +1,19 @@
// Labels for buttons
// --------------------------------------------------
.button-label-size(@padding-vertical; @padding-horizontal; @border-radius) {
padding: @padding-vertical @padding-horizontal;
left: (-1 * @padding-horizontal);
border-radius: (@border-radius - 1px) 0 0 (@border-radius - 1px);
&.btn-label-right {
left: auto;
right: (-1 * @padding-horizontal);
border-radius: 0 (@border-radius - 1px) (@border-radius - 1px) 0;
}
}
.btn-labeled {
padding-top: 0;
padding-bottom: 0;

View File

@@ -13,8 +13,6 @@
margin: 0;
opacity: 0;
filter: alpha(opacity=0);
transform: translate(-300px, 0) scale(4);
-webkit-transform: translate(-300px, 0) scale(4);
font-size: 23px;
height: 100%;
width: 100%;
@@ -23,12 +21,6 @@
}
}
@-moz-document url-prefix() {
.btn-file > input {
transform: none;
}
}
.fileinput {
margin-bottom: 9px;
display: inline-block;
@@ -73,6 +65,14 @@
.fileinput.input-group {
display: table;
> * {
position: relative;
z-index: 2;
}
> .btn-file {
z-index: 1;
}
}
// Not 100% correct, but helps in typical use case

View File

@@ -1,4 +1,3 @@
//
// Navmenu and offcanvas navbar
// --------------------------------------------------

View File

@@ -1,4 +1,3 @@
//
// Off canvas navigation
// --------------------------------------------------

View File

@@ -1,4 +1,3 @@
//
// Rowlink
// --------------------------------------------------

View File

@@ -1,7 +1,7 @@
{
"name": "jasny-bootstrap",
"description": "Additional features and components for Bootstrap",
"version": "3.1.1",
"version": "3.1.2",
"keywords": [
"bootstrap",
"css"
@@ -30,24 +30,24 @@
"grunt": "~0.4.2",
"grunt-banner": "~0.2.0",
"grunt-contrib-clean": "~0.5.0",
"grunt-contrib-concat": "~0.3.0",
"grunt-contrib-concat": "~0.4.0",
"grunt-contrib-connect": "~0.7.0",
"grunt-contrib-copy": "~0.5.0",
"grunt-contrib-csslint": "~0.2.0",
"grunt-contrib-cssmin": "~0.9.0",
"grunt-contrib-jade": "~0.11.0",
"grunt-contrib-jshint": "~0.8.0",
"grunt-contrib-less": "~0.10.0",
"grunt-contrib-jshint": "~0.10.0",
"grunt-contrib-less": "~0.11.0",
"grunt-contrib-qunit": "~0.4.0",
"grunt-contrib-uglify": "~0.4.0",
"grunt-contrib-watch": "~0.5.3",
"grunt-contrib-watch": "~0.6.0",
"grunt-csscomb": "~2.0.1",
"grunt-exec": "~0.4.2",
"grunt-html-validation": "~0.1.13",
"grunt-jekyll": "~0.4.1",
"grunt-jscs-checker": "~0.4.0",
"grunt-saucelabs": "~5.0.0",
"grunt-sed": "~0.1.1",
"grunt-saucelabs": "~5.1.0",
"grunt-text-replace": "~0.3.0",
"load-grunt-tasks": "~0.4.0",
"markdown": "~0.5.0"
},

39
scss/_alerts-fixed.scss Normal file
View File

@@ -0,0 +1,39 @@
// Fixed alerts
// Position to the top or bottom.
// ------------------------------------------------
.alert-fixed-top,
.alert-fixed-bottom {
position: fixed;
width: 100%;
z-index: $zindex-alert-fixed;
border-radius: 0;
margin: 0;
left: 0;
@media (min-width: $alert-fixed-width) {
width: $alert-fixed-width;
left: 50%;
margin-left: (-1 * ($alert-fixed-width / 2));
}
}
.alert-fixed-top {
top: 0;
border-width: 0 0 1px 0;
@media (min-width: $alert-fixed-width) {
@include border-bottom-radius($alert-border-radius);
border-width: 0 1px 1px 1px;
}
}
.alert-fixed-bottom {
bottom: 0;
border-width: 1px 0 0 0;
@media (min-width: $alert-fixed-width) {
@include border-top-radius($alert-border-radius);
border-width: 1px 1px 0 1px;
}
}

38
scss/_button-labels.scss Normal file
View File

@@ -0,0 +1,38 @@
// Labels for buttons
// --------------------------------------------------
@mixin button-label-size($padding-vertical, $padding-horizontal, $border-radius) {
padding: $padding-vertical $padding-horizontal;
left: (-1 * $padding-horizontal);
border-radius: ($border-radius - 1px) 0 0 ($border-radius - 1px);
&.btn-label-right {
left: auto;
right: (-1 * $padding-horizontal);
border-radius: 0 ($border-radius - 1px) ($border-radius - 1px) 0;
}
}
.btn-labeled {
padding-top: 0;
padding-bottom: 0;
}
.btn-label {
position: relative;
background: transparent;
background: rgba(0, 0, 0, 0.15);
display: inline-block;
@include button-label-size($padding-base-vertical, $padding-base-horizontal, $border-radius-base);
}
.btn-lg .btn-label {
@include button-label-size($padding-large-vertical, $padding-large-horizontal, $border-radius-large);
}
.btn-sm .btn-label {
@include button-label-size($padding-small-vertical, $padding-small-horizontal, $border-radius-small);
}
.btn-xs .btn-label {
@include button-label-size(1px, 5px, $border-radius-small);
}

114
scss/_fileinput.scss Normal file
View File

@@ -0,0 +1,114 @@
// Fileinput
// CSS for file upload button and fileinput widget
// ------------------------------------------------
.btn-file {
overflow: hidden;
position: relative;
vertical-align: middle;
> input {
position: absolute;
top: 0;
right: 0;
margin: 0;
opacity: 0;
filter: alpha(opacity=0);
font-size: 23px;
height: 100%;
width: 100%;
direction: ltr;
cursor: pointer;
}
}
.fileinput {
margin-bottom: 9px;
display: inline-block;
.form-control {
padding-top: 7px;
padding-bottom: 5px;
display: inline-block;
margin-bottom: 0px;
vertical-align: middle;
cursor: text;
}
.thumbnail {
overflow: hidden;
display: inline-block;
margin-bottom: 5px;
vertical-align: middle;
text-align: center;
> img {
max-height: 100%;
}
}
.btn {
vertical-align: middle;
}
}
.fileinput-exists .fileinput-new,
.fileinput-new .fileinput-exists {
display: none;
}
.fileinput-inline .fileinput-controls {
display: inline;
}
.fileinput-filename {
vertical-align: middle;
display: inline-block;
overflow: hidden;
}
.form-control .fileinput-filename {
vertical-align: bottom;
}
.fileinput.input-group {
display: table;
}
// Not 100% correct, but helps in typical use case
.fileinput-new.input-group .btn-file,
.fileinput-new .input-group .btn-file {
border-radius: 0 $border-radius-base $border-radius-base 0;
&.btn-xs,
&.btn-sm {
border-radius: 0 $border-radius-small $border-radius-small 0;
}
&.btn-lg {
border-radius: 0 $border-radius-large $border-radius-large 0;
}
}
.form-group.has-warning .fileinput {
.fileinput-preview {
color: $state-warning-text;
}
.thumbnail {
border-color: $state-warning-border;
}
}
.form-group.has-error .fileinput {
.fileinput-preview {
color: $state-danger-text;
}
.thumbnail {
border-color: $state-danger-border;
}
}
.form-group.has-success .fileinput {
.fileinput-preview {
color: $state-success-text;
}
.thumbnail {
border-color: $state-success-border;
}
}
// Input group fixes
.input-group-addon:not(:first-child) {
border-left: 0;
}

View File

@@ -0,0 +1,10 @@
// Smooth sizing container
// -------------------------
.container-smooth {
max-width: $container-lg;
@media (min-width: 1px) {
width: auto;
}
}

View File

@@ -0,0 +1,97 @@
// Alignment options
// -------------------------
// bottom
.nav-tabs-bottom {
border-bottom: 0;
border-top: 1px solid $nav-tabs-border-color;
> li {
margin-bottom: 0;
margin-top: -1px;
> a {
border-radius: 0 0 $border-radius-base $border-radius-base;
}
> a:hover,
> a:focus,
&.active > a,
&.active > a:hover,
&.active > a:focus {
border: 1px solid $nav-tabs-active-link-hover-border-color;
border-top-color: transparent;
}
}
}
// left
.nav-tabs-left {
border-bottom: 0;
border-right: 1px solid $nav-tabs-border-color;
> li {
margin-bottom: 0;
margin-right: -1px;
float: none;
> a {
border-radius: $border-radius-base 0 0 $border-radius-base;
margin-right: 0;
margin-bottom: 2px;
}
> a:hover,
> a:focus,
&.active > a,
&.active > a:hover,
&.active > a:focus {
border: 1px solid $nav-tabs-active-link-hover-border-color;
border-right-color: transparent;
}
}
.row > & {
padding-right: 0;
padding-left: ($grid-gutter-width / 2);
margin-right: -1px;
position: relative;
z-index: 1;
& + .tab-content {
border-left: 1px solid $nav-tabs-active-link-hover-border-color;
}
}
}
// right
.nav-tabs-right {
border-bottom: 0;
border-left: 1px solid $nav-tabs-border-color;
> li {
margin-bottom: 0;
margin-left: -1px;
float: none;
> a {
border-radius: 0 $border-radius-base $border-radius-base 0;
margin-left: 0;
margin-bottom: 2px;
}
> a:hover,
> a:focus,
&.active > a,
&.active > a:hover,
&.active > a:focus {
border: 1px solid $nav-tabs-active-link-hover-border-color;
border-left-color: transparent;
}
}
.row > & {
padding-left: 0;
padding-right: ($grid-gutter-width / 2);
}
}

273
scss/_navmenu.scss Normal file
View File

@@ -0,0 +1,273 @@
// Navmenu and offcanvas navbar
// --------------------------------------------------
// Wrapper and base class
//
// Provide a static navmenu from which we expand to create the fixed navmenu
// variations.
.navmenu,
.navbar-offcanvas {
width: $navmenu-width;
height: 100%;
border-width: 1px;
border-style: solid;
border-radius: $border-radius-base;
}
.navmenu-fixed-left,
.navmenu-fixed-right,
.navbar-offcanvas {
position: fixed;
z-index: $zindex-navmenu-fixed;
top: 0;
border-radius: 0;
}
.navmenu-fixed-left,
.navbar-offcanvas.navmenu-fixed-left {
left: 0;
right: auto;
border-width: 0 1px 0 0;
bottom: 0;
overflow-y: auto;
}
.navmenu-fixed-right,
.navbar-offcanvas {
left: auto;
right: 0;
border-width: 0 0 0 1px;
}
.navmenu-nav {
margin-bottom: $navmenu-margin-vertical;
&.dropdown-menu {
position: static;
margin: 0;
padding-top: 0;
float: none;
border: none;
@include box-shadow(none);
border-radius: 0;
}
}
.navbar-offcanvas {
.navbar-nav {
margin: 0;
}
@media (min-width: $grid-float-breakpoint) {
width: auto;
border-top: 0;
box-shadow: none;
&.offcanvas {
position: static;
display: block !important;
height: auto !important;
padding-bottom: 0; // Override default setting
overflow: visible !important;
}
// Account for first and last children spacing
.navbar-nav.navbar-left:first-child {
margin-left: -$navbar-padding-horizontal;
}
.navbar-nav.navbar-right:last-child {
margin-right: -$navbar-padding-horizontal;
}
.navmenu-brand {
display: none;
}
}
}
// Brand/project name
.navmenu-brand {
display: block;
font-size: $font-size-large;
line-height: $line-height-computed;
padding: $nav-link-padding;
&:hover,
&:focus {
text-decoration: none;
}
margin: $navmenu-margin-vertical 0;
}
// Alternate navmenus
// --------------------------------------------------
// Default navmenu
.navmenu-default,
.navbar-default .navbar-offcanvas {
background-color: $navmenu-default-bg;
border-color: $navmenu-default-border;
.navmenu-brand {
color: $navmenu-default-brand-color;
&:hover,
&:focus {
color: $navmenu-default-brand-hover-color;
background-color: $navmenu-default-brand-hover-bg;
}
}
.navmenu-text {
color: $navmenu-default-color;
}
.navmenu-nav {
// Caret should match text color on hover
> .dropdown > a:hover .caret,
> .dropdown > a:focus .caret {
border-top-color: $navmenu-default-link-hover-color;
border-bottom-color: $navmenu-default-link-hover-color;
}
// Remove background color from open dropdown
> .open > a {
&,
&:hover,
&:focus {
background-color: $navmenu-default-link-active-bg;
color: $navmenu-default-link-active-color;
.caret {
border-top-color: $navmenu-default-link-active-color;
border-bottom-color: $navmenu-default-link-active-color;
}
}
}
> .dropdown > a .caret {
border-top-color: $navmenu-default-link-color;
border-bottom-color: $navmenu-default-link-color;
}
&.dropdown-menu {
background-color: $navmenu-default-link-active-bg;
& > .divider {
background-color: $navmenu-default-bg;
}
> .active > a {
&,
&:hover,
&:focus {
background-color: darken($navmenu-default-link-active-bg, 6.5%);
}
}
}
> li > a {
color: $navmenu-default-link-color;
&:hover,
&:focus {
color: $navmenu-default-link-hover-color;
background-color: $navmenu-default-link-hover-bg;
}
}
> .active > a {
&,
&:hover,
&:focus {
color: $navmenu-default-link-active-color;
background-color: $navmenu-default-link-active-bg;
}
}
> .disabled > a {
&,
&:hover,
&:focus {
color: $navmenu-default-link-disabled-color;
background-color: $navmenu-default-link-disabled-bg;
}
}
}
}
// Inverse navmenu
.navmenu-inverse,
.navbar-inverse .navbar-offcanvas {
background-color: $navmenu-inverse-bg;
border-color: $navmenu-inverse-border;
.navmenu-brand {
color: $navmenu-inverse-brand-color;
&:hover,
&:focus {
color: $navmenu-inverse-brand-hover-color;
background-color: $navmenu-inverse-brand-hover-bg;
}
}
.navmenu-text {
color: $navmenu-inverse-color;
}
.navmenu-nav {
// Caret should match text color on hover
> .dropdown > a:hover .caret,
> .dropdown > a:focus .caret {
border-top-color: $navmenu-inverse-link-hover-color;
border-bottom-color: $navmenu-inverse-link-hover-color;
}
// Remove background color from open dropdown
> .open > a {
&,
&:hover,
&:focus {
background-color: $navmenu-inverse-link-active-bg;
color: $navmenu-inverse-link-active-color;
.caret {
border-top-color: $navmenu-inverse-link-active-color;
border-bottom-color: $navmenu-inverse-link-active-color;
}
}
}
> .dropdown > a .caret {
border-top-color: $navmenu-inverse-link-color;
border-bottom-color: $navmenu-inverse-link-color;
}
&.dropdown-menu {
background-color: $navmenu-inverse-link-active-bg;
& > .divider {
background-color: $navmenu-inverse-bg;
}
> .active > a {
&,
&:hover,
&:focus {
background-color: darken($navmenu-inverse-link-active-bg, 6.5%);
}
}
}
> li > a {
color: $navmenu-inverse-link-color;
&:hover,
&:focus {
color: $navmenu-inverse-link-hover-color;
background-color: $navmenu-inverse-link-hover-bg;
}
}
> .active > a {
&,
&:hover,
&:focus {
color: $navmenu-inverse-link-active-color;
background-color: $navmenu-inverse-link-active-bg;
}
}
> .disabled > a {
&,
&:hover,
&:focus {
color: $navmenu-inverse-link-disabled-color;
background-color: $navmenu-inverse-link-disabled-bg;
}
}
}
}

48
scss/_offcanvas.scss Normal file
View File

@@ -0,0 +1,48 @@
// Off canvas navigation
// --------------------------------------------------
@mixin offcanvas {
display: none;
&.in {
display: block;
}
}
@media (max-width: $screen-xs-max) {
.offcanvas-xs {
@include offcanvas;
}
}
@media (max-width: $screen-sm-max) {
.offcanvas-sm {
@include offcanvas;
}
}
@media (max-width: $screen-md-max) {
.offcanvas-md {
@include offcanvas;
}
}
.offcanvas-lg {
@include offcanvas;
}
.canvas-sliding {
-webkit-transition: top 0.35s, left 0.35s, bottom 0.35s, right 0.35s;
transition: top 0.35s, left 0.35s, bottom 0.35s, right 0.35s;
}
.offcanvas-clone {
height: 0px !important;
width: 0px !important;
overflow: hidden !important;
border: none !important;
margin: 0px !important;
padding: 0px !important;
position: absolute !important;
top: auto !important;
left: auto !important;
bottom: 0px !important;
right: 0px !important;
opacity: 0 !important;
}

22
scss/_rowlink.scss Normal file
View File

@@ -0,0 +1,22 @@
// Rowlink
// --------------------------------------------------
.table.rowlink,
.table .rowlink {
td:not(.rowlink-skip) {
cursor: pointer;
a {
color: inherit;
font: inherit;
text-decoration: inherit;
}
}
}
.table-hover.rowlink,
.table-hover .rowlink {
tr:hover td {
background-color: darken($table-bg-hover, 15%);
}
}

66
scss/_variables.scss Normal file
View File

@@ -0,0 +1,66 @@
//
// Variables
//
// Either Twitter Bootstrap's "variables.less" or this package's
// "default-variables.less" should be loaded before this file.
// -------------------------------------------------------------
$zindex-navmenu-fixed: 1030 !default;
$zindex-alert-fixed: 1035 !default;
$container-smooth: $container-lg !default;
$alert-fixed-width: $screen-md-min !default;
//== Navmenu
// Basics of a navmenu
$navmenu-width: 300px !default;
$navmenu-margin-vertical: (0.5 * $line-height-computed) !default;
$navmenu-default-color: #777 !default;
$navmenu-default-bg: #f8f8f8 !default;
$navmenu-default-border: darken($navmenu-default-bg, 6.5%) !default;
// Navmenu links
$navmenu-default-link-color: #777 !default;
$navmenu-default-link-hover-color: #333 !default;
$navmenu-default-link-hover-bg: transparent !default;
$navmenu-default-link-active-color: #555 !default;
$navmenu-default-link-active-bg: darken($navmenu-default-bg, 6.5%) !default;
$navmenu-default-link-disabled-color: #ccc !default;
$navmenu-default-link-disabled-bg: transparent !default;
// Navmenu brand label
$navmenu-default-brand-color: $navmenu-default-link-color !default;
$navmenu-default-brand-hover-color: darken($navmenu-default-link-color, 10%) !default;
$navmenu-default-brand-hover-bg: transparent !default;
// Inverted navmenu
//
// Reset inverted navmenu basics
$navmenu-inverse-color: $gray-light !default;
$navmenu-inverse-bg: #222 !default;
$navmenu-inverse-border: darken($navmenu-inverse-bg, 10%) !default;
// Inverted navmenu links
$navmenu-inverse-link-color: $gray-light !default;
$navmenu-inverse-link-hover-color: #fff !default;
$navmenu-inverse-link-hover-bg: transparent !default;
$navmenu-inverse-link-active-color: $navmenu-inverse-link-hover-color !default;
$navmenu-inverse-link-active-bg: darken($navmenu-inverse-bg, 10%) !default;
$navmenu-inverse-link-disabled-color: #444 !default;
$navmenu-inverse-link-disabled-bg: transparent !default;
// Inverted navmenu brand label
$navmenu-inverse-brand-color: $navmenu-inverse-link-color !default;
$navmenu-inverse-brand-hover-color: #fff !default;
$navmenu-inverse-brand-hover-bg: transparent !default;
// Inverted navmenu search
// Normal navmenu needs no special styles or vars
$navmenu-inverse-search-bg: lighten($navmenu-inverse-bg, 25%) !default;
$navmenu-inverse-search-bg-focus: #fff !default;
$navmenu-inverse-search-border: $navmenu-inverse-bg !default;
$navmenu-inverse-search-placeholder-color: #ccc !default;

19
scss/jasny-bootstrap.scss Normal file
View File

@@ -0,0 +1,19 @@
// Twitter Bootstrap's "variables.scss" should already be imported
// Core variables and mixins
@import "variables";
@import "mixins";
// Core CSS
@import "grid-container-smooth";
@import "button-labels";
// Components
@import "nav-tab-alignment";
@import "navmenu";
@import "alerts-fixed";
// Components w/ JavaScript
@import "offcanvas";
@import "rowlink";
@import "fileinput";

File diff suppressed because one or more lines are too long