Skip to content

Docs #1147

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 169 commits into from
Apr 17, 2020
Merged

Docs #1147

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
169 commits
Select commit Hold shift + click to select a range
029ef15
Initial commit
Andy-set-studio Jun 11, 2019
1466b79
Initial with basic files
Andy-set-studio Jun 11, 2019
aad55f9
Merge pull request #2 from andybelldesign/feature/jsdom-integration
Andy-set-studio Jun 13, 2019
160c195
Merge pull request #6 from andybelldesign/feature/front-end-first-pass
Andy-set-studio Jun 17, 2019
9f60aa3
Merge pull request #7 from andybelldesign/feature/rss
Andy-set-studio Jun 18, 2019
14e01cc
Add compact modifier to intro
Andy-set-studio Jun 18, 2019
7de7a9d
Merge branch 'master' of github.com:andybelldesign/hylia
Andy-set-studio Jun 18, 2019
c0e7e90
Fix build task
Andy-set-studio Jun 18, 2019
467d0d9
Merge branch 'master' of github.com:andybelldesign/hylia
Andy-set-studio Jun 18, 2019
fb7db02
Rename build task
Andy-set-studio Jun 18, 2019
41882cf
Update Pages “home”
Andy-set-studio Jun 18, 2019
7d5cb11
Reset CMS test content
Andy-set-studio Jun 18, 2019
be50b38
Create a quick generic page template
Andy-set-studio Jun 18, 2019
0c3f101
Wire up the navigation CMS
Andy-set-studio Jun 18, 2019
8113a38
Wire up design tokens to CMS
Andy-set-studio Jun 18, 2019
01625ab
Wire up design tokens to CMS
Andy-set-studio Jun 18, 2019
8af7701
Add netlify config
Andy-set-studio Jun 18, 2019
f694286
Tweak highlight styles
Andy-set-studio Jun 18, 2019
f0e3fc0
Implement basic service worker
Andy-set-studio Jun 18, 2019
7a1b3cf
Minify all the things
Andy-set-studio Jun 18, 2019
3b32f2a
Ignore compiled CSS
Andy-set-studio Jun 18, 2019
b100795
Add video player transform
Andy-set-studio Jun 18, 2019
e61ab9f
Add syntax highlighting
Andy-set-studio Jun 18, 2019
e6d241d
Add stub posts, ready for CMS
Andy-set-studio Jun 18, 2019
7ba0435
CMS fixes
Andy-set-studio Jun 18, 2019
fc47a9b
Tweaks to service worker for CMS
Andy-set-studio Jun 18, 2019
0ce77c3
Add images pass-through
Andy-set-studio Jun 18, 2019
52d0913
Tweak intro
Andy-set-studio Jun 18, 2019
abd728b
Merge branch 'master' of github.com:andybelldesign/hylia
Andy-set-studio Jun 18, 2019
85c676e
Link styling tweak
Andy-set-studio Jun 18, 2019
9b639ee
Social images tweak
Andy-set-studio Jun 18, 2019
49106c4
Merge branch 'master' of github.com:andybelldesign/hylia
Andy-set-studio Jun 18, 2019
a4bac5a
Fix up design tokens CMS config
Andy-set-studio Jun 18, 2019
2df6ad5
Merge branch 'master' of github.com:andybelldesign/hylia
Andy-set-studio Jun 18, 2019
6506f7e
Merge pull request #13 from andybelldesign/cms/nav
Andy-set-studio Jun 18, 2019
053f293
Merge pull request #12 from andybelldesign/cms/home
Andy-set-studio Jun 18, 2019
d42f8d1
Upload “/src/images/demo-image-1.jpg”
Andy-set-studio Jun 19, 2019
ab690a3
Merge pull request #14 from andybelldesign/cms/a-simple-post
Andy-set-studio Jun 19, 2019
e7c2359
Merge pull request #16 from andybelldesign/cms/a-post-with-code-samples
Andy-set-studio Jun 19, 2019
923cd74
Post content tweaks
Andy-set-studio Jun 19, 2019
7f55c1d
Intro tweaks
Andy-set-studio Jun 19, 2019
e79404c
Tweak admin config
Andy-set-studio Jun 19, 2019
a11c6e0
Some bleed out tweaks
Andy-set-studio Jun 19, 2019
0afc233
Add tag title
Andy-set-studio Jun 19, 2019
7eada7b
Merge branch 'master' of github.com:andybelldesign/hylia
Andy-set-studio Jun 19, 2019
d9dfb54
Merge pull request #27 from andybelldesign/cms/a-post-with-figures-an…
Andy-set-studio Jun 19, 2019
b9a25ac
Upload “/src/images/social-share.jpg”
Andy-set-studio Jun 19, 2019
131fb93
Add contributing guide
Andy-set-studio Jun 19, 2019
2d23722
Tweak styleguide
Andy-set-studio Jun 19, 2019
aeaa5c9
First pass at readme
Andy-set-studio Jun 19, 2019
da32c45
Another docs pass
Andy-set-studio Jun 19, 2019
966b4df
Add Sass docs
Andy-set-studio Jun 19, 2019
1604b91
Tweak spacing
Andy-set-studio Jun 19, 2019
42d0292
Edit readme
Andy-set-studio Jun 19, 2019
3e532b9
Readme tweak
Andy-set-studio Jun 19, 2019
ab3f00a
Update readme
Andy-set-studio Jun 19, 2019
9c75418
Fix overflow whoopsie
Andy-set-studio Jun 19, 2019
5db2eb0
Update readme with CMS guide
Andy-set-studio Jun 20, 2019
fad31ae
Add quick start video
Andy-set-studio Jun 20, 2019
c4effeb
Update readme
Andy-set-studio Jun 20, 2019
415ddba
Add cdata wrapper for content
Andy-set-studio Jun 20, 2019
cf173a5
Merge pull request #32 from andybelldesign/fix/add-missing-page-config
Andy-set-studio Jun 21, 2019
6771625
Merge pull request #35 from andybelldesign/fix/cms-page-config
Andy-set-studio Jun 21, 2019
320737f
Merge pull request #38 from erquhart/enable-identity
Andy-set-studio Jun 21, 2019
97a64c9
Merge pull request #37 from d2s/d2s-fix-text-improvements
Andy-set-studio Jun 21, 2019
7d7f865
Version bump
Andy-set-studio Jun 21, 2019
2ba6bcc
Merge pull request #42 from brendansparrow/patch-1
Andy-set-studio Jun 22, 2019
66c24a1
Merge pull request #43 from erquhart/custom-previews
Andy-set-studio Jun 22, 2019
d329c02
Merge pull request #41 from marcusrelacion/master
Andy-set-studio Jun 22, 2019
836b28b
Bump version
Andy-set-studio Jun 22, 2019
66f7f1d
Merge pull request #46 from MadeByMike/master
Andy-set-studio Jun 24, 2019
c11bc63
Bump version
Andy-set-studio Jun 24, 2019
5e7c0b9
Merge pull request #47 from juanfernandes/patch-1
Andy-set-studio Jun 24, 2019
1d4f90b
Merge pull request #49 from remy/master
Andy-set-studio Jun 25, 2019
075f106
Pre-release tweaks
Andy-set-studio Jun 25, 2019
1b5ffae
Merge pull request #50 from 36degrees/fix-typo-scheduled-blog-post
Andy-set-studio Jun 25, 2019
83ac6a4
Version bump
Andy-set-studio Jun 25, 2019
2f72b44
Merge pull request #51 from andybelldesign/feature/dark-mode
Andy-set-studio Jul 1, 2019
fbd2f9f
Add native video to full bleed CSS rules
Andy-set-studio Jul 1, 2019
0fa5767
Bump versions
Andy-set-studio Jul 1, 2019
4f0eb6b
Merge pull request #53 from andybelldesign/feature/general-ui-improve…
Andy-set-studio Jul 2, 2019
10267b3
Bump versions
Andy-set-studio Jul 2, 2019
2f3058f
Add canonical url
Andy-set-studio Jul 3, 2019
e134e55
Merge pull request #61 from andybelldesign/feature/general-ui-improve…
Andy-set-studio Jul 16, 2019
623e6d7
Merge pull request #60 from brandonaaron/exclude-scheduled-posts
Andy-set-studio Jul 16, 2019
5c07303
Merge pull request #59 from brandonaaron/sticky-footer
Andy-set-studio Jul 16, 2019
764571f
Merge pull request #62 from Jolg42/patch-1
Andy-set-studio Jul 17, 2019
50fc8b6
Bump
Andy-set-studio Jul 17, 2019
356522e
Bump
Andy-set-studio Jul 17, 2019
d6e48ee
Merge pull request #63 from AutoSponge/master
Andy-set-studio Jul 22, 2019
ebd85f6
Merge pull request #65 from erquhart/patch-1
Andy-set-studio Jul 22, 2019
4f45cfa
Merge pull request #68 from chrisburnell/patch-1
Andy-set-studio Aug 14, 2019
ac6c108
Update Stalfos reference
Andy-set-studio Aug 15, 2019
bfb05af
Bump
Andy-set-studio Aug 15, 2019
c062ee6
Merge pull request #72 from MikaCaldera/master
Andy-set-studio Aug 22, 2019
66681a9
Merge pull request #74 from erquhart/fix/rollup-plugin-vulnerability
Andy-set-studio Sep 7, 2019
48e10fc
Bump
Andy-set-studio Sep 7, 2019
adb7271
Bump
Andy-set-studio Sep 7, 2019
9c489ae
Merge pull request #77 from charlesroper/master
Andy-set-studio Sep 17, 2019
20fb359
Merge pull request #78 from dberesford/master
Andy-set-studio Sep 18, 2019
3bd36db
Merge pull request #80 from dberesford/master
Andy-set-studio Sep 18, 2019
8e3c878
Update my handle
Andy-set-studio Sep 20, 2019
bea6b53
Merge pull request #82 from hankchizljaw/feature/0.5.0
Andy-set-studio Sep 20, 2019
0bc1015
Update default pointer
Andy-set-studio Sep 23, 2019
3eec9e3
Merge pull request #88 from MrJean/fix/add-slate-to-config
Andy-set-studio Oct 7, 2019
fa461f5
Merge pull request #86 from acarlson0000/feature/update-documentation
Andy-set-studio Oct 7, 2019
d693d8d
Bump
Andy-set-studio Oct 7, 2019
83a4d1e
Bump
Andy-set-studio Oct 7, 2019
7bc506b
Add swap font display rule
Andy-set-studio Nov 6, 2019
b2ea5a7
Remove font preload
Andy-set-studio Nov 6, 2019
497933d
Initial commit
bradfrost Nov 7, 2019
f4e897d
Update favicon
bradfrost Nov 8, 2019
42e57a7
Remove third-party comments
bradfrost Nov 8, 2019
076d130
Remove third-party comments
bradfrost Nov 8, 2019
73e2592
Move meta-info into components
bradfrost Nov 8, 2019
03e038c
Remove service worker
bradfrost Nov 8, 2019
0a6ffff
Clean up header
bradfrost Nov 8, 2019
e1acd43
Add docs conent from PL website
bradfrost Nov 8, 2019
940c6d8
Feature: import docs WIP
bradfrost Nov 8, 2019
b9e5794
Add tree nav; wire up docs WIP
bradfrost Nov 12, 2019
9c189b1
Remove docs list
bradfrost Nov 12, 2019
49e1806
Move php docs (temporarily?)
bradfrost Nov 21, 2019
30e86cd
Change global.css => style.css; include as linked file
bradfrost Nov 21, 2019
5c16791
Remove unused include
bradfrost Nov 21, 2019
6482d7c
Style changes; heading permalink styles
bradfrost Nov 21, 2019
9c553f6
Change getting started link
bradfrost Nov 21, 2019
4080af5
Global site info WIP
bradfrost Nov 21, 2019
3cad0d4
Tone down transparent colors
bradfrost Nov 21, 2019
5f08b7a
Permalink styles
bradfrost Nov 21, 2019
d26045b
Add primary nav JS
bradfrost Nov 22, 2019
0c06b67
Remove tags
bradfrost Nov 22, 2019
a02d000
Add new pages
bradfrost Nov 22, 2019
3581f4f
Add additional content WIP
bradfrost Nov 22, 2019
405bfe3
Update installation instructions
bradfrost Nov 22, 2019
b6c28ef
Style formatting
bradfrost Nov 22, 2019
4782cbd
Add rotating atom logo
bradfrost Nov 27, 2019
bc360f9
Focus states
bradfrost Nov 27, 2019
efe5c37
Navigation WIP
bradfrost Nov 27, 2019
cebf0c9
Nav active states
bradfrost Nov 27, 2019
2d77ed8
Add prism syntax highlighting
bradfrost Nov 27, 2019
724c7dc
Update raw tags
bradfrost Nov 27, 2019
c00e71f
Homepage WIP
bradfrost Nov 27, 2019
0039574
Homepage WIP
bradfrost Dec 23, 2019
bc10471
Merge pull request #14 from bradfrost/feature/build-resources-page
bradfrost Jan 3, 2020
e12d020
Merge pull request #13 from bradfrost/feature/add-aria-to-dropdown-lists
bradfrost Jan 3, 2020
42c1273
Merge pull request #17 from bradfrost/feature/Handle-PHP-in-the-docs
bradfrost Jan 19, 2020
42cdd92
Merge pull request #18 from bradfrost/feature/remove-old-doc-pages
bradfrost Jan 21, 2020
818a1fc
Merge pull request #19 from bradfrost/feature/update-blog-posts
QuincyGow Jan 22, 2020
b406394
Merge pull request #20 from bradfrost/revert-19-feature/update-blog-p…
bradfrost Jan 23, 2020
08cc07f
bug fix to master for blog
QuincyGow Jan 23, 2020
49d35c5
Merge branch 'feature/scrub-hylia' of github.com:bradfrost/pl-website…
bradfrost Feb 3, 2020
84026cc
Merge branch 'master' of github.com:bradfrost/pl-website-eleventy
bradfrost Feb 17, 2020
0d5fb07
Merge branch 'master' of github.com:bradfrost/pl-website-eleventy
bradfrost Mar 10, 2020
7560c04
Add ordered subnav
bradfrost Mar 10, 2020
4bdd649
Remove old doc
bradfrost Mar 18, 2020
3ac6fd9
Merge branch 'master' of github.com:bradfrost/pl-website-eleventy
bradfrost Mar 19, 2020
7269346
Merge branch 'master' of github.com:bradfrost/pl-website-eleventy
bradfrost Mar 23, 2020
f7bff95
Homepage design WIP
bradfrost Mar 25, 2020
f2f5711
Homepage WIP
bradfrost Mar 31, 2020
3a980ae
Homepage and nav cleanup
bradfrost Mar 31, 2020
ace9944
Adjust contrast of menu
bradfrost Mar 31, 2020
de888ec
Homepage style tweaks
bradfrost Mar 31, 2020
6b0a655
Merge branch 'feature/remove-old-doc-pages'
bradfrost Mar 31, 2020
75ce2e5
Homepage design
bradfrost Apr 3, 2020
029acd8
Add support page
bradfrost Apr 3, 2020
c1d72f5
Installation updates
bradfrost Apr 3, 2020
2a489c7
Installation instructions
bradfrost Apr 3, 2020
5a47dc7
feat(docs): yarnify
bmuenzenmeyer Apr 17, 2020
941df8a
feat(README): add netlify badges
bmuenzenmeyer Apr 17, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ If you'd like to see what a front-end project built with Pattern Lab looks like,
[![node (scoped)](https://img.shields.io/node/v/@pattern-lab/patternlab-node.svg)]()
[![Join the chat at Gitter](https://badges.gitter.im/pattern-lab/node.svg)](https://gitter.im/pattern-lab/node)

Docs @ [![Netlify Status](https://api.netlify.com/api/v1/badges/d454dbde-02c5-4bd4-8393-4ab75e862b03/deploy-status)](https://app.netlify.com/sites/patternlab-docs-preview/deploys)

Pattern Lab Preview @ [![Netlify Status](https://api.netlify.com/api/v1/badges/a6db1666-cb4f-4d26-82d4-9d88d875f286/deploy-status)](https://app.netlify.com/sites/patternlab-handlebars-preview/deploys)

## Using Pattern Lab

Refer to the [core usage guidelines](https://github.com/pattern-lab/patternlab-node/blob/master/packages/core/README.md#usage)
Expand Down
2 changes: 1 addition & 1 deletion netlify.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[context.deploy-preview]
command = "npm run setup && npm run preview:hbs"
command = "yarn setup && yarn preview:hbs && yarn preview:docs"
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
"clean": "git clean -dfx",
"publish": "npx lerna publish -m \"[skip travis] chore(release): publish %s\"",
"postpublish": "auto release",
"preview:docs": "cd packages/docs && yarn production",
"preview:hbs": "cd packages/development-edition-engine-handlebars && npx patternlab add --starterkits @pattern-lab/starterkit-handlebars-vanilla && npm run pl:build"
},
"nyc": {
Expand Down
96 changes: 96 additions & 0 deletions packages/docs/.eleventy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
const rssPlugin = require('@11ty/eleventy-plugin-rss');
const syntaxHighlight = require('@11ty/eleventy-plugin-syntaxhighlight');
const eleventyNavigationPlugin = require('@11ty/eleventy-navigation');
const fs = require('fs');

// Import filters
const dateFilter = require('./src/filters/date-filter.js');
const markdownFilter = require('./src/filters/markdown-filter.js');
const w3DateFilter = require('./src/filters/w3-date-filter.js');

// Import transforms
const htmlMinTransform = require('./src/transforms/html-min-transform.js');
const parseTransform = require('./src/transforms/parse-transform.js');

// Import data files
const site = require('./src/_data/site.json');

module.exports = function(config) {
// Filters
config.addFilter('dateFilter', dateFilter);
config.addFilter('markdownFilter', markdownFilter);
config.addFilter('w3DateFilter', w3DateFilter);

// Layout aliases
config.addLayoutAlias('home', 'layouts/home.njk');

// Transforms
config.addTransform('htmlmin', htmlMinTransform);
config.addTransform('parse', parseTransform);

// Passthrough copy
config.addPassthroughCopy('src/images');
config.addPassthroughCopy('src/js');
config.addPassthroughCopy('src/admin/config.yml');
config.addPassthroughCopy('src/admin/previews.js');
config.addPassthroughCopy('node_modules/nunjucks/browser/nunjucks-slim.js');

const now = new Date();

// Custom collections
const livePosts = post => post.date <= now && !post.data.draft;
config.addCollection('posts', collection => {
return [
...collection.getFilteredByGlob('./src/posts/*.md').filter(livePosts)
].reverse();
});

config.addCollection('demos', collection => {
return [...collection.getFilteredByGlob('./src/demos/*.md')].reverse();
});

config.addCollection('postFeed', collection => {
return [...collection.getFilteredByGlob('./src/posts/*.md').filter(livePosts)]
.reverse()
.slice(0, site.maxPostsPerPage);
});

config.addCollection('docs', collection => {
return [...collection.getFilteredByGlob('./src/docs/*.md')].reverse();
});

config.addCollection('docsOrdered', collection => {
const docs = collection.getFilteredByGlob('src/docs/*.md').sort((a, b) => {
return Number(a.data.order) - Number(b.data.order);
});
return docs;
});

// Plugins
config.addPlugin(rssPlugin);
config.addPlugin(syntaxHighlight);
config.addPlugin(eleventyNavigationPlugin);

// 404
config.setBrowserSyncConfig({
callbacks: {
ready: function(err, browserSync) {
const content_404 = fs.readFileSync('dist/404.html');

browserSync.addMiddleware('*', (req, res) => {
// Provides the 404 content without redirect.
res.write(content_404);
res.end();
});
}
}
});

return {
dir: {
input: 'src',
output: 'dist'
},
passthroughFileCopy: true
};
};
17 changes: 17 additions & 0 deletions packages/docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
*.log
npm-debug.*
*.scssc
*.log
*.swp
.DS_Store
.sass-cache
node_modules
dist

# Specifics

# Hide design tokens
src/scss/_tokens.scss

# Hide compiled CSS
src/_includes/assets/*
7 changes: 7 additions & 0 deletions packages/docs/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"printWidth": 90,
"useTabs": true,
"tabWidth": 2,
"singleQuote": true,
"bracketSpacing": false
}
17 changes: 17 additions & 0 deletions packages/docs/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Launch Program",
"skipFiles": [
"<node_internals>/**"
],
"program": "${workspaceFolder}/index.js"
}
]
}
21 changes: 21 additions & 0 deletions packages/docs/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2019 andy-bell.design and other contributors

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.
32 changes: 32 additions & 0 deletions packages/docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Pattern Lab Website

This is the website for patternlab.io. This site was build using the [Hylia starter kit](https://hylia.website/), which is a lightweight [Eleventy](https://11ty.io) starter kit.

---

## How to work with this project

1. Clone this repository
2. `cd` into the project directory and run `yarn`
3. Once all the dependencies are installed run `yarn start`
4. Open your browser at `http://localhost:8080`

## Terminal commands

### Serve the site locally

```bash
yarn start
```

### Build a production version of the site

```bash
yarn production
```

### Compile Sass

```bash
yarn sass:process
```
52 changes: 52 additions & 0 deletions packages/docs/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"name": "patternlab-website",
"version": "0.1.0",
"description": "The website for patternlab.io",
"main": "index.js",
"dependencies": {
"@11ty/eleventy": "^0.8.3",
"@11ty/eleventy-plugin-rss": "^1.0.6",
"@11ty/eleventy-plugin-syntaxhighlight": "^2.0.3",
"@tbranyen/jsdom": "^13.0.0",
"concurrently": "^4.1.0",
"html-minifier": "^4.0.0",
"json-to-scss": "^1.3.1",
"sass": "^1.21.0",
"semver": "^6.3.0",
"slugify": "^1.3.4",
"stalfos": "github:hankchizljaw/stalfos#c8971d22726326cfc04089b2da4d51eeb1ebb0eb"
},
"devDependencies": {
"@11ty/eleventy-navigation": "^0.1.5",
"@erquhart/rollup-plugin-node-builtins": "^2.1.5",
"bl": "^3.0.0",
"chokidar-cli": "^2.0.0",
"cross-env": "^5.2.0",
"make-dir-cli": "^2.0.0",
"prettier": "^1.18.2",
"rollup": "^1.16.1",
"rollup-plugin-commonjs": "^10.0.0",
"rollup-plugin-json": "^4.0.0",
"rollup-plugin-node-resolve": "^5.0.3"
},
"scripts": {
"sass:tokens": "npx json-to-scss src/_data/tokens.json src/scss/_tokens.scss",
"sass:process": "yarn sass:tokens && sass src/scss/style.scss dist/css/style.css --style=compressed",
"cms:precompile": "make-dir dist/admin && nunjucks-precompile src/_includes > dist/admin/templates.js -i \"\\.(njk|css|svg)$\"",
"cms:bundle": "rollup --config",
"start": "concurrently \"yarn sass:process -- --watch\" \"yarn cms:bundle -- --watch\" \"chokidar \\\"src/_includes/**\\\" -c \\\"yarn cms:precompile\\\"\" \"yarn serve\"",
"serve": "cross-env ELEVENTY_ENV=development npx eleventy --serve",
"production": "yarn sass:process && yarn cms:precompile && yarn cms:bundle && npx eleventy"
},
"repository": {
"type": "git",
"url": "git+https://github.com/bradfrost/pl-website-eleventy.git"
},
"keywords": [],
"author": "",
"license": "MIT",
"bugs": {
"url": "https://github.com/bradfrost/pl-website-eleventy/issues"
},
"homepage": "https://github.com/bradfrost/pl-website-eleventy/#readme"
}
55 changes: 55 additions & 0 deletions packages/docs/php-docs/advanced-auto-regenerate.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
---
title: Watching for Changes and Auto Regenerating Patterns
tags:
- docs
---

Pattern Lab can watch for changes to files in `./source/` and automatically rebuild the entire Pattern Lab website for you. Make your changes, save the file, and Pattern Lab takes care of the rest.

## How to Start Watching for Changes

To start watching for changes do the following:

1. In a terminal window navigate to the root of your project
2. Type `php core/console --watch`

To stop watching files use `CTRL+C` in the same terminal window.

### Only Watch for Changes to Pattern Lab Files

If you use a task runner like Gulp or Grunt to compile Sass, JavaScript or images you may want Pattern Lab to only concern itself with its own files. To limit Pattern Lab to watch and move only its files do the following:

1. In a terminal window navigate to the root of your project
2. Type `php core/console --watch --patternsonly`

Or, better yet, use this command within your Gulp or Grunt script.

### Start the Web Server & Watch for Changes at the Same Time

If you're relying on Pattern Lab's server to view your content you'll want to run the watch and server with the same command. Do the following:

1. In a terminal window navigate to the root of your project
2. Type `php core/console --server --with-watch`

You can also start the server and watch only patterns:

1. In a terminal window navigate to the root of your project
2. Type `php core/console --server --with-watch --patternsonly`

To stop the server and watching files use `CTRL+C` in the same terminal window.

### Start the Web Server, Watch for Changes, and Reload the Browser at the Same Time

The ultimate solution for working with Pattern Lab if you're not using a task runner is Pattern Lab's [Auto-Reload Plugin](https://github.com/pattern-lab/plugin-php-reload). Do the following:

1. In a terminal window navigate to the root of your project
2. Install the [Auto-Reload Plugin](https://github.com/pattern-lab/plugin-php-reload) using `composer require pattern-lab/plugin-reload`
3. Type `php core/console --server --with-watch`

The Auto-Reload Plugin is automatically enabled when you install it. You can always [disable the plugin](https://github.com/pattern-lab/plugin-php-reload#disabling-the-plugin) if you need to.

To stop the server, watching files, and auto-reload service use `CTRL+C` in the same terminal window.

## What Pattern Lab Will Watch

By default, the PHP version of Pattern Lab will watch all files in `./source` except those that match the "ignore" configuration options in `config/config.yml`. When using `--patternsonly` Pattern Lab will only watch those directories in `./source` that start with an underscore. For example, `_patterns`. To learn how to modify what is ignored check out "[Managing Assets for a Pattern](/docs/pattern-managing-assets.html)".
5 changes: 5 additions & 0 deletions packages/docs/php-docs/advanced-clean-public.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
title: Stopping public/ from Being "Cleaned"
tags:
- docs
---
7 changes: 7 additions & 0 deletions packages/docs/php-docs/advanced-config-options.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: Editing the Configuration Options
tags:
- docs
---

Pattern Lab comes with a simple configuration file that allows you to modify certain aspects of the system. The configuration file can be found in `./config/config.yml`.
17 changes: 17 additions & 0 deletions packages/docs/php-docs/advanced-exporting-patterns.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
title: Exporting Patterns
tags:
- docs
---

Pattern Lab can export all of your patterns for you sans Pattern Lab's CSS and JavaScript. To export your patterns do the following:

1. In a terminal window navigate to the root of your project
2. Type `php core/console --export`

If you require your patterns to be exported without your global header and footer (_e.g. to export a clean molecule_) do the following:

1. In a terminal window navigate to the root of your project
2. Type `php core/console --export --clean`

In both cases the patterns will be exported to `./export/patterns`. The export directory is one of the many directories that can be [configured and changed](/docs/editing-source-files.html).
7 changes: 7 additions & 0 deletions packages/docs/php-docs/advanced-page-follow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
title: Multi browser & Multi device Testing with Page Follow
tags:
- docs
---

An auto-reload service was built into Pattern Lab 1. With Pattern Lab 2 this feature has been removed. This feature may return as a plugin in the same way that the [Auto-Reload service](/docs/advanced-reload-browser.html) did.
29 changes: 29 additions & 0 deletions packages/docs/php-docs/advanced-pattern-lab-nav.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
title: Modifying Pattern Lab's Navigation
tags:
- docs
---

When sharing Pattern Lab with a client it may be beneficial to turn-off certain elements in the default navigation. To turn-off navigation elements do the following:

1. Open `./config/config.yml`
2. Add the keys for the elements you'd like to hide to the `ishControlsHide` configuration option
3. Re-generate your Pattern Lab site

The following keys are supported and will hide their respective elements:

```
s
m
l
full
random
disco
hay
find
views-new
tools-all
tools-docs
```

`hay` is disabled by default.
Loading