Skip to content

Commit

Permalink
include bower components
Browse files Browse the repository at this point in the history
  • Loading branch information
thomaspark committed Nov 13, 2013
1 parent dda3129 commit 34c406a
Show file tree
Hide file tree
Showing 1,780 changed files with 213,060 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
@@ -1,4 +1,3 @@
node_modules
_site/
batch.json
bower_components/
26 changes: 26 additions & 0 deletions bower_components/bootstrap/.bower.json
@@ -0,0 +1,26 @@
{
"name": "bootstrap",
"version": "3.0.2",
"main": [
"./dist/js/bootstrap.js",
"./dist/css/bootstrap.css",
"./dist/fonts/*"
],
"ignore": [
"**/.*"
],
"dependencies": {
"jquery": ">= 1.9.0"
},
"homepage": "https://github.com/twbs/bootstrap",
"_release": "3.0.2",
"_resolution": {
"type": "version",
"tag": "v3.0.2",
"commit": "3887f540b978d593f433bfef15888bc2d103de72"
},
"_source": "git://github.com/twbs/bootstrap.git",
"_target": "~3.0.2",
"_originalSource": "bootstrap",
"_direct": true
}
1 change: 1 addition & 0 deletions bower_components/bootstrap/CNAME
@@ -0,0 +1 @@
getbootstrap.com
61 changes: 61 additions & 0 deletions bower_components/bootstrap/CONTRIBUTING.md
@@ -0,0 +1,61 @@
# Contributing to Bootstrap

Looking to contribute something to Bootstrap? **Here's how you can help.**



## Reporting issues

We only accept issues that are bug reports or feature requests. Bugs must be isolated and reproducible problems that we can fix within the Bootstrap core. Please read the following guidelines before opening any issue.

1. **Search for existing issues.** We get a lot of duplicate issues, and you'd help us out a lot by first checking if someone else has reported the same issue. Moreover, the issue may have already been resolved with a fix available.
2. **Create an isolated and reproducible test case.** Be sure the problem exists in Bootstrap's code with a [reduced test case](http://css-tricks.com/reduced-test-cases/) that should be included in each bug report.
3. **Include a live example.** Make use of jsFiddle or jsBin to share your isolated test cases.
4. **Share as much information as possible.** Include operating system and version, browser and version, version of Bootstrap, customized or vanilla build, etc. where appropriate. Also include steps to reproduce the bug.



## Pull requests

- CSS changes must be done in `.less` files first, never just the compiled `.css` files
- If modifying the `.less` files, always recompile and commit the compiled files `bootstrap.css` and `bootstrap.min.css`
- Try not to pollute your pull request with unintended changes--keep them simple and small
- Try to share which browsers your code has been tested in before submitting a pull request
- Pull requests should always be against the `master` branch, never against `gh-pages`.



## Coding standards

### HTML

- Two spaces for indentation, never tabs
- Double quotes only, never single quotes
- Always use proper indentation
- Use tags and elements appropriate for an HTML5 doctype (e.g., self-closing tags)
- Use CDNs and HTTPS for third-party JS when possible. We don't use protocol-relative URLs in this case because they break when viewing the page locally via `file://`.

### CSS

