diff --git a/CNAME b/CNAME index 987e0cb..aff77b6 100644 --- a/CNAME +++ b/CNAME @@ -1 +1 @@ -goratchet.com \ No newline at end of file +goratchet.com diff --git a/Gruntfile.js b/Gruntfile.js index f3af756..7ab765d 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -23,7 +23,7 @@ module.exports = function(grunt) { banner: '/*!\n' + ' * =====================================================\n' + - ' * Ratchet v<%= pkg.version %>\n' + + ' * Ratchet v<%= pkg.version %> (<%= pkg.homepage %>)\n' + ' * Copyright <%= grunt.template.today("yyyy") %> <%= pkg.author %>\n' + ' * Licensed under <%= pkg.license %>.\n' + ' *\n' + @@ -129,6 +129,17 @@ module.exports = function(grunt) { files: { src: '_site/**/*.html' } + }, + + sed: { + versionNumber: { + pattern: (function () { + var old = grunt.option('oldver'); + return old ? RegExp.quote(old) : old; + })(), + replacement: grunt.option('newver'), + recursive: true + } } }); @@ -142,4 +153,9 @@ module.exports = function(grunt) { grunt.registerTask('validate-html', ['jekyll', 'validation']); grunt.registerTask('default', ['dist']); grunt.registerTask('build', ['dist']); + + // 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'); }; diff --git a/README.md b/README.md index 1f816b7..90f52bb 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ Build mobile apps with simple HTML, CSS, and JS components. - Clone the repo with `git clone https://github.com/twbs/ratchet.git` or just [download](http://github.com/twbs/ratchet/archive/v2.0.0.zip) the bundled CSS and JS - [Read the docs](http://goratchet.com) to learn about the components and how to get a prototype on your phone -- We will have example apps to check out very soon! +- [Check out examples](http://goratchet.com/examples/) Take note that our master branch is our active, unstable development branch and that if you're looking to download a stable copy of the repo, check the [tagged downloads](https://github.com/twbs/ratchet/tags). @@ -37,11 +37,11 @@ Please file a GitHub issue to [report a bug](https://github.com/twbs/ratchet/iss A small list of "gotchas" are provided below for designers and developers starting to work with Ratchet - Ratchet is designed to respond to touch events from a mobile device. In order to use mouse click events (for desktop browsing and testing), you have a few options: - - Enable touch event emulation in Chrome (found in the overrides tab in the web inspector preferences) - - Use a JavaScript library like fingerblast.js to emulate touch events (ideally only loaded from desktop devices) + - Enable touch event emulation in Chrome (found in the overrides tab in the web inspector preferences) + - Use a JavaScript library like fingerblast.js to emulate touch events (ideally only loaded from desktop devices) - Script tags containing JavaScript will not be executed on pages that are loaded with push.js. If you would like to attach event handlers to elements on other pages, document-level event delegation is a common solution. -- Ratchet uses XHR requests to fetch additional pages inside the application. Due to security concerns, modern browsers prevent XHR requests when opening files locally (aka using the file:/// protocol); consequently, Ratchet does not work when opened directly as a file. - - A common solution to this is to simply serve the files from a local server. One convenient way to achieve this is to run ```python -m SimpleHTTPServer ``` to serve up the files in the current directory to ```http://localhost:``` +- Ratchet uses XHR requests to fetch additional pages inside the application. Due to security concerns, modern browsers prevent XHR requests when opening files locally (aka using the file:// protocol); consequently, Ratchet does not work when opened directly as a file. + - A common solution to this is to simply serve the files from a local server. One convenient way to achieve this is to run ```python -m SimpleHTTPServer ``` to serve up the files in the current directory to ```http://localhost:``` ## Versioning diff --git a/dist/ratchet-theme-android.css b/dist/ratchet-theme-android.css index 62fc5a8..a9c3abc 100644 --- a/dist/ratchet-theme-android.css +++ b/dist/ratchet-theme-android.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/dist/ratchet-theme-ios.css b/dist/ratchet-theme-ios.css index d07c9e0..e268d38 100644 --- a/dist/ratchet-theme-ios.css +++ b/dist/ratchet-theme-ios.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/dist/ratchet.css b/dist/ratchet.css index a948031..741a5ae 100644 --- a/dist/ratchet.css +++ b/dist/ratchet.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/dist/ratchet.js b/dist/ratchet.js index 1cc9ccd..4372a7b 100644 --- a/dist/ratchet.js +++ b/dist/ratchet.js @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/dist/ratchet.min.css b/dist/ratchet.min.css index 0e5e4ce..3429028 100644 --- a/dist/ratchet.min.css +++ b/dist/ratchet.min.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/dist/ratchet.min.js b/dist/ratchet.min.js index 8c467e9..6c3332d 100644 --- a/dist/ratchet.min.js +++ b/dist/ratchet.min.js @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/dist/template.html b/dist/template.html index 6416b7c..9577105 100644 --- a/dist/template.html +++ b/dist/template.html @@ -52,7 +52,7 @@
  • - + Ratchet on Github
  • @@ -62,7 +62,7 @@
  • - + Ratchet on Twitter
  • @@ -71,4 +71,4 @@ - \ No newline at end of file + diff --git a/docs/_includes/download-module.html b/docs/_includes/download-module.html index a6f4d80..318855f 100644 --- a/docs/_includes/download-module.html +++ b/docs/_includes/download-module.html @@ -2,5 +2,5 @@

    Download Ratchet

    If you haven't already, download the source code for Ratchet.

    Download Ratchet -

    Currently v2.0.0

    +

    Currently v2.0.0

    \ No newline at end of file diff --git a/docs/_includes/footer.html b/docs/_includes/footer.html index c1db49a..e9df6a9 100644 --- a/docs/_includes/footer.html +++ b/docs/_includes/footer.html @@ -14,5 +14,15 @@ - + + + diff --git a/docs/assets/css/docs.css b/docs/assets/css/docs.css index adc2f5d..e14f512 100644 --- a/docs/assets/css/docs.css +++ b/docs/assets/css/docs.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * @@ -305,6 +305,8 @@ body { margin-top: 50px; padding-top: 30px; padding-bottom: 30px; + color: #777; + font-size: 14px; text-align: center; } .docs-footer .social { @@ -321,10 +323,24 @@ body { margin-top: 5px; } -.docs-footer-content { - margin: 0; - color: #777; - font-size: 12px; +.docs-footer-text { + margin-top: 0; + margin-bottom: 0; +} + +@media screen and (min-width: 768px) { + .docs-footer-text { + width: 550px; + margin: 0 auto; + } +} +.docs-footer-links { + padding-left: 0; +} +.docs-footer-links li { + display: inline; + padding-left: 3px; + padding-right: 3px; } .docs-header .docs-footer { @@ -335,11 +351,12 @@ body { margin-top: 0; border-top: 1px solid rgba(255, 255, 255, 0.1); } -.docs-header .docs-footer .docs-footer-content { +.docs-header .docs-footer .docs-footer-text, +.docs-header .docs-footer .docs-footer-links { color: rgba(255, 255, 255, 0.5); } -.docs-header .docs-footer .docs-footer-content a { - font-weight: bold; +.docs-header .docs-footer .docs-footer-text a, +.docs-header .docs-footer .docs-footer-links a { color: rgba(255, 255, 255, 0.8); } @@ -643,10 +660,10 @@ hr { @media screen and (min-width: 768px) { .docs-header { - min-height: 830px; + min-height: 870px; } .docs-header .carbonad { - bottom: 180px !important; + bottom: 259px !important; left: 50% !important; margin-left: -165px !important; } @@ -675,7 +692,7 @@ hr { } .docs-header-content { - top: 32%; + top: 30%; -webkit-transform: translateY(-50%); -ms-transform: translateY(-50%); transform: translateY(-50%); diff --git a/docs/dist/ratchet-theme-android.css b/docs/dist/ratchet-theme-android.css index 62fc5a8..a9c3abc 100644 --- a/docs/dist/ratchet-theme-android.css +++ b/docs/dist/ratchet-theme-android.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/docs/dist/ratchet-theme-ios.css b/docs/dist/ratchet-theme-ios.css index d07c9e0..e268d38 100644 --- a/docs/dist/ratchet-theme-ios.css +++ b/docs/dist/ratchet-theme-ios.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/docs/dist/ratchet.css b/docs/dist/ratchet.css index a948031..741a5ae 100644 --- a/docs/dist/ratchet.css +++ b/docs/dist/ratchet.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/docs/dist/ratchet.js b/docs/dist/ratchet.js index 1cc9ccd..4372a7b 100644 --- a/docs/dist/ratchet.js +++ b/docs/dist/ratchet.js @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/docs/dist/ratchet.min.css b/docs/dist/ratchet.min.css index 0e5e4ce..3429028 100644 --- a/docs/dist/ratchet.min.css +++ b/docs/dist/ratchet.min.css @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/docs/dist/ratchet.min.js b/docs/dist/ratchet.min.js index 8c467e9..6c3332d 100644 --- a/docs/dist/ratchet.min.js +++ b/docs/dist/ratchet.min.js @@ -1,6 +1,6 @@ /*! * ===================================================== - * Ratchet v2.0.0 + * Ratchet v2.0.0 (http://goratchet.com) * Copyright 2014 Connor Sears * Licensed under MIT. * diff --git a/docs/index.html b/docs/index.html index cd90959..e637f87 100644 --- a/docs/index.html +++ b/docs/index.html @@ -8,7 +8,7 @@ title: Ratchet

    Build mobile apps with simple HTML‚ CSS‚ and JS components.

    Download Ratchet -

    Currently v2.0.0

    +

    Currently v2.0.0

    {% include ad.html %} diff --git a/docs/one.html b/docs/one.html index ff13d4e..4b8afeb 100644 --- a/docs/one.html +++ b/docs/one.html @@ -10,7 +10,7 @@ - + diff --git a/docs/two.html b/docs/two.html index 746828d..e0be407 100644 --- a/docs/two.html +++ b/docs/two.html @@ -10,7 +10,7 @@ - + diff --git a/package.json b/package.json index a039263..9a99b01 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,7 @@ "grunt-contrib-watch": "~0.5.3", "grunt-html-validation": "~0.1.13", "grunt-jekyll": "~0.4.1", + "grunt-sed": "~0.1.1", "load-grunt-tasks": "~0.4.0" } } diff --git a/sass/docs.scss b/sass/docs.scss index 7a024eb..256168a 100644 --- a/sass/docs.scss +++ b/sass/docs.scss @@ -296,6 +296,8 @@ body { margin-top: 50px; padding-top: 30px; padding-bottom: 30px; + color: #777; + font-size: 14px; text-align: center; .social { @@ -313,11 +315,27 @@ body { } } } -.docs-footer-content { - margin: 0; - color: #777; - font-size: 12px; +.docs-footer-text { + margin-top: 0; + margin-bottom: 0; +} +@media screen and (min-width: 768px) { + .docs-footer-text { + width: 550px; + margin: 0 auto; + } } +.docs-footer-links { + padding-left: 0; + + li { + display: inline; + padding-left: 3px; + padding-right: 3px; + } +} + +// Overrides for the homepage's footer .docs-header .docs-footer { position: absolute; bottom: 0; @@ -326,11 +344,11 @@ body { margin-top: 0; border-top: 1px solid rgba(255,255,255,.1); - .docs-footer-content { + .docs-footer-text, + .docs-footer-links { color: rgba(255,255,255,.5); a { - font-weight: bold; color: rgba(255,255,255,.8); } } @@ -656,11 +674,11 @@ hr { // Tablet to desktop @media screen and (min-width: 768px) { .docs-header { - min-height: 830px; + min-height: 870px; // Ads on the homepage .carbonad { - bottom: 180px !important; + bottom: 259px !important; left: 50% !important; margin-left: -165px !important; } @@ -682,7 +700,7 @@ hr { @include transform(translateX(0)); } .docs-header-content { - top: 32%; + top: 30%; @include transform(translateY(-50%)); .btn {