-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* material: (24 commits) More bower.json tweaks. Tweak bower.json. Tweak package.json. Fix failing tests caused by the grunt config. Fix all failing tests because of switch-light markup change. Add new tests for the Material theme and switch-toggle with 6 options. Changelog tweaks. Update the bootstrap docs. Tweak the line-height so the light switch works better with bootstrap classes. Update the Foundation docs. Tweaks to the README. Add the new material theme to the docs homepage, and some tweaks. component(1) is dead, so stop supporting it. componentjs/component#639 Update changelog with the material theme details. Add more example to the docs site homepage header. Complete the new material design theme, with ripples and everything, all still css. Material design toggle switches will look like custom radios, still from material design. Make the new material design theme work with the new switch-light markup. Fix the ios theme to work with the new markup. Tweaks to the iOS theme to make it look a bit better. Nesting CSS was a bad idea. Fix the Holo theme to work with the new switch-light markup. Remove the nasty `switch-X` classes used with `switch-toggle` for number of items. More fixes to the `candy` theme to support the new markup. New markup for the `switch-light` component and begin adapting the `candy` theme for the new markup. Begin work on the new `material` theme. Use partials for the top menus and the footer credits. ...
- Loading branch information
Showing
41 changed files
with
3,797 additions
and
8,821 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,3 +5,4 @@ npm-debug.log | |
node_modules | ||
.tmp | ||
.sass-cache | ||
build/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,33 +6,27 @@ var mountFolder = function (connect, dir) { | |
}; | ||
|
||
module.exports = function (grunt) { | ||
// load all grunt tasks | ||
require('matchdep').filterDev('grunt-*').forEach(grunt.loadNpmTasks); | ||
|
||
// configurable paths | ||
var yeomanConfig = { | ||
app: 'src', | ||
dist: 'dist' | ||
}; | ||
|
||
try { | ||
yeomanConfig.app = require('./bower.json').appPath || yeomanConfig.app; | ||
} catch (e) {} | ||
grunt.loadNpmTasks('assemble'); | ||
|
||
grunt.initConfig({ | ||
yeoman: yeomanConfig, | ||
watch: { | ||
sass: { | ||
files: [ '<%= yeoman.app %>/{,*/}*.{scss,sass}' ], | ||
files: [ '{src,site}/{,*/}*.scss' ], | ||
tasks: [ 'sass:server' ] | ||
}, | ||
assemble: { | ||
files: [ 'site/{,*/}*.{hbs,html}' ], | ||
tasks: [ 'assemble' ] | ||
}, | ||
livereload: { | ||
options: { | ||
livereload: LIVERELOAD_PORT | ||
}, | ||
files: [ | ||
'./{,*/}*.html', | ||
'./{,*/}*.css' | ||
'./build/*.html', | ||
'./build/{,*/}*.css', | ||
'./dist/*.css' | ||
] | ||
} | ||
}, | ||
|
@@ -46,6 +40,7 @@ module.exports = function (grunt) { | |
middleware: function (connect) { | ||
return [ | ||
lrSnippet, | ||
mountFolder(connect, './build/'), | ||
mountFolder(connect, './') | ||
]; | ||
} | ||
|
@@ -55,34 +50,22 @@ module.exports = function (grunt) { | |
options: { | ||
middleware: function (connect) { | ||
return [ | ||
mountFolder(connect, './') | ||
mountFolder(connect, './build/') | ||
]; | ||
} | ||
} | ||
} | ||
}, | ||
sass: { | ||
dist: { | ||
files: { | ||
'<%= yeoman.dist %>/toggle-switch.css': '<%= yeoman.app %>/toggle-switch.scss', | ||
'<%= yeoman.dist %>/toggle-switch-rem.css': '<%= yeoman.app %>/toggle-switch-rem.scss', | ||
'<%= yeoman.dist %>/toggle-switch-px.css': '<%= yeoman.app %>/toggle-switch-px.scss', | ||
'<%= yeoman.dist %>/docs/docs.css': '<%= yeoman.app %>/docs/docs.scss', | ||
'<%= yeoman.dist %>/docs/foundation.css': 'bower_components/foundation/scss/foundation.scss' | ||
} | ||
options: { | ||
sourceMap: true | ||
}, | ||
server: { | ||
options: { | ||
includePaths: [ | ||
'' | ||
] | ||
}, | ||
files: { | ||
'<%= yeoman.dist %>/toggle-switch.css': '<%= yeoman.app %>/toggle-switch.scss', | ||
'<%= yeoman.dist %>/toggle-switch-rem.css': '<%= yeoman.app %>/toggle-switch-rem.scss', | ||
'<%= yeoman.dist %>/toggle-switch-px.css': '<%= yeoman.app %>/toggle-switch-px.scss', | ||
'<%= yeoman.dist %>/docs/docs.css': '<%= yeoman.app %>/docs/docs.scss', | ||
'<%= yeoman.dist %>/docs/foundation.css': 'bower_components/foundation/scss/foundation.scss' | ||
'dist/toggle-switch.css': 'src/toggle-switch.scss', | ||
'dist/toggle-switch-rem.css': 'src/toggle-switch-rem.scss', | ||
'dist/toggle-switch-px.css': 'src/toggle-switch-px.scss', | ||
'build/css/docs.css': 'site/css/docs.scss' | ||
} | ||
} | ||
}, | ||
|
@@ -137,6 +120,55 @@ module.exports = function (grunt) { | |
] | ||
} | ||
} | ||
}, | ||
assemble: { | ||
options: { | ||
layoutdir: 'site/layouts', | ||
partials: 'site/partials/*.html' | ||
}, | ||
site: { | ||
files: [{ | ||
expand: true, | ||
cwd: 'site', | ||
src: '{,*/}*.hbs', | ||
dest: 'build' | ||
}] | ||
} | ||
}, | ||
clean: { | ||
site: { | ||
src: [ | ||
'build/', | ||
'dist/' | ||
] | ||
} | ||
}, | ||
copy: { | ||
site: { | ||
files: [ | ||
{ | ||
src: [ | ||
'bower_components/**', | ||
'test/**', | ||
'dist/**' | ||
], | ||
dest: 'build/' | ||
} | ||
] | ||
} | ||
}, | ||
buildcontrol: { | ||
options: { | ||
dir: 'build', | ||
commit: true, | ||
push: true | ||
}, | ||
site: { | ||
options: { | ||
remote: '[email protected]:ghinda/css-toggle-switch.git', | ||
branch: 'gh-pages' | ||
} | ||
} | ||
} | ||
}); | ||
|
||
|
@@ -146,20 +178,25 @@ module.exports = function (grunt) { | |
} | ||
|
||
grunt.task.run([ | ||
'sass:server', | ||
'clean', | ||
'assemble', | ||
'sass', | ||
'connect:livereload', | ||
'watch' | ||
]); | ||
}); | ||
|
||
grunt.registerTask('test', [ | ||
'sass:server', | ||
'build', | ||
'connect:dist', | ||
'saucelabs-qunit' | ||
]); | ||
|
||
grunt.registerTask('build', [ | ||
'sass:dist' | ||
'clean', | ||
'assemble', | ||
'sass', | ||
'copy' | ||
]); | ||
|
||
grunt.registerTask('default', [ | ||
|
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
Oops, something went wrong.