Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
uglymunky committed Apr 24, 2015
0 parents commit 35460af
Show file tree
Hide file tree
Showing 425 changed files with 40,926 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .gitignore
@@ -0,0 +1,11 @@
.DS_Store
public/*
source/css/*.css
source/css/*.css.map
source/dep
node_modules
bower_components
config.ini
latest-change.txt
*-ck.js
*.sass-cache/
205 changes: 205 additions & 0 deletions CHANGELOG
@@ -0,0 +1,205 @@
THIS CHANGELOG IS AN ATTEMPT TO DOCUMENT CHANGES TO THIS PROJECT.

PL-v0.7.12
- FIX: making sure only the hostname shows up for the websocket servers. no ports.
- THX: thanks to @levito for the pull request

PL-v0.7.11
- FIX: migrator now orders migrations properly for ubuntu
- THX: thanks to @krulik for reporting the issue & @paulovieira for confirming the fix

PL-v0.7.10
- ADD: more responsive pull bar
- THX: thanks to @crohrer for the pull request making the pull bar more responsive

PL-v0.7.9
- ADD: .sass-cache now ignored by default
- ADD: configuration options to disable loading of page follow & auto-reload
- ADD: configuration option to set cacheBuster to 0
- ADD: configuration option to enable QR code feature
- ADD: configuration option to set minimum & maximum widths for the viewport resizer
- ADD: command line flag for generating only the patterns
- ADD: command line flag to set cacheBuster to 0
- ADD: better handling of missing required directories in public/
- ADD: added a styleguide-specific.css to better manage classes
- FIX: updated the console help output
- FIX: removed everything in public/ except the README
- FIX: removed the CDN version of jQuery
- FIX: toolbar styles updated
- FIX: icon font for the toolbar is no longer influencing the icon font of the patterns
- FIX: updated the styles for the "find a pattern" field
- FIX: code/annotations views now properly hide on resizing
- FIX: states.css removed and those styles loaded into styleguide.css
- FIX: default images updated
- FIX: removed hay mode from the tool bar by default. can be added back in by editing config.ini
- FIX: general pattern clean-up and re-styling to better match pattern lab's capabilities
- THX: thanks to @illepic for the .sass-cache PR

PL-v0.7.8
- ADD: can show annotations on view-all pages by default
- FIX: can target pattern divs and apply annotations

PL-v0.7.7
- ADD: can hide all of the patterns for a given pattern type from being shown on the styleguide. good for nested pages/templates
- FIX: the MQ menu is hidden on smaller viewports

PL-v0.7.6
- FIX: pattern search now searches the entire name of a pattern
- FIX: the MQ menu lines up with the navigation item

PL-v0.7.5
- ADD: a quick pattern search using typeahead
- ADD: keyboard shortcuts for a bunch of features using jwerty
- ADD: using cmd+a/ctrl+a when in code view selects the contents of the currently active tab
- ADD: code and annotation views can be opened automatically on load via query string params
- ADD: can use the config to remove items from pattern nav
- ADD: check for json support now that certain flavors of PHP 5.5.3 don't come with it
- ADD: can use boolean vars to enable/disable sections via pattern parameters
- ADD: pattern states for tracking progress on individual patterns
- FIX: updated icomoon icons
- FIX: code view has tabs
- FIX: code view shows mustache versions of a pattern
- FIX: patterns are properly sorted in style guide and view all views
- FIX: pattern lab-specific JS & CSS is only loaded when in the iframe
- FIX: classlist polyfill for better IE9 support
- FIX: stringified the postmessage messages for better IE9 support
- FIX: make sure history is only used by browsers that support it (e.g. IE9 doesn't)
- FIX: using watcher-launched auto-reload server now works on Windows
- FIX: various bugs with lineage
- FIX: vendored third-party JS and CSS
- FIX: infinite refresh bug squashed
- THX: thanks to @joshrcook for some styling fixes and hitting on the cause of the start-up issues on ubuntu
- THX: thanks to @tylersticka for lots of ideas: pattern states, cmd+a, boolean pattern parameters and the feedback on the watcher
- THX: thanks to @nikvm for the fix for properly sorting the styleguide view
- THX: thanks to @aarongustafson for the idea to only load the JS when it's in the iframe

PL-v0.7.2
- FIX: proper support for Windows with the changes that happened in v0.7.0
- THX: thanks to @chriskevin and @MattKohnen for reporting the issue

PL-v0.7.1
- FIX: annotation event should only fire when overlay is active
- FIX: styleguide should properly sort patterns
- THX: thanks to @jplhomer for the heads up on the annotations issue
- THX: thanks to @tylersticka for the heads up on the styleguide issue

PL-v0.7.0
- ADD: auto-reload server can be started directly from the watcher
- ADD: pattern parameter support
- ADD: styleModifier support
- ADD: pseudo-pattern support
- ADD: RAM usage now outputted when generating the site
- ADD: an easter egg
- ADD: configuration flag for cleanPublic
- ADD: dedicated pattern header and footer files
- ADD: QR code generator to make mobile testing easier
- ADD: reverse lineages to see where a pattern is used
- ADD: if _data.json contains a reserved keyword an error is thrown
- ADD: closer to being PSR-0 and PSR-1 compatible
- ADD: migrator class to handle file moves/updates between versions
- ADD: configurer class to handle managing the configuration file
- FIX: ran JS hint against project JavaScript
- FIX: attempted to add better cache busting
- FIX: reorganized the project for better upgradeability by moving lots to core/
- FIX: malformed JSON throws error and gives file name
- FIX: code view styles
- FIX: annotation styles and functionality are now more robust
- FIX: mobile styles are more robust including scrolling on iOS7
- FIX: drop down interaction
- FIX: refactored how patterns and view all pages are gathered and generated
- FIX: lineage list now hidden if pattern doesn't have a lineage
- FIX: listitems.json and data.json default attributes match
- FIX: an existing config.ini file is automatically updated with new version
- FIX: pull bar now works in Firefox
- FIX: history now works in Firefox
- FIX: renamed the websocket servers
- THX: thanks to @faustgertz for some fixes with the new watcher class
- THX: thanks to @coding-stuff for the original idea and original code for pattern parameters
- THX: thanks to @mattwellss for inspiring the PSR compliant changes as well as changes to the configuration

PL-v0.6.4
- FIX: using # for a link won't cause a jump
- THX: thanks to @tylersticka for the heads up

PL-v0.6.3
- FIX: making sure code view is properly encoded
- THX: thanks to @tylersticka for the heads up

PL-v0.6.2
- FIX: a few small sass and styling tweaks
- THX: thanks to @griffinartworks for the sass and styling fixes

PL-v0.6.1
- FIX: fixed the height of the HTML pre element on the pattern detail view
- ADD: added in support for viewing the generated CSS on the pattern detail view

PL-v0.6.0
- ADD: a UI list of the current media query widths from the CSS
- ADD: a pattern's "lineage" now displays in the UI under code view
- ADD: annotations can be added to DOM elements of patterns
- ADD: separate annotation views on the list view and pattern details views
- ADD: generate() now "cleans" public/ before generating the site by deleting most everything
- ADD: added support for the css rule saver library
- ADD: can use a flag to generate the specific CSS that is used in a pattern. shows on code view when available.
- ADD: mark-up for a pattern is now included in the UI under code view
- FIX: can open the "raw" version of a pattern in a new window
- FIX: frame resizing bar properly supports decimals
- FIX: the checkboxes for the websocket-based features, page follow & auto-reload, now work
- FIX: postmessage calls now centralized and refactored
- FIX: units appear in the toolbar when using Hay! mode
- FIX: patterns shouldn't be cached
- THX: thanks to @benedfit for the MQ idea which he originally named "phases"
- THX: thanks to @alienlebarge for the "clean public/" idea

PL-v0.3.6
- FIX: added a delay to the watcher so the CPU doesn't get maxed
- THX: thanks to martin berglund for the heads up

PL-v0.3.5
- ADD: an explicit MIT license
- FIX: updated .gitignore so that it's more flexible
- THX: thanks to @alienlebarge for the .gitignore fix

PL-v0.3.4
- FIX: Generator class renamed because it's a reserved name in PHP 5.5
- THX: thanks to @faustgertz for the heads up

PL-v0.3.3
- FIX: links created with {{ link.pattern }} now have the correct path
- FIX: links within a pattern now properly update the history
- FIX: simplified the history updates from a pattern
- THX: thanks to @kevin-heil for the fix for {{ link.pattern }}

PL-v0.3.2
- ADD: added .svn to the ignore dirs listing when checking the source dir
- FIX: top-level ignored dirs are now found properly
- THX: thanks to @alienlebarge for the heads up regarding .svn dirs

PL-v0.3.1
- FIX: made sure the command scripts work in directories that contain spaces
- THX: thanks to @mattsims for the heads up

PL-v0.3.0
- ADD: added "all" link to the nav that takes the user back to the style guide
- ADD: title tag updates when switching patterns
- FIX: if a pattern type or pattern sub-type doesn't have any patterns it's removed from the nav
- FIX: added styleguide.css to the pattern header
- FIX: commented out the video & audio patterns to address an issue w/ Chrome 29, frames, & History API
- FIX: reduced the number of comments called in the comment-thread pattern
- FIX: patterns won't try to auto-reload if viewed directly
- THX: thanks to @bmuenzenmeyer for the "all link" suggestion

PL-v0.2.0
- ADD: better styling in the overall navigation (via @geibi)
- FIX: better windows support for the generator and watcher
- FIX: more comprehensive "apache-less" support
- FIX: debian linux path issue when loading mustache
- FIX: pattern fix which mis-used an ID
- FIX: widths in 'ish are now properly updated onload
- THX: thanks to @benedfit & @bmuenzenmeyer for the help w/ windows
- THX: thanks to @geibi for the pull request with the improved nav style
- THX: thanks to @juanmi007 for alerting me to issues on debian
- THX: thanks to @lewisnyman for the pattern fix

PL-v0.1.0
- ADD: re-launch of the PHP version of Pattern Lab
58 changes: 58 additions & 0 deletions Gruntfile.js
@@ -0,0 +1,58 @@
module.exports = function(grunt) {

grunt.initConfig({
pkg: grunt.file.readJSON('package.json')

, copy: {
js: {
files: [
{src: 'bower_components/fastclick/lib/fastclick.js', dest: 'public/dep/fastclick/fastclick.js'}
, {src: 'bower_components/foundation/js/foundation.js', dest: 'public/dep/foundation/foundation.js'}
, {src: 'bower_components/jquery/dist/jquery.js', dest: 'public/dep/jquery/jquery.js'}
, {src: 'bower_components/modernizr/modernizr.js', dest: 'public/dep/modernizr/modernizr.js'}
]
}
}


, sass: {
options: {
includePaths: [
'bower_components/foundation/scss'
// @todo - should we also add bourbon? require('node-bourbon').includePaths
]
}
, dist: {
options: {
sourceMap: false
},

files: {
'source/css/styles.css': 'source/css/scss/styles.scss'
}
}
}


, shell: {
patternlab: {
command: "php core/builder.php -gp"
}
}


// copy foundation.js into public/js
// * install jquery and modernizr via bower
// * do we need fitvids?
// * replace fonts
// * replace images
// * delete source/css (use source/scss instead)
});

grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-sass');
grunt.loadNpmTasks('grunt-shell');
// @todo add livereload?

grunt.registerTask('compile', ['sass', 'shell:patternlab', 'copy']);
};
20 changes: 20 additions & 0 deletions LICENSE
@@ -0,0 +1,20 @@
The MIT License (MIT)

Copyright (c) 2013-14 Brad Frost, http://bradfrost.com & Dave Olsen, http://dmolsen.com

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
62 changes: 62 additions & 0 deletions README.md
@@ -0,0 +1,62 @@
## About Pattern Lab
- [Pattern Lab Website](http://patternlab.io/)
- [About Pattern Lab](http://patternlab.io/about.html)
- [Documentation](http://patternlab.io/docs/index.html)
- [Demo](http://demo.patternlab.io/)

The PHP version of Pattern Lab is, at its core, a static site generator. It combines platform-agnostic assets, like the [Mustache](http://mustache.github.io/)-based patterns and the JavaScript-based viewer, with a PHP-based "builder" that transforms and dynamically builds the Pattern Lab site. By making it a static site generator, Pattern Lab strongly separates patterns, data, and presentation from build logic.

## Demo

You can play with a demo of the front-end of Pattern Lab at [demo.patternlab.io](http://demo.patternlab.io).

## Getting Started

* [Requirements](http://patternlab.io/docs/requirements.html)
* [Installing the PHP Version of Pattern Lab](http://patternlab.io/docs/installation.html)
* [Upgrading the PHP Version of Pattern Lab](http://patternlab.io/docs/upgrading.html)
* [Generating the Pattern Lab Website for the First Time](http://patternlab.io/docs/first-run.html)
* [Editing the Pattern Lab Website Source Files](http://patternlab.io/docs/editing-source-files.html)
* [Using the Command-line Options](http://patternlab.io/docs/command-line.html)
* [Command Prompt on Windows](http://patternlab.io/docs/command-prompt-windows.html)

## Working with Patterns

Patterns are the core element of Pattern Lab. Understanding how they work is the key to getting the most out of the system. Patterns use [Mustache](http://mustache.github.io/) so please read [Mustache's docs](http://mustache.github.io/mustache.5.html) as well.

* [How Patterns Are Organized](http://patternlab.io/docs/pattern-organization.html)
* [Adding New Patterns](http://patternlab.io/docs/pattern-add-new.html)
* [Reorganizing Patterns](http://patternlab.io/docs/pattern-reorganizing.html)
* [Including One Pattern Within Another via Partials](http://patternlab.io/docs/pattern-including.html)
* [Managing Assets for a Pattern: JavaScript, images, CSS, etc.](http://patternlab.io/docs/pattern-managing-assets.html)
* [Modifying the Pattern Header and Footer](http://patternlab.io/docs/pattern-header-footer.html)
* [Using Pseudo-Patterns](http://patternlab.io/docs/pattern-pseudo-patterns.html)
* [Using Pattern Parameters](http://patternlab.io/docs/pattern-parameters.html)
* [Using Pattern State](http://patternlab.io/docs/pattern-states.html)
* ["Hiding" Patterns in the Navigation](http://patternlab.io/docs/pattern-hiding.html)
* [Adding Annotations](http://patternlab.io/docs/pattern-adding-annotations.html)
* [Viewing Patterns on a Mobile Device](http://patternlab.io/docs/pattern-mobile-view.html)

## Creating & Working With Dynamic Data for a Pattern

The PHP version of Pattern Lab utilizes Mustache as the template language for patterns. In addition to allowing for the [inclusion of one pattern within another](http://patternlab.io/docs/pattern-including.html) it also gives pattern developers the ability to include variables. This means that attributes like image sources can be centralized in one file for easy modification across one or more patterns. The PHP version of Pattern Lab uses a JSON file, `source/_data/data.json`, to centralize many of these attributes.

* [Introduction to JSON & Mustache Variables](http://patternlab.io/docs/data-json-mustache.html)
* [Overriding the Central `data.json` Values with Pattern-specific Values](http://patternlab.io/docs/data-pattern-specific.html)
* [Linking to Patterns with Pattern Lab's Default `link` Variable](http://patternlab.io/docs/data-link-variable.html)
* [Creating Lists with Pattern Lab's Default `listItems` Variable](http://patternlab.io/docs/data-listitems.html)

## Using Pattern Lab's Advanced Features

By default, the Pattern Lab assets can be manually generated and the Pattern Lab site manually refreshed but who wants to waste time doing that? Here are some ways that Pattern Lab can make your development workflow a little smoother:

* [Watching for Changes and Auto-Regenerating Patterns](http://patternlab.io/docs/advanced-auto-regenerate.html)
* [Auto-Reloading the Browser Window When Changes Are Made](http://patternlab.io/docs/advanced-reload-browser.html)
* [Multi-browser & Multi-device Testing with Page Follow](http://patternlab.io/docs/advanced-page-follow.html)
* [Keyboard Shortcuts](http://patternlab.io/docs/advanced-keyboard-shortcuts.html)
* [Special Pattern Lab-specific Query String Variables ](http://patternlab.io/docs/pattern-linking.html)
* [Preventing the Cleaning of public/](http://patternlab.io/docs/advanced-clean-public.html)
* [Generating CSS](http://patternlab.io/docs/advanced-generating-css.html)
* [Modifying the Pattern Lab Nav](http://patternlab.io/docs/advanced-pattern-lab-nav.html)
* [Editing the config.ini Options](http://patternlab.io/docs/advanced-config-options.html)
* [Integration with Compass](http://patternlab.io/docs/advanced-integration-with-compass.html)
22 changes: 22 additions & 0 deletions bower.json
@@ -0,0 +1,22 @@
{
"name": "patternlab-kiva",
"version": "1.0.0",
"homepage": "-",
"authors": [
"uglymunky <gabriel@uglymunky.com>"
],
"license": "MIT",
"private": true,
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"test",
"tests"
],
"dependencies": {
"foundation": "~5.5.1",
"jquery": "~2.1.3",
"modernizr": "~2.8.3"
}
}
1 change: 1 addition & 0 deletions config/README
@@ -0,0 +1 @@
After you generate Pattern Lab for the first time your configuration file will be placed here.

0 comments on commit 35460af

Please sign in to comment.