Skip to content

Commit

Permalink
Initial import
Browse files Browse the repository at this point in the history
  • Loading branch information
David Milne committed May 8, 2015
1 parent 34d06d9 commit 6261927
Show file tree
Hide file tree
Showing 16 changed files with 2,102 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,5 @@ target/
#Bower
bower_components/

#Node
node_modules/
103 changes: 103 additions & 0 deletions GruntFile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
'use strict';

module.exports = function (grunt) {

// Load grunt tasks automatically
require('load-grunt-tasks')(grunt);

grunt.initConfig({
concat: {
js: {
options: {
banner:
'angular.module(\'datetime.bootstrap\', [\'datetime.bootstrap.directives\',' +
'\'datetime.bootstrap.services\',' +
'\'datetime.bootstrap.templates\']);\n\n'
},
src: ['./src/scripts/*.js'],
dest: './dist/datetime-bootstrap.js'
},
css: {
src: ['./src/styles/*.css'],
dest: './dist/datetime-bootstrap.css'
}
},
htmlangular: {
options: {
customtags: [
'date-input',
'time-input',
'numeric-dropdown'
],
customattrs: [
'dropdown',
'dropdown-toggle',
'is-open',
'padded-numeric'
]
},
files: {
src: ['src/templates/*.html'],
}
},
html2js: {
app: {
options: {
base: './src/templates/',
useStrict: true,
quoteChar: '\'',
htmlmin: {
collapseBooleanAttributes: true,
collapseWhitespace: true,
removeAttributeQuotes: true,
removeComments: true,
removeEmptyAttributes: true,
removeRedundantAttributes: true,
removeScriptTypeAttributes: true,
removeStyleLinkTypeAttributes: true
}
},
src: ['./src/templates/*.html'],
dest: './src/scripts/templates.js',
module: 'datetime.bootstrap.templates'
}
},
uglify: {
js: {
src: ['./dist/datetime-bootstrap.js'],
dest: './dist/datetime-bootstrap.min.js'
}
},
cssmin: {
target: {
files: {
'./dist/datetime-bootstrap.min.css': ['./dist/datetime-bootstrap.css']
}
}
},
watch: {
files: [
'./src/templates/*.html',
'./src/scripts/*.js',
'./src/styles/*.css'
],
tasks: 'quick'
}
});

grunt.registerTask('default', [
'htmlangular',
'html2js',
'concat',
'uglify',
'cssmin'
]);

grunt.registerTask('quick', [
'html2js',
'concat',
'uglify',
'cssmin'
]) ;

};
35 changes: 35 additions & 0 deletions bower.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"name": "datetime-bootstrap",
"version": "0.0.1",
"dependencies": {
"angular": "latest",
"lodash": "latest",
"moment": "latest",
"bootstrap": "latest",
"angular-bootstrap": "latest"
},
"devDependencies": {
"angular-mocks": "latest",
"angular-resource": "latest"
},
"main": ["dist/datetime-bootstrap.js", "datetime/datetime-bootstrap.css"],
"authors": [
"David Milne <[email protected]>"
],
"description": "Angular widgets for entering dates and times, with boostrap theming",
"keywords": [
"angular",
"date",
"time",
"bootstrap"
],
"license": "MIT",
"homepage": "https://github.com/dnmilne/datetime-bootstrap",
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"test",
"tests"
]
}
22 changes: 22 additions & 0 deletions dist/datetime-bootstrap.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
.internal-form-control {
display: inline-block;
border: none;
}

.internal-form-control input {
border: none;
width: 100%;
text-align:center;
}

.internal-form-control.left input {
text-align:right;
}

.internal-form-control.center input {
text-align:center;
}

.internal-form-control.right input {
text-align:left;
}
Loading

0 comments on commit 6261927

Please sign in to comment.