- Adhere to the [RECESS CSS property order](http://markdotto.com/2011/11/29/css-property-order/)
- Multiple-line approach (one property and value per line)
- Always a space after a property's colon (e.g., `display: block;` and not `display:block;`)
- End all lines with a semi-colon
- For multiple, comma-separated selectors, place each selector on its own line
- Attribute selectors, like `input[type="text"]` should always wrap the attribute's value in double quotes, for consistency and safety (see this [blog post on unquoted attribute values](http://mathiasbynens.be/notes/unquoted-attribute-values) that can lead to XSS attacks).

### JS

- No semicolons
- Comma first
- 2 spaces (no tabs)
- strict mode
- "Attractive"



## License

With v3.1, we're moving from the Apache 2 to the MIT license for the Bootstrap code (not the docs). We're in the process of collecting permissions from all Bootstrap contributors with code still part of the project to make this happen. For details, please see [#2054](https://github.com/twbs/bootstrap/issues/2054).

By contributing your code, you agree to dual-license your contribution under the [Apache 2](https://github.com/twbs/bootstrap/blob/master/LICENSE) and [MIT](https://github.com/twbs/bootstrap/blob/master/MIT) licenses.
319 changes: 319 additions & 0 deletions bower_components/bootstrap/DOCS-LICENSE

Large diffs are not rendered by default.

244 changes: 244 additions & 0 deletions bower_components/bootstrap/Gruntfile.js
@@ -0,0 +1,244 @@
/* jshint node: true */

module.exports = function(grunt) {
"use strict";

RegExp.quote = require('regexp-quote')
var btoa = require('btoa')
// Project configuration.
grunt.initConfig({

// Metadata.
pkg: grunt.file.readJSON('package.json'),
banner: '/*!\n' +
' * Bootstrap v<%= pkg.version %> by @fat and @mdo\n' +
' * Copyright <%= grunt.template.today("yyyy") %> <%= pkg.author %>\n' +
' * Licensed under <%= _.pluck(pkg.licenses, "url").join(", ") %>\n' +
' *\n' +
' * Designed and built with all the love in the world by @mdo and @fat.\n' +
' */\n\n',
jqueryCheck: 'if (typeof jQuery === "undefined") { throw new Error("Bootstrap requires jQuery") }\n\n',

// Task configuration.
clean: {
dist: ['dist']
},

jshint: {
options: {
jshintrc: 'js/.jshintrc'
},
gruntfile: {
src: 'Gruntfile.js'
},
src: {
src: ['js/*.js']
},
test: {
src: ['js/tests/unit/*.js']
}
},

concat: {
options: {
banner: '<%= banner %><%= jqueryCheck %>',
stripBanners: false
},
bootstrap: {
src: [
'js/transition.js',
'js/alert.js',
'js/button.js',
'js/carousel.js',
'js/collapse.js',
'js/dropdown.js',
'js/modal.js',
'js/tooltip.js',
'js/popover.js',
'js/scrollspy.js',
'js/tab.js',
'js/affix.js'
],
dest: 'dist/js/<%= pkg.name %>.js'
}
},

uglify: {
options: {
banner: '<%= banner %>',
report: 'min'
},
bootstrap: {
src: ['<%= concat.bootstrap.dest %>'],
dest: 'dist/js/<%= pkg.name %>.min.js'
}
},

recess: {
options: {
compile: true,
banner: '<%= banner %>'
},
bootstrap: {
src: ['less/bootstrap.less'],
dest: 'dist/css/<%= pkg.name %>.css'
},
min: {
options: {
compress: true
},
src: ['less/bootstrap.less'],
dest: 'dist/css/<%= pkg.name %>.min.css'
},
theme: {
src: ['less/theme.less'],
dest: 'dist/css/<%= pkg.name %>-theme.css'
},
theme_min: {
options: {
compress: true
},
src: ['less/theme.less'],
dest: 'dist/css/<%= pkg.name %>-theme.min.css'
}
},

copy: {
fonts: {
expand: true,
src: ["fonts/*"],
dest: 'dist/'
}
},

qunit: {
options: {
inject: 'js/tests/unit/phantom.js'
},
files: ['js/tests/*.html']
},

connect: {
server: {
options: {
port: 3000,
base: '.'
}
}
},

jekyll: {
docs: {}
},

validation: {
options: {
reset: true,
relaxerror: [
"Bad value X-UA-Compatible for attribute http-equiv on element meta.",
"Element img is missing required attribute src."
]
},
files: {
src: ["_gh_pages/**/*.html"]
}
},

watch: {
src: {
files: '<%= jshint.src.src %>',
tasks: ['jshint:src', 'qunit']
},
test: {
files: '<%= jshint.test.src %>',
tasks: ['jshint:test', 'qunit']
},
recess: {
files: 'less/*.less',
tasks: ['recess']
}
},

sed: {
versionNumber: {
pattern: (function () {
var old = grunt.option('oldver')
return old ? RegExp.quote(old) : old
})(),
replacement: grunt.option('newver'),
recursive: true
}
}
});


// These plugins provide necessary tasks.
grunt.loadNpmTasks('browserstack-runner');
grunt.loadNpmTasks('grunt-contrib-clean');
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-connect');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-qunit');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-html-validation');
grunt.loadNpmTasks('grunt-jekyll');
grunt.loadNpmTasks('grunt-recess');
grunt.loadNpmTasks('grunt-sed');

// Docs HTML validation task
grunt.registerTask('validate-html', ['jekyll', 'validation']);

// Test task.
var testSubtasks = ['dist-css', 'jshint', 'qunit', 'validate-html'];
// Only run BrowserStack tests under Travis
if (process.env.TRAVIS) {
// Only run BrowserStack tests if this is a mainline commit in twbs/bootstrap, or you have your own BrowserStack key
if ((process.env.TRAVIS_REPO_SLUG === 'twbs/bootstrap' && process.env.TRAVIS_PULL_REQUEST === 'false') || process.env.TWBS_HAVE_OWN_BROWSERSTACK_KEY) {
testSubtasks.push('browserstack_runner');
}
}
grunt.registerTask('test', testSubtasks);

// JS distribution task.
grunt.registerTask('dist-js', ['concat', 'uglify']);

// CSS distribution task.
grunt.registerTask('dist-css', ['recess']);

// Fonts distribution task.
grunt.registerTask('dist-fonts', ['copy']);

// Full distribution task.
grunt.registerTask('dist', ['clean', 'dist-css', 'dist-fonts', 'dist-js']);

// Default task.
grunt.registerTask('default', ['test', 'dist', 'build-customizer']);

// 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']);

// task for building customizer
grunt.registerTask('build-customizer', 'Add scripts/less files to customizer.', function () {
var fs = require('fs')

function getFiles(type) {
var files = {}
fs.readdirSync(type)
.filter(function (path) {
return type == 'fonts' ? true : new RegExp('\\.' + type + '$').test(path)
})
.forEach(function (path) {
var fullPath = type + '/' + path
return files[path] = (type == 'fonts' ? btoa(fs.readFileSync(fullPath)) : fs.readFileSync(fullPath, 'utf8'))
})
return 'var __' + type + ' = ' + JSON.stringify(files) + '\n'
}

var files = getFiles('js') + getFiles('less') + getFiles('fonts')
fs.writeFileSync('docs-assets/js/raw-files.js', files)
});
};

0 comments on commit 34c406a

Please sign in to comment.