-
- Hey! Here's the Hello World component:
-
+
+
Hey! Here's the Hello World component:
);
diff --git a/packages/development-edition-engine-react/source/css/pattern-scaffolding.css b/packages/development-edition-engine-react/source/css/pattern-scaffolding.css
index 2a69457ed..b09172fc8 100644
--- a/packages/development-edition-engine-react/source/css/pattern-scaffolding.css
+++ b/packages/development-edition-engine-react/source/css/pattern-scaffolding.css
@@ -5,7 +5,7 @@
*/
#sg-patterns {
-webkit-box-sizing: border-box !important;
- box-sizing: border-box !important;
+ box-sizing: border-box !important;
max-width: 100%;
padding: 0 0.5em;
}
@@ -24,15 +24,15 @@
display: -ms-flexbox;
display: flex;
-ms-flex-wrap: wrap;
- flex-wrap: wrap;
+ flex-wrap: wrap;
list-style: none !important;
padding: 0 !important;
margin: 0 !important;
}
.sg-colors li {
-webkit-box-flex: 1;
- -ms-flex: auto;
- flex: auto;
+ -ms-flex: auto;
+ flex: auto;
padding: 0.3em;
margin: 0 0.5em 0.5em 0;
min-width: 5em;
diff --git a/packages/development-edition-engine-react/source/css/style.css b/packages/development-edition-engine-react/source/css/style.css
index 588a45915..04f745349 100644
--- a/packages/development-edition-engine-react/source/css/style.css
+++ b/packages/development-edition-engine-react/source/css/style.css
@@ -1,3 +1,3 @@
/*
* YOUR STYLES HERE
- */
\ No newline at end of file
+ */
diff --git a/packages/edition-node-gulp/CHANGELOG.md b/packages/edition-node-gulp/CHANGELOG.md
index afd205a81..70dfc5272 100644
--- a/packages/edition-node-gulp/CHANGELOG.md
+++ b/packages/edition-node-gulp/CHANGELOG.md
@@ -4,26 +4,20 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
+
# [2.0.0-alpha.15](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.14...@pattern-lab/edition-node-gulp@2.0.0-alpha.15) (2018-07-09)
**Note:** Version bump only for package @pattern-lab/edition-node-gulp
-
-
-
-
+
# [2.0.0-alpha.14](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.13...@pattern-lab/edition-node-gulp@2.0.0-alpha.14) (2018-07-06)
**Note:** Version bump only for package @pattern-lab/edition-node-gulp
-
-
-
-
-# [2.0.0-alpha.13](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.12...@pattern-lab/edition-node-gulp@2.0.0-alpha.13) (2018-07-06)
+# [2.0.0-alpha.13](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.12...@pattern-lab/edition-node-gulp@2.0.0-alpha.13) (2018-07-06)
### Features
@@ -31,53 +25,39 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/commit/5ab3995))
-
-
-
-
-# [2.0.0-alpha.12](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.11...@pattern-lab/edition-node-gulp@2.0.0-alpha.12) (2018-07-05)
+# [2.0.0-alpha.12](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.11...@pattern-lab/edition-node-gulp@2.0.0-alpha.12) (2018-07-05)
### Bug Fixes
* **gulp:** remove help command ([71575db](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/commit/71575db))
-
### Features
* **serve:** change calling method ([f47217a](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/commit/f47217a))
-
-
-
-# [2.0.0-alpha.11](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.10...@pattern-lab/edition-node-gulp@2.0.0-alpha.11) (2018-05-19)
-
-
+# [2.0.0-alpha.11](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.10...@pattern-lab/edition-node-gulp@2.0.0-alpha.11) (2018-05-19)
**Note:** Version bump only for package @pattern-lab/edition-node-gulp
-# [2.0.0-alpha.10](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.9...@pattern-lab/edition-node-gulp@2.0.0-alpha.10) (2018-05-04)
-
-
+# [2.0.0-alpha.10](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.9...@pattern-lab/edition-node-gulp@2.0.0-alpha.10) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/edition-node-gulp
-# [2.0.0-alpha.9](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.8...@pattern-lab/edition-node-gulp@2.0.0-alpha.9) (2018-05-04)
-
-
+# [2.0.0-alpha.9](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.8...@pattern-lab/edition-node-gulp@2.0.0-alpha.9) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/edition-node-gulp
-# [2.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.7...@pattern-lab/edition-node-gulp@2.0.0-alpha.8) (2018-05-04)
+# [2.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.7...@pattern-lab/edition-node-gulp@2.0.0-alpha.8) (2018-05-04)
### Features
@@ -88,14 +68,10 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** add cli as a dependency ([a52b487](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/commit/a52b487))
* **uikits:** remove workshop for default config ([55570ff](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/commit/55570ff))
-
### BREAKING CHANGES
* **API:** change `version()` to return a string representation of the version, removing `v()`
-
-
-
# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node-gulp/compare/@pattern-lab/edition-node-gulp@2.0.0-alpha.6...@pattern-lab/edition-node-gulp@2.0.0-alpha.7) (2018-03-21)
diff --git a/packages/edition-node/CHANGELOG.md b/packages/edition-node/CHANGELOG.md
index 2e6d295bb..fd4554dcf 100644
--- a/packages/edition-node/CHANGELOG.md
+++ b/packages/edition-node/CHANGELOG.md
@@ -4,29 +4,22 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-# [1.0.0-alpha.13](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.12...@pattern-lab/edition-node@1.0.0-alpha.13) (2018-07-09)
+# [1.0.0-alpha.13](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.12...@pattern-lab/edition-node@1.0.0-alpha.13) (2018-07-09)
### Features
* **scripts:** namespace scripts ([3ecbb3e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/commit/3ecbb3e))
-
-
-
-
+
# [1.0.0-alpha.12](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.11...@pattern-lab/edition-node@1.0.0-alpha.12) (2018-07-06)
**Note:** Version bump only for package @pattern-lab/edition-node
-
-
-
-
-# [1.0.0-alpha.11](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.10...@pattern-lab/edition-node@1.0.0-alpha.11) (2018-07-06)
+# [1.0.0-alpha.11](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.10...@pattern-lab/edition-node@1.0.0-alpha.11) (2018-07-06)
### Features
@@ -34,45 +27,33 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/commit/5ab3995))
-
-
-
-
-# [1.0.0-alpha.10](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.9...@pattern-lab/edition-node@1.0.0-alpha.10) (2018-07-05)
-
-
+# [1.0.0-alpha.10](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.9...@pattern-lab/edition-node@1.0.0-alpha.10) (2018-07-05)
**Note:** Version bump only for package @pattern-lab/edition-node
-# [1.0.0-alpha.9](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.8...@pattern-lab/edition-node@1.0.0-alpha.9) (2018-05-19)
-
-
+# [1.0.0-alpha.9](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.8...@pattern-lab/edition-node@1.0.0-alpha.9) (2018-05-19)
**Note:** Version bump only for package @pattern-lab/edition-node
-# [1.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.7...@pattern-lab/edition-node@1.0.0-alpha.8) (2018-05-04)
-
-
+# [1.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.7...@pattern-lab/edition-node@1.0.0-alpha.8) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/edition-node
-# [1.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.6...@pattern-lab/edition-node@1.0.0-alpha.7) (2018-05-04)
-
-
+# [1.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.6...@pattern-lab/edition-node@1.0.0-alpha.7) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/edition-node
-# [1.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.5...@pattern-lab/edition-node@1.0.0-alpha.6) (2018-05-04)
+# [1.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.5...@pattern-lab/edition-node@1.0.0-alpha.6) (2018-05-04)
### Features
@@ -80,9 +61,6 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **scripts:** refactor to use cli commands ([e8d5c21](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/commit/e8d5c21))
* **uikits:** uikits config ([027e56c](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/commit/027e56c))
-
-
-
# [1.0.0-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/edition-node/compare/@pattern-lab/edition-node@1.0.0-alpha.4...@pattern-lab/edition-node@1.0.0-alpha.5) (2018-03-21)
diff --git a/packages/engine-handlebars/CHANGELOG.md b/packages/engine-handlebars/CHANGELOG.md
index 92ddef103..6ac98f4e6 100644
--- a/packages/engine-handlebars/CHANGELOG.md
+++ b/packages/engine-handlebars/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-# [2.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/compare/@pattern-lab/engine-handlebars@2.0.0-alpha.7...@pattern-lab/engine-handlebars@2.0.0-alpha.8) (2018-07-06)
+# [2.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/compare/@pattern-lab/engine-handlebars@2.0.0-alpha.7...@pattern-lab/engine-handlebars@2.0.0-alpha.8) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/commit/5ab3995))
-
-
-
-
-# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/compare/@pattern-lab/engine-handlebars@2.0.0-alpha.6...@pattern-lab/engine-handlebars@2.0.0-alpha.7) (2018-07-05)
+# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/compare/@pattern-lab/engine-handlebars@2.0.0-alpha.6...@pattern-lab/engine-handlebars@2.0.0-alpha.7) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/commit/38a01b1))
-
-
-
-# [2.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/compare/@pattern-lab/engine-handlebars@2.0.0-alpha.5...@pattern-lab/engine-handlebars@2.0.0-alpha.6) (2018-05-04)
-
-
+# [2.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-handlebars/compare/@pattern-lab/engine-handlebars@2.0.0-alpha.5...@pattern-lab/engine-handlebars@2.0.0-alpha.6) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/engine-handlebars
diff --git a/packages/engine-liquid/CHANGELOG.md b/packages/engine-liquid/CHANGELOG.md
index 389219d6d..25592dc11 100644
--- a/packages/engine-liquid/CHANGELOG.md
+++ b/packages/engine-liquid/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-# [1.0.0-alpha.10](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-liquid/compare/@pattern-lab/engine-liquid@1.0.0-alpha.9...@pattern-lab/engine-liquid@1.0.0-alpha.10) (2018-07-06)
+# [1.0.0-alpha.10](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-liquid/compare/@pattern-lab/engine-liquid@1.0.0-alpha.9...@pattern-lab/engine-liquid@1.0.0-alpha.10) (2018-07-06)
### Features
@@ -13,15 +13,9 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-liquid/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-liquid/commit/5ab3995))
-
-
-
-
-# [1.0.0-alpha.9](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-liquid/compare/@pattern-lab/engine-liquid@1.0.0-alpha.8...@pattern-lab/engine-liquid@1.0.0-alpha.9) (2018-05-04)
-
-
+# [1.0.0-alpha.9](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-liquid/compare/@pattern-lab/engine-liquid@1.0.0-alpha.8...@pattern-lab/engine-liquid@1.0.0-alpha.9) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/engine-liquid
diff --git a/packages/engine-mustache/CHANGELOG.md b/packages/engine-mustache/CHANGELOG.md
index 3a65a3975..698db7c44 100644
--- a/packages/engine-mustache/CHANGELOG.md
+++ b/packages/engine-mustache/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-# [2.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/compare/@pattern-lab/engine-mustache@2.0.0-alpha.7...@pattern-lab/engine-mustache@2.0.0-alpha.8) (2018-07-06)
+# [2.0.0-alpha.8](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/compare/@pattern-lab/engine-mustache@2.0.0-alpha.7...@pattern-lab/engine-mustache@2.0.0-alpha.8) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/commit/5ab3995))
-
-
-
-
-# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/compare/@pattern-lab/engine-mustache@2.0.0-alpha.6...@pattern-lab/engine-mustache@2.0.0-alpha.7) (2018-07-05)
+# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/compare/@pattern-lab/engine-mustache@2.0.0-alpha.6...@pattern-lab/engine-mustache@2.0.0-alpha.7) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/commit/38a01b1))
-
-
-
-# [2.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/compare/@pattern-lab/engine-mustache@2.0.0-alpha.5...@pattern-lab/engine-mustache@2.0.0-alpha.6) (2018-05-04)
-
-
+# [2.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-mustache/compare/@pattern-lab/engine-mustache@2.0.0-alpha.5...@pattern-lab/engine-mustache@2.0.0-alpha.6) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/engine-mustache
diff --git a/packages/engine-mustache/package.json b/packages/engine-mustache/package.json
index 024ea8c6b..6116fe60b 100644
--- a/packages/engine-mustache/package.json
+++ b/packages/engine-mustache/package.json
@@ -5,7 +5,7 @@
"main": "lib/engine_mustache.js",
"dependencies": {
"fs-extra": "0.30.0",
- "mustache": "2.2.0"
+ "mustache": "2.3.0"
},
"keywords": [
"Pattern Lab",
diff --git a/packages/engine-nunjucks/CHANGELOG.md b/packages/engine-nunjucks/CHANGELOG.md
index 85b485607..c5f334584 100644
--- a/packages/engine-nunjucks/CHANGELOG.md
+++ b/packages/engine-nunjucks/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-## [0.1.4-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/compare/@pattern-lab/engine-nunjucks@0.1.4-alpha.3...@pattern-lab/engine-nunjucks@0.1.4-alpha.4) (2018-07-06)
+## [0.1.4-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/compare/@pattern-lab/engine-nunjucks@0.1.4-alpha.3...@pattern-lab/engine-nunjucks@0.1.4-alpha.4) (2018-07-06)
### Features
@@ -13,32 +13,22 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/commit/5ab3995))
-
-
-
-
-## [0.1.4-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/compare/@pattern-lab/engine-nunjucks@0.1.4-alpha.2...@pattern-lab/engine-nunjucks@0.1.4-alpha.3) (2018-07-05)
+## [0.1.4-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/compare/@pattern-lab/engine-nunjucks@0.1.4-alpha.2...@pattern-lab/engine-nunjucks@0.1.4-alpha.3) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/commit/38a01b1))
-
-
-
-## [0.1.4-alpha.2](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/compare/@pattern-lab/engine-nunjucks@0.1.4-alpha.1...@pattern-lab/engine-nunjucks@0.1.4-alpha.2) (2018-05-04)
+## [0.1.4-alpha.2](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/compare/@pattern-lab/engine-nunjucks@0.1.4-alpha.1...@pattern-lab/engine-nunjucks@0.1.4-alpha.2) (2018-05-04)
### Features
* **package:** add [@pattern-lab](https://github.com/pattern-lab)/cli as a dependency ([760d0e0](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-nunjucks/commit/760d0e0))
-
-
-
## 0.1.4-alpha.1 (2018-03-21)
diff --git a/packages/engine-nunjucks/README.md b/packages/engine-nunjucks/README.md
index 7a88645df..b85c5e5d7 100644
--- a/packages/engine-nunjucks/README.md
+++ b/packages/engine-nunjucks/README.md
@@ -17,10 +17,10 @@ Level of Support is more or less full. Partial calls and lineage hunting are sup
## Extending the Nunjucks instance
-To add custom filters or make customizations to the nunjucks instance, create a file named `patternlab-nunjucks-config.js` in the root of your Pattern Lab project. `patternlab-nunjucks-config.js` should export a function that takes two parameters. The first parameter is the nunjucks instance; the second is the nunjucks instance's environment.
+To add custom filters or make customizations to the nunjucks instance, create a file named `patternlab-nunjucks-config.js` in the root of your Pattern Lab project. `patternlab-nunjucks-config.js` should export a function with the Nunjucks environment as parameter.
```
-module.exports = function (nunjucks, env) {
+module.exports = function (env) {
[YOUR CUSTOM CODE HERE]
};
```
@@ -30,7 +30,7 @@ Example: `patternlab-nunjucks-config.js` file that uses lodash and adds three cu
var _shuffle = require('lodash/shuffle'),
_take = require('lodash/take');
-exports = module.exports = function (nunjucks, env) {
+exports = module.exports = function (env) {
env.addFilter('shorten', function (str, count) {
return str.slice(0, count || 5);
});
diff --git a/packages/engine-nunjucks/lib/engine_nunjucks.js b/packages/engine-nunjucks/lib/engine_nunjucks.js
index 5c149d3f9..92f5acb7e 100644
--- a/packages/engine-nunjucks/lib/engine_nunjucks.js
+++ b/packages/engine-nunjucks/lib/engine_nunjucks.js
@@ -20,48 +20,43 @@
'use strict';
-var fs = require('fs-extra'),
- path = require('path'),
- plPath = process.cwd(),
- plConfig = require(path.join(plPath, 'patternlab-config.json')),
- nunjucks = require('nunjucks'),
- env = nunjucks.configure(plConfig.paths.source.patterns),
- partialRegistry = [];
-
-////////////////////////////
-// LOAD ANY USER NUNJUCKS CONFIGURATIONS
-////////////////////////////
+const fs = require('fs-extra');
+const path = require('path');
+const plPath = process.cwd();
+const plConfig = require(path.join(plPath, 'patternlab-config.json'));
+const nunjucks = require('nunjucks');
+const partialRegistry = [];
+
+// Create Pattern Loader
+// Since Pattern Lab includes are not path based we need a custom loader for Nunjucks.
+function PatternLoader() {}
+
+PatternLoader.prototype.getSource = function(name) {
+ const fullPath = path.resolve(
+ plConfig.paths.source.patterns,
+ partialRegistry[name]
+ );
+ return {
+ src: fs.readFileSync(fullPath, 'utf-8'),
+ path: fullPath,
+ };
+};
+
+const env = new nunjucks.Environment(new PatternLoader());
+
+// Load any user Defined configurations
try {
- var nunjucksConfig = require(path.join(
+ const nunjucksConfig = require(path.join(
plPath,
'patternlab-nunjucks-config.js'
));
- if (typeof nunjucksConfig == 'function') {
- nunjucksConfig(nunjucks, env);
+ if (typeof nunjucksConfig === 'function') {
+ nunjucksConfig(env);
}
} catch (err) {}
-////////////////////////////
-// HELPER FUNCTIONS
-// https://stackoverflow.com/questions/2116558/fastest-method-to-replace-all-instances-of-a-character-in-a-string
-// Might do some research on the solution.
-////////////////////////////
-if (!String.prototype.replaceAll) {
- String.prototype.replaceAll = function(str1, str2, ignore) {
- return this.replace(
- new RegExp(
- str1.replace(/([\/\,\!\\\^\$\{\}\[\]\(\)\.\*\+\?\|\<\>\-\&])/g, '\\$&'),
- ignore ? 'gi' : 'g'
- ),
- typeof str2 == 'string' ? str2.replace(/\$/g, '$$$$') : str2
- );
- };
-}
-
-////////////////////////////
-// NUNJUCKS ENGINE
-////////////////////////////
-var engine_nunjucks = {
+// Nunjucks Engine
+const engine_nunjucks = {
engine: nunjucks,
engineName: 'nunjucks',
engineFileExtension: '.njk',
@@ -77,25 +72,24 @@ var engine_nunjucks = {
// render it
renderPattern: function renderPattern(pattern, data) {
try {
- // replace pattern names with their full path so Nunjucks can find them.
- pattern.extendedTemplate = this.replacePartials(pattern);
- var result = nunjucks.renderString(pattern.extendedTemplate, data);
+ const result = env.renderString(pattern.extendedTemplate, data);
return Promise.resolve(result);
} catch (err) {
console.error('Failed to render pattern: ' + pattern.name);
+ console.error(err);
}
},
// find and return any Nunjucks style includes/imports/extends within pattern
findPartials: function findPartials(pattern) {
- var matches = pattern.template.match(this.findPartialsRE);
+ const matches = pattern.template.match(this.findPartialsRE);
return matches;
},
// given a pattern, and a partial string, tease out the "pattern key" and return it.
findPartial: function(partialString) {
try {
- var partial = partialString.match(this.findPartialKeyRE)[1];
+ let partial = partialString.match(this.findPartialKeyRE)[1];
partial = partial.replace(/["']/g, '');
return partial;
} catch (err) {
@@ -116,38 +110,9 @@ var engine_nunjucks = {
}
},
- replacePartials: function(pattern) {
- try {
- var partials = this.findPartials(pattern);
- if (partials !== null) {
- for (var i = 0; i < partials.length; i++) {
- // e.g. {% include "atoms-parent" %}
- var partialName = this.findPartial(partials[i]); // e.g. atoms-parent
- var partialFullPath = partialRegistry[partialName]; // e.g. 00-atoms/01-parent.njk
- var newPartial = partials[i].replaceAll(
- partialName,
- partialFullPath,
- true
- ); // e.g. {% include "00-atoms/01-parent.njk" %}
- pattern.extendedTemplate = pattern.extendedTemplate.replaceAll(
- partials[i],
- newPartial,
- true
- );
- }
- }
- return pattern.extendedTemplate;
- } catch (err) {
- console.error(
- 'Error occurred in replacing partial names with paths for patern: ' +
- pattern.name
- );
- }
- },
-
// still requires the mustache syntax because of the way PL handles lists
findListItems: function(pattern) {
- var matches = pattern.template.match(this.findListItemsRE);
+ const matches = pattern.template.match(this.findListItemsRE);
return matches;
},
@@ -168,7 +133,6 @@ var engine_nunjucks = {
fs.statSync(metaFilePath);
} catch (err) {
//not a file, so spawn it from the included file
- const localMetaFilePath = path.resolve(__dirname, '_meta/', fileName);
const metaFileContent = fs.readFileSync(
path.resolve(__dirname, '..', '_meta/', fileName),
'utf8'
diff --git a/packages/engine-nunjucks/package.json b/packages/engine-nunjucks/package.json
index cca41a66b..98c8e34e5 100644
--- a/packages/engine-nunjucks/package.json
+++ b/packages/engine-nunjucks/package.json
@@ -7,8 +7,8 @@
"deprecated": false,
"description": "The nunjucks PatternEngine for Pattern Lab / Node",
"dependencies": {
- "fs-extra": "5.0.0",
- "nunjucks": "3.0.1"
+ "fs-extra": "7.0.0",
+ "nunjucks": "3.1.3"
},
"engines": {
"node": ">=4.0"
diff --git a/packages/engine-react/CHANGELOG.md b/packages/engine-react/CHANGELOG.md
index c1afffdb9..49e7cfcdc 100644
--- a/packages/engine-react/CHANGELOG.md
+++ b/packages/engine-react/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-## [0.2.1-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/compare/@pattern-lab/engine-react@0.2.1-alpha.4...@pattern-lab/engine-react@0.2.1-alpha.5) (2018-07-06)
+## [0.2.1-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/compare/@pattern-lab/engine-react@0.2.1-alpha.4...@pattern-lab/engine-react@0.2.1-alpha.5) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/commit/5ab3995))
-
-
-
-
-## [0.2.1-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/compare/@pattern-lab/engine-react@0.2.1-alpha.3...@pattern-lab/engine-react@0.2.1-alpha.4) (2018-07-05)
+## [0.2.1-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/compare/@pattern-lab/engine-react@0.2.1-alpha.3...@pattern-lab/engine-react@0.2.1-alpha.4) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/commit/38a01b1))
-
-
-
-## [0.2.1-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/compare/@pattern-lab/engine-react@0.2.1-alpha.2...@pattern-lab/engine-react@0.2.1-alpha.3) (2018-05-04)
-
-
+## [0.2.1-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-react/compare/@pattern-lab/engine-react@0.2.1-alpha.2...@pattern-lab/engine-react@0.2.1-alpha.3) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/engine-react
diff --git a/packages/engine-react/lib/engine_react.js b/packages/engine-react/lib/engine_react.js
index 70e821bc5..b0f01cdd2 100644
--- a/packages/engine-react/lib/engine_react.js
+++ b/packages/engine-react/lib/engine_react.js
@@ -215,9 +215,7 @@ var engine_react = {
* each with two properties: path, and content
*/
addOutputFiles(paths, patternlab) {
- return [
-
- ];
+ return [];
},
/**
diff --git a/packages/engine-twig/CHANGELOG.md b/packages/engine-twig/CHANGELOG.md
index cd0f9d89d..040dc4ac8 100644
--- a/packages/engine-twig/CHANGELOG.md
+++ b/packages/engine-twig/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-## [0.2.1-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/compare/@pattern-lab/engine-twig@0.2.1-alpha.4...@pattern-lab/engine-twig@0.2.1-alpha.5) (2018-07-06)
+## [0.2.1-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/compare/@pattern-lab/engine-twig@0.2.1-alpha.4...@pattern-lab/engine-twig@0.2.1-alpha.5) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/commit/5ab3995))
-
-
-
-
-## [0.2.1-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/compare/@pattern-lab/engine-twig@0.2.1-alpha.3...@pattern-lab/engine-twig@0.2.1-alpha.4) (2018-07-05)
+## [0.2.1-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/compare/@pattern-lab/engine-twig@0.2.1-alpha.3...@pattern-lab/engine-twig@0.2.1-alpha.4) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/commit/38a01b1))
-
-
-
-## [0.2.1-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/compare/@pattern-lab/engine-twig@0.2.1-alpha.2...@pattern-lab/engine-twig@0.2.1-alpha.3) (2018-05-04)
-
-
+## [0.2.1-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-twig/compare/@pattern-lab/engine-twig@0.2.1-alpha.2...@pattern-lab/engine-twig@0.2.1-alpha.3) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/engine-twig
diff --git a/packages/engine-underscore/CHANGELOG.md b/packages/engine-underscore/CHANGELOG.md
index 04dcadba5..533ecb7e8 100644
--- a/packages/engine-underscore/CHANGELOG.md
+++ b/packages/engine-underscore/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/compare/@pattern-lab/engine-underscore@2.0.0-alpha.6...@pattern-lab/engine-underscore@2.0.0-alpha.7) (2018-07-06)
+# [2.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/compare/@pattern-lab/engine-underscore@2.0.0-alpha.6...@pattern-lab/engine-underscore@2.0.0-alpha.7) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/commit/5ab3995))
-
-
-
-
-# [2.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/compare/@pattern-lab/engine-underscore@2.0.0-alpha.5...@pattern-lab/engine-underscore@2.0.0-alpha.6) (2018-07-05)
+# [2.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/compare/@pattern-lab/engine-underscore@2.0.0-alpha.5...@pattern-lab/engine-underscore@2.0.0-alpha.6) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/commit/38a01b1))
-
-
-
-# [2.0.0-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/compare/@pattern-lab/engine-underscore@2.0.0-alpha.4...@pattern-lab/engine-underscore@2.0.0-alpha.5) (2018-05-04)
-
-
+# [2.0.0-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/engine-underscore/compare/@pattern-lab/engine-underscore@2.0.0-alpha.4...@pattern-lab/engine-underscore@2.0.0-alpha.5) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/engine-underscore
diff --git a/packages/live-server/CHANGELOG.md b/packages/live-server/CHANGELOG.md
index 9396dc2a1..90c875efe 100644
--- a/packages/live-server/CHANGELOG.md
+++ b/packages/live-server/CHANGELOG.md
@@ -4,20 +4,16 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-## [1.3.3-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.5...@pattern-lab/live-server@1.3.3-alpha.6) (2018-07-06)
+## [1.3.3-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.5...@pattern-lab/live-server@1.3.3-alpha.6) (2018-07-06)
### Bug Fixes
* **dependencies:** pin all packages marked as latest ([87347d5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/commit/87347d5))
-
-
-
-
-## [1.3.3-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.4...@pattern-lab/live-server@1.3.3-alpha.5) (2018-07-06)
+## [1.3.3-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.4...@pattern-lab/live-server@1.3.3-alpha.5) (2018-07-06)
### Features
@@ -25,26 +21,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/commit/5ab3995))
-
-
-
-
-## [1.3.3-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.3...@pattern-lab/live-server@1.3.3-alpha.4) (2018-07-05)
+## [1.3.3-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.3...@pattern-lab/live-server@1.3.3-alpha.4) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/commit/38a01b1))
-
-
-
-## [1.3.3-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.2...@pattern-lab/live-server@1.3.3-alpha.3) (2018-05-04)
-
-
+## [1.3.3-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/live-server/compare/@pattern-lab/live-server@1.3.3-alpha.2...@pattern-lab/live-server@1.3.3-alpha.3) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/live-server
diff --git a/packages/plugin-tab/CHANGELOG.md b/packages/plugin-tab/CHANGELOG.md
index 5987384b9..db05da1ca 100644
--- a/packages/plugin-tab/CHANGELOG.md
+++ b/packages/plugin-tab/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-## [2.0.3-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/compare/@pattern-lab/plugin-tab@2.0.3-alpha.4...@pattern-lab/plugin-tab@2.0.3-alpha.5) (2018-07-06)
+## [2.0.3-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/compare/@pattern-lab/plugin-tab@2.0.3-alpha.4...@pattern-lab/plugin-tab@2.0.3-alpha.5) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/commit/5ab3995))
-
-
-
-
-## [2.0.3-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/compare/@pattern-lab/plugin-tab@2.0.3-alpha.3...@pattern-lab/plugin-tab@2.0.3-alpha.4) (2018-07-05)
+## [2.0.3-alpha.4](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/compare/@pattern-lab/plugin-tab@2.0.3-alpha.3...@pattern-lab/plugin-tab@2.0.3-alpha.4) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/commit/38a01b1))
-
-
-
-## [2.0.3-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/compare/@pattern-lab/plugin-tab@2.0.3-alpha.2...@pattern-lab/plugin-tab@2.0.3-alpha.3) (2018-05-04)
-
-
+## [2.0.3-alpha.3](https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab/compare/@pattern-lab/plugin-tab@2.0.3-alpha.2...@pattern-lab/plugin-tab@2.0.3-alpha.3) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/plugin-tab
diff --git a/packages/plugin-tab/README.md b/packages/plugin-tab/README.md
index 50e24a477..8bd03b862 100644
--- a/packages/plugin-tab/README.md
+++ b/packages/plugin-tab/README.md
@@ -1,4 +1,4 @@
-
+
[](https://www.npmjs.com/package/@pattern-lab/plugin-tab)
[](https://gitter.im/pattern-lab/node)
@@ -28,7 +28,7 @@ Example:
```
"plugins": {
- "plugin-node-tab": {
+ "pattern-lab-plugin-tab": {
"enabled": true,
"initialized": false,
"options": {
@@ -38,7 +38,7 @@ Example:
}
```
-Add file extensions to this array as strings. Example: `"tabsToAdd": ['scss', 'js']`. You are all set now.
+Add file extensions to this array as strings. Example: `"tabsToAdd": ["scss", "js"]`. You are all set now.
## Expected Structure
@@ -56,4 +56,4 @@ For example, if we added an `scss` tab:
## Enabling / Disabling the Plugin
-After install, you may manually enable or disable the plugin by finding the `plugin-node-tab` key within your main Pattern Lab project's `patternlab-config.json` file and setting the `enabled` flag. In the future this will be possible via CLI.
+After install, you may manually enable or disable the plugin by finding the `@pattern-lab/plugin-tab` key within your main Pattern Lab project's `patternlab-config.json` file and setting the `enabled` flag. In the future this will be possible via CLI.
diff --git a/packages/plugin-tab/dist/js/plugin-node-tab.js b/packages/plugin-tab/dist/js/pattern-lab-plugin-tab.js
similarity index 93%
rename from packages/plugin-tab/dist/js/plugin-node-tab.js
rename to packages/plugin-tab/dist/js/pattern-lab-plugin-tab.js
index d0e999422..9573b9bed 100644
--- a/packages/plugin-tab/dist/js/plugin-node-tab.js
+++ b/packages/plugin-tab/dist/js/pattern-lab-plugin-tab.js
@@ -1,4 +1,4 @@
-var PluginTab = {
+const PluginTab = {
/**
* The function defined as the onready callback within the plugin configuration.
*/
diff --git a/packages/plugin-tab/index.js b/packages/plugin-tab/index.js
index 3790ea383..b5cea6072 100644
--- a/packages/plugin-tab/index.js
+++ b/packages/plugin-tab/index.js
@@ -1,24 +1,31 @@
'use strict';
-const pluginName = 'plugin-node-tab';
+const path = require('path');
+const EOL = require('os').EOL;
+const _ = require('lodash');
const fs = require('fs-extra');
const glob = require('glob');
-const path = require('path');
-const EOL = require('os').EOL;
+
const tab_loader = require('./src/tab-loader');
+const pluginName = 'pattern-lab-plugin-tab';
+
function writeConfigToOutput(patternlab, pluginConfig) {
- var pluginConfigPathName = path.resolve(
- patternlab.config.paths.public.root,
- 'patternlab-components',
- 'packages'
- );
try {
- fs.outputFileSync(
- pluginConfigPathName + '/' + pluginName + '.json',
- JSON.stringify(pluginConfig, null, 2)
- );
+ _.each(patternlab.uikits, uikit => {
+ fs.outputFileSync(
+ path.join(
+ process.cwd(),
+ uikit.outputDir,
+ patternlab.config.paths.public.root,
+ 'patternlab-components',
+ 'packages',
+ `/${pluginName}.json`
+ ),
+ JSON.stringify(pluginConfig, null, 2)
+ );
+ });
} catch (ex) {
console.trace(
pluginName + ': Error occurred while writing pluginFile configuration'
@@ -48,7 +55,7 @@ function registerEvents(patternlab) {
*/
function getPluginFrontendConfig() {
return {
- name: 'pattern-lab/' + pluginName,
+ name: pluginName,
templates: [],
stylesheets: [],
javascripts: [
@@ -69,33 +76,16 @@ function getPluginFrontendConfig() {
*/
function pluginInit(patternlab) {
if (!patternlab) {
- console.error('patternlab object not provided to plugin-init');
+ console.error('patternlab object not provided to pluginInit');
process.exit(1);
}
//write the plugin json to public/patternlab-components
- var pluginConfig = getPluginFrontendConfig();
+ const pluginConfig = getPluginFrontendConfig();
pluginConfig.tabsToAdd =
patternlab.config.plugins[pluginName].options.tabsToAdd;
writeConfigToOutput(patternlab, pluginConfig);
- var pluginConfigPathName = path.resolve(
- patternlab.config.paths.public.root,
- 'patternlab-components',
- 'packages'
- );
- try {
- fs.outputFileSync(
- pluginConfigPathName + '/' + pluginName + '.json',
- JSON.stringify(pluginConfig, null, 2)
- );
- } catch (ex) {
- console.trace(
- 'plugin-node-tab: Error occurred while writing pluginFile configuration'
- );
- console.log(ex);
- }
-
//add the plugin config to the patternlab-object
if (!patternlab.plugins) {
patternlab.plugins = [];
@@ -103,22 +93,22 @@ function pluginInit(patternlab) {
patternlab.plugins.push(pluginConfig);
//write the plugin dist folder to public/pattern-lab
- var pluginFiles = glob.sync(__dirname + '/dist/**/*');
+ const pluginFiles = glob.sync(__dirname + '/dist/**/*');
if (pluginFiles && pluginFiles.length > 0) {
- let tab_frontend_snippet = fs.readFileSync(
+ const tab_frontend_snippet = fs.readFileSync(
path.resolve(__dirname + '/src/snippet.js'),
'utf8'
);
for (let i = 0; i < pluginFiles.length; i++) {
try {
- var fileStat = fs.statSync(pluginFiles[i]);
+ const fileStat = fs.statSync(pluginFiles[i]);
if (fileStat.isFile()) {
- var relativePath = path
+ const relativePath = path
.relative(__dirname, pluginFiles[i])
.replace('dist', ''); //dist is dropped
- var writePath = path.join(
+ const writePath = path.join(
patternlab.config.paths.public.root,
'patternlab-components',
'pattern-lab',
@@ -134,10 +124,10 @@ function pluginInit(patternlab) {
//in this case, we need to alter the dist file to loop through our tabs to load as defined in the package.json
//we are also being a bit lazy here, since we only expect one file
let tabJSFileContents = fs.readFileSync(pluginFiles[i], 'utf8');
- var snippetString = '';
+ let snippetString = '';
if (pluginConfig.tabsToAdd && pluginConfig.tabsToAdd.length > 0) {
for (let j = 0; j < pluginConfig.tabsToAdd.length; j++) {
- let tabSnippetLocal = tab_frontend_snippet
+ const tabSnippetLocal = tab_frontend_snippet
.replace(/<
>/g, pluginConfig.tabsToAdd[j])
.replace(
/<>/g,
@@ -149,12 +139,17 @@ function pluginInit(patternlab) {
'/*SNIPPETS*/',
snippetString
);
- fs.outputFileSync(writePath, tabJSFileContents);
+ _.each(patternlab.uikits, uikit => {
+ fs.outputFileSync(
+ path.join(process.cwd(), uikit.outputDir, writePath),
+ tabJSFileContents
+ );
+ });
}
}
} catch (ex) {
console.trace(
- 'plugin-node-tab: Error occurred while copying pluginFile',
+ 'plugin-tab: Error occurred while copying pluginFile',
pluginFiles[i]
);
console.log(ex);
diff --git a/packages/plugin-tab/package.json b/packages/plugin-tab/package.json
index 744175bda..cc26ea744 100644
--- a/packages/plugin-tab/package.json
+++ b/packages/plugin-tab/package.json
@@ -5,7 +5,8 @@
"main": "index.js",
"dependencies": {
"fs-extra": "0.30.0",
- "glob": "7.0.0"
+ "glob": "7.0.0",
+ "lodash": "4.17.5"
},
"repository": "https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab",
"bugs": "https://github.com/pattern-lab/patternlab-node/issues",
@@ -15,7 +16,7 @@
},
"author": "Brian Muenzenmeyer",
"license": "MIT",
- "homepage": "https://github.com/pattern-lab/plugin-node-tab#readme",
+ "homepage": "https://github.com/pattern-lab/patternlab-node/tree/master/packages/plugin-tab",
"devDependencies": {
"eslint": "4.18.2"
},
diff --git a/packages/plugin-tab/postinstall.js b/packages/plugin-tab/postinstall.js
index 56620abe5..25c8c2039 100644
--- a/packages/plugin-tab/postinstall.js
+++ b/packages/plugin-tab/postinstall.js
@@ -1,10 +1,5 @@
-console.log('Pattern Lab Node Plugin - "plugin-node-tab" installed. ');
-console.log(
- 'You may have to run `npm run postinstall` from your console as well.'
-);
-console.log(
- 'Configure or disable this plugin inside your patternlab-config.json file.'
-);
-console.log(
- 'Add tabs to the Pattern Lab UI by adding file extensions to the "tabsToAdd" array on the plugins.plugin-node-tab.options object.'
-);
+console.log(`Pattern Lab Node Plugin - "plugin-tab" installed.
+Use the CLI to install this: patternlab install --plugins @pattern-lab/plugin-tab
+Configure or disable this plugin inside your patternlab-config.json file.
+Add tabs to the Pattern Lab UI by adding file extensions to the "tabsToAdd" array on the plugins['@pattern-lab/plugin-tab'].options object.
+`);
diff --git a/packages/plugin-tab/src/snippet.js b/packages/plugin-tab/src/snippet.js
index b7e08bb36..499fc65f5 100644
--- a/packages/plugin-tab/src/snippet.js
+++ b/packages/plugin-tab/src/snippet.js
@@ -9,6 +9,6 @@ Panels.add({
httpRequestReplace: '.<>',
httpRequestCompleted: false,
prismHighlight: true,
- language: 'markup',
+ language: '<>',
keyCombo: 'ctrl+shift+z',
});
diff --git a/packages/plugin-tab/src/tab-loader.js b/packages/plugin-tab/src/tab-loader.js
index 4793128a9..7ae297500 100644
--- a/packages/plugin-tab/src/tab-loader.js
+++ b/packages/plugin-tab/src/tab-loader.js
@@ -1,8 +1,10 @@
'use strict';
-const fs = require('fs-extra');
const path = require('path');
+const _ = require('lodash');
+const fs = require('fs-extra');
+
/**
* The backend method that is called during the patternlab-pattern-write-end event.
* Responsible for looking for a companion filetype file alongside a pattern file and outputting it if found.
@@ -12,21 +14,21 @@ const path = require('path');
function findTab(patternlab, pattern) {
//read the filetypes from the configuration
const fileTypes =
- patternlab.config.plugins['plugin-node-tab'].options.tabsToAdd;
+ patternlab.config.plugins['pattern-lab-plugin-tab'].options.tabsToAdd;
//exit if either of these two parameters are missing
if (!patternlab) {
- console.error('plugin-node-tab: patternlab object not provided to findTab');
+ console.error('plugin-tab: patternlab object not provided to findTab');
process.exit(1);
}
if (!pattern) {
- console.error('plugin-node-tab: pattern object not provided to findTab');
+ console.error('plugin-tab: pattern object not provided to findTab');
process.exit(1);
}
//derive the custom filetype paths from the pattern relPath
- var customFileTypePath = path.join(
+ let customFileTypePath = path.join(
patternlab.config.paths.source.patterns,
pattern.relPath
);
@@ -39,35 +41,47 @@ function findTab(patternlab, pattern) {
customFileTypePath.substr(0, customFileTypePath.lastIndexOf('.')) +
'.' +
fileType;
- var customFileTypeOutputPath =
+ const customFileTypeOutputPath =
patternlab.config.paths.public.patterns +
pattern.getPatternLink(patternlab, 'custom', '.' + fileType);
//look for a custom filetype for this template
+ let tabFileName;
+ let tabFileNameStats;
try {
- var tabFileName = path.resolve(customFileTypePath);
+ tabFileName = path.resolve(customFileTypePath);
try {
- var tabFileNameStats = fs.statSync(tabFileName);
+ tabFileNameStats = fs.statSync(tabFileName);
} catch (err) {
//not a file - move on quietly
}
if (tabFileNameStats && tabFileNameStats.isFile()) {
if (patternlab.config.debug) {
console.log(
- 'plugin-node-tab: copied pattern-specific custom file for ' +
+ 'plugin-tab: copied pattern-specific custom file for ' +
pattern.patternPartial
);
}
//copy the file to our output target if found
- fs.copySync(tabFileName, customFileTypeOutputPath);
+ _.each(patternlab.uikits, uikit => {
+ fs.copySync(
+ tabFileName,
+ path.join(process.cwd(), uikit.outputDir, customFileTypeOutputPath)
+ );
+ });
} else {
//otherwise write nothing to the same location - this prevents GET errors on the tab.
- fs.outputFileSync(customFileTypeOutputPath, '');
+ _.each(patternlab.uikits, uikit => {
+ fs.outputFileSync(
+ path.join(process.cwd(), uikit.outputDir, customFileTypeOutputPath),
+ ''
+ );
+ });
}
} catch (err) {
console.log(
- 'plugin-node-tab:There was an error parsing sibling JSON for ' +
+ 'plugin-tab: There was an error parsing sibling JSON for ' +
pattern.relPath
);
console.log(err);
diff --git a/packages/uikit-workshop/.bowerrc b/packages/uikit-workshop/.bowerrc
deleted file mode 100644
index ba7d4d8df..000000000
--- a/packages/uikit-workshop/.bowerrc
+++ /dev/null
@@ -1,3 +0,0 @@
-{
- "directory": "src/bower_components"
-}
\ No newline at end of file
diff --git a/packages/uikit-workshop/.github/CONTRIBUTING.md b/packages/uikit-workshop/.github/CONTRIBUTING.md
index d6ab592b8..8cb32513f 100644
--- a/packages/uikit-workshop/.github/CONTRIBUTING.md
+++ b/packages/uikit-workshop/.github/CONTRIBUTING.md
@@ -19,11 +19,11 @@ The best way to make changes to this repo and test them is through your existing
To make changes **always edit files in `src/`**. To make sure that these changes are reflected in the front-end and `dist/` folder run the following:
- gulp --copy-dist=../../../public
+ npm run build
To watch for changes you can use:
- gulp --watch --copy-dist=../../../public
+ npm run watch
At this point changes to the static assets should compile to the correct locations in the project as well as `dist/`.
diff --git a/packages/uikit-workshop/CHANGELOG.md b/packages/uikit-workshop/CHANGELOG.md
index 995e767c6..cc83a4d59 100644
--- a/packages/uikit-workshop/CHANGELOG.md
+++ b/packages/uikit-workshop/CHANGELOG.md
@@ -4,8 +4,8 @@ All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
-# [1.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/compare/@pattern-lab/uikit-workshop@1.0.0-alpha.6...@pattern-lab/uikit-workshop@1.0.0-alpha.7) (2018-07-06)
+# [1.0.0-alpha.7](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/compare/@pattern-lab/uikit-workshop@1.0.0-alpha.6...@pattern-lab/uikit-workshop@1.0.0-alpha.7) (2018-07-06)
### Features
@@ -13,26 +13,17 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
* **package:** pin all dependencies ([415698e](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/commit/415698e))
* **package:** remove package-lock.json files ([5ab3995](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/commit/5ab3995))
-
-
-
-
-# [1.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/compare/@pattern-lab/uikit-workshop@1.0.0-alpha.5...@pattern-lab/uikit-workshop@1.0.0-alpha.6) (2018-07-05)
+# [1.0.0-alpha.6](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/compare/@pattern-lab/uikit-workshop@1.0.0-alpha.5...@pattern-lab/uikit-workshop@1.0.0-alpha.6) (2018-07-05)
### Features
* **tests:** use lerna run test at the monorepo level ([38a01b1](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/commit/38a01b1))
-
-
-
-# [1.0.0-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/compare/@pattern-lab/uikit-workshop@1.0.0-alpha.4...@pattern-lab/uikit-workshop@1.0.0-alpha.5) (2018-05-04)
-
-
+# [1.0.0-alpha.5](https://github.com/pattern-lab/patternlab-node/tree/master/packages/uikit-workshop/compare/@pattern-lab/uikit-workshop@1.0.0-alpha.4...@pattern-lab/uikit-workshop@1.0.0-alpha.5) (2018-05-04)
**Note:** Version bump only for package @pattern-lab/uikit-workshop
diff --git a/packages/uikit-workshop/bower.json b/packages/uikit-workshop/bower.json
deleted file mode 100644
index 86102afa8..000000000
--- a/packages/uikit-workshop/bower.json
+++ /dev/null
@@ -1,34 +0,0 @@
-{
- "name": "styleguidekit-assets-default",
- "version": "0.1.0",
- "homepage": "https://github.com/pattern-lab/styleguidekit-assets-default",
- "authors": [
- "Dave Olsen "
- ],
- "license": "MIT",
- "private": true,
- "dependencies": {
- "jquery": "~2.1.1",
- "jwerty": "~0.3.2",
- "prism": "gh-pages",
- "typeahead.js": "~0.10.4",
- "hogan": "~3.0.2",
- "script.js": "~2.5.7",
- "eventEmitter": "~4.2.7"
- },
- "overrides": {
- "hogan": {
- "main": "web/builds/3.0.2/hogan-3.0.2.js"
- },
- "script.js": {
- "main": "dist/script.js"
- },
- "jwerty": {
- "main": "jwerty.js"
- },
- "prism": {
- "main": "prism.js"
- }
- },
- "devDependencies": {}
-}
diff --git a/packages/uikit-workshop/dist/index.html b/packages/uikit-workshop/dist/index.html
index 5022d8f9b..c63d63f16 100644
--- a/packages/uikit-workshop/dist/index.html
+++ b/packages/uikit-workshop/dist/index.html
@@ -1,399 +1,8 @@
-
-
-
-
- Pattern Lab
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ Pattern Lab
+
+
+
\ No newline at end of file
diff --git a/packages/uikit-workshop/dist/styleguide/bower_components/EventEmitter.min.js b/packages/uikit-workshop/dist/styleguide/bower_components/EventEmitter.min.js
deleted file mode 100644
index 04dabbb66..000000000
--- a/packages/uikit-workshop/dist/styleguide/bower_components/EventEmitter.min.js
+++ /dev/null
@@ -1 +0,0 @@
-(function(){"use strict";function e(){}function t(e,t){for(var n=e.length;n--;)if(e[n].listener===t)return n;return-1}function n(e){return function(){return this[e].apply(this,arguments)}}var r=e.prototype,i=this,s=i.EventEmitter;r.getListeners=function(e){var t,n,r=this._getEvents();if(e instanceof RegExp){t={};for(n in r)r.hasOwnProperty(n)&&e.test(n)&&(t[n]=r[n])}else t=r[e]||(r[e]=[]);return t},r.flattenListeners=function(e){var t,n=[];for(t=0;t=0;c--)if(a=e[c],s=n(t,a,u),void 0!==s){o=!0;break}return o?(r||"function"!=typeof s||(s=this.mv(s,e,i)),s):!r&&""},ls:function(t,n,e,r,s){var a=this.options.delimiters;return this.options.delimiters=s,this.b(this.ct(i(t.call(n,r)),n,e)),this.options.delimiters=a,!1},ct:function(t,n,e){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(t,this.options).render(n,e)},b:function(t){this.buf+=t},fl:function(){var t=this.buf;return this.buf="",t},ms:function(t,n,e,i,r,s,a){var o,u=n[n.length-1],c=t.call(u);return"function"==typeof c?!!i||(o=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(c,u,e,o.substring(r,s),a)):c},mv:function(t,n,e){var r=n[n.length-1],s=t.call(r);return"function"==typeof s?this.ct(i(s.call(r)),r,e):s},sub:function(t,n,e,i){var r=this.subs[t];r&&(this.activeSub=t,r(n,e,this,i),this.activeSub=!1)}};var s=/&/g,a=//g,u=/\'/g,c=/\"/g,l=/[&<>\"\']/,f=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)}}("undefined"!=typeof exports?exports:Hogan),function(t){function n(t){"}"===t.n.substr(t.n.length-1)&&(t.n=t.n.substring(0,t.n.length-1))}function e(t){return t.trim?t.trim():t.replace(/^\s*|\s*$/g,"")}function i(t,n,e){if(n.charAt(e)!=t.charAt(0))return!1;for(var i=1,r=t.length;i0;){if(f=n.shift(),l&&"<"==l.tag&&!(f.tag in k))throw new Error("Illegal content in < super tag.");if(t.tags[f.tag]<=t.tags.$||s(f,o))i.push(f),f.nodes=r(n,f.tag,i,o);else{if("/"==f.tag){if(0===i.length)throw new Error("Closing tag without opener: /"+f.n);if(c=i.pop(),f.n!=c.n&&!a(f.n,c.n,o))throw new Error("Nesting error: "+c.n+" vs. "+f.n);return c.end=f.i,u}"\n"==f.tag&&(f.last=0==n.length||"\n"==n[0].tag)}u.push(f)}if(i.length>0)throw new Error("missing closing tag: "+i.pop().n);return u}function s(t,n){for(var e=0,i=n.length;e":7,"=":8,_v:9,"{":10,"&":11,_t:12},t.scan=function(r,s){function a(){m.length>0&&(x.push({tag:"_t",text:new String(m)}),m="")}function o(){for(var n=!0,e=y;e"==e.tag&&(e.indent=x[i].text.toString()),x.splice(i,1));else n||x.push({tag:"\n"});w=!1,y=x.length}function c(t,n){var i="="+S,r=t.indexOf(i,n),s=e(t.substring(t.indexOf("=",n)+1,r)).split(" ");return T=s[0],S=s[s.length-1],r+i.length-1}var l=r.length,f=0,h=1,p=2,v=f,b=null,d=null,m="",x=[],w=!1,k=0,y=0,T="{{",S="}}";for(s&&(s=s.split(" "),T=s[0],S=s[1]),k=0;k":f,"<":function(n,e){var i={partials:{},code:"",subs:{},inPartial:!0};t.walk(n.nodes,i);var r=e.partials[f(n,e)];r.subs=i.subs,r.partials=i.partials},$:function(n,e){var i={subs:{},code:"",partials:e.partials,prefix:n.n};t.walk(n.nodes,i),e.subs[n.n]=i.code,e.inPartial||(e.code+='t.sub("'+c(n.n)+'",c,p,i);')},"\n":function(t,n){n.code+=p('"\\n"'+(t.last?"":" + i"))},_v:function(t,n){n.code+="t.b(t.v(t."+l(t.n)+'("'+c(t.n)+'",c,p,0)));'},_t:function(t,n){n.code+=p('"'+c(t.text)+'"')},"{":h,"&":h},t.walk=function(n,e){for(var i,r=0,s=n.length;r0&&t-1 in e))}function r(e,t,n){if(Z.isFunction(t))return Z.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return Z.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(ae.test(t))return Z.filter(t,e,n);t=Z.filter(t,e)}return Z.grep(e,function(e){return U.call(t,e)>=0!==n})}function i(e,t){for(;(e=e[t])&&1!==e.nodeType;);return e}function o(e){var t=he[e]={};return Z.each(e.match(de)||[],function(e,n){t[n]=!0}),t}function s(){J.removeEventListener("DOMContentLoaded",s,!1),e.removeEventListener("load",s,!1),Z.ready()}function a(){Object.defineProperty(this.cache={},0,{get:function(){return{}}}),this.expando=Z.expando+a.uid++}function u(e,t,n){var r;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(be,"-$1").toLowerCase(),n=e.getAttribute(r),"string"==typeof n){try{n="true"===n||"false"!==n&&("null"===n?null:+n+""===n?+n:xe.test(n)?Z.parseJSON(n):n)}catch(i){}ye.set(e,t,n)}else n=void 0;return n}function l(){return!0}function c(){return!1}function f(){try{return J.activeElement}catch(e){}}function p(e,t){return Z.nodeName(e,"table")&&Z.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function d(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function h(e){var t=Pe.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function g(e,t){for(var n=0,r=e.length;n")).appendTo(t.documentElement),t=We[0].contentDocument,t.write(),t.close(),n=x(e,t),We.detach()),$e[e]=n),n}function w(e,t,n){var r,i,o,s,a=e.style;return n=n||_e(e),n&&(s=n.getPropertyValue(t)||n[t]),n&&(""!==s||Z.contains(e.ownerDocument,e)||(s=Z.style(e,t)),Be.test(s)&&Ie.test(t)&&(r=a.width,i=a.minWidth,o=a.maxWidth,a.minWidth=a.maxWidth=a.width=s,s=n.width,a.width=r,a.minWidth=i,a.maxWidth=o)),void 0!==s?s+"":s}function T(e,t){return{get:function(){return e()?void delete this.get:(this.get=t).apply(this,arguments)}}}function C(e,t){if(t in e)return t;for(var n=t[0].toUpperCase()+t.slice(1),r=t,i=Ge.length;i--;)if(t=Ge[i]+n,t in e)return t;return r}function N(e,t,n){var r=Xe.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function k(e,t,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===t?1:0,s=0;o<4;o+=2)"margin"===n&&(s+=Z.css(e,n+Te[o],!0,i)),r?("content"===n&&(s-=Z.css(e,"padding"+Te[o],!0,i)),"margin"!==n&&(s-=Z.css(e,"border"+Te[o]+"Width",!0,i))):(s+=Z.css(e,"padding"+Te[o],!0,i),"padding"!==n&&(s+=Z.css(e,"border"+Te[o]+"Width",!0,i)));return s}function E(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=_e(e),s="border-box"===Z.css(e,"boxSizing",!1,o);if(i<=0||null==i){if(i=w(e,t,o),(i<0||null==i)&&(i=e.style[t]),Be.test(i))return i;r=s&&(Q.boxSizingReliable()||i===e.style[t]),i=parseFloat(i)||0}return i+k(e,t,n||(s?"border":"content"),r,o)+"px"}function S(e,t){for(var n,r,i,o=[],s=0,a=e.length;s=0&&n=0},isPlainObject:function(e){return"object"===Z.type(e)&&!e.nodeType&&!Z.isWindow(e)&&!(e.constructor&&!G.call(e.constructor.prototype,"isPrototypeOf"))},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?V[Y.call(e)]||"object":typeof e},globalEval:function(e){var t,n=eval;e=Z.trim(e),e&&(1===e.indexOf("use strict")?(t=J.createElement("script"),t.text=e,J.head.appendChild(t).parentNode.removeChild(t)):n(e))},camelCase:function(e){return e.replace(te,"ms-").replace(ne,re)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,r){var i,o=0,s=e.length,a=n(e);if(r){if(a)for(;oT.cacheLength&&delete e[t.shift()],e[n+" "]=r}var t=[];return e}function r(e){return e[W]=!0,e}function i(e){var t=q.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function o(e,t){for(var n=e.split("|"),r=e.length;r--;)T.attrHandle[n[r]]=t}function s(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||V)-(~e.sourceIndex||V);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function a(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function u(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function l(e){return r(function(t){return t=+t,r(function(n,r){for(var i,o=e([],n.length,t),s=o.length;s--;)n[i=o[s]]&&(n[i]=!(r[i]=n[i]))})})}function c(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}function f(){}function p(e){for(var t=0,n=e.length,r="";t1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function g(e,n,r){for(var i=0,o=n.length;i-1&&(r[l]=!(s[l]=f))}}else x=m(x===s?x.splice(h,x.length):x),o?o(null,s,x,u):K.apply(s,x)})}function y(e){for(var t,n,r,i=e.length,o=T.relative[e[0].type],s=o||T.relative[" "],a=o?1:0,u=d(function(e){return e===t},s,!0),l=d(function(e){return ee(t,e)>-1},s,!0),c=[function(e,n,r){var i=!o&&(r||n!==D)||((t=n).nodeType?u(e,n,r):l(e,n,r));return t=null,i}];a1&&h(c),a>1&&p(e.slice(0,a-1).concat({value:" "===e[a-2].type?"*":""})).replace(ue,"$1"),n,a0,o=e.length>0,s=function(r,s,a,u,l){var c,f,p,d=0,h="0",g=r&&[],v=[],y=D,x=r||o&&T.find.TAG("*",l),b=I+=null==y?1:Math.random()||.1,w=x.length;for(l&&(D=s!==q&&s);h!==w&&null!=(c=x[h]);h++){if(o&&c){for(f=0;p=e[f++];)if(p(c,s,a)){u.push(c);break}l&&(I=b)}i&&((c=!p&&c)&&d--,r&&g.push(c))}if(d+=h,i&&h!==d){for(f=0;p=n[f++];)p(g,v,s,a);if(r){if(d>0)for(;h--;)g[h]||v[h]||(v[h]=Q.call(u));v=m(v)}K.apply(u,v),l&&!r&&v.length>0&&d+n.length>1&&t.uniqueSort(u)}return l&&(I=b,D=y),g};return i?r(s):s}var b,w,T,C,N,k,E,S,D,j,A,L,q,H,O,F,P,R,M,W="sizzle"+1*new Date,$=e.document,I=0,B=0,_=n(),z=n(),X=n(),U=function(e,t){return e===t&&(A=!0),0},V=1<<31,Y={}.hasOwnProperty,G=[],Q=G.pop,J=G.push,K=G.push,Z=G.slice,ee=function(e,t){for(var n=0,r=e.length;n+~]|"+ne+")"+ne+"*"),fe=new RegExp("="+ne+"*([^\\]'\"]*?)"+ne+"*\\]","g"),pe=new RegExp(se),de=new RegExp("^"+ie+"$"),he={ID:new RegExp("^#("+re+")"),CLASS:new RegExp("^\\.("+re+")"),TAG:new RegExp("^("+re.replace("w","w*")+")"),ATTR:new RegExp("^"+oe),PSEUDO:new RegExp("^"+se),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+ne+"*(even|odd|(([+-]|)(\\d*)n|)"+ne+"*(?:([+-]|)"+ne+"*(\\d+)|))"+ne+"*\\)|)","i"),bool:new RegExp("^(?:"+te+")$","i"),needsContext:new RegExp("^"+ne+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+ne+"*((?:-\\d)?\\d*)"+ne+"*\\)|)(?=[^-]|$)","i")},ge=/^(?:input|select|textarea|button)$/i,me=/^h\d$/i,ve=/^[^{]+\{\s*\[native \w/,ye=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,xe=/[+~]/,be=/'|\\/g,we=new RegExp("\\\\([\\da-f]{1,6}"+ne+"?|("+ne+")|.)","ig"),Te=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},Ce=function(){L()};try{K.apply(G=Z.call($.childNodes),$.childNodes),G[$.childNodes.length].nodeType}catch(Ne){K={apply:G.length?function(e,t){J.apply(e,Z.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}w=t.support={},N=t.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},L=t.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:$;return r!==q&&9===r.nodeType&&r.documentElement?(q=r,H=r.documentElement,n=r.defaultView,n&&n!==n.top&&(n.addEventListener?n.addEventListener("unload",Ce,!1):n.attachEvent&&n.attachEvent("onunload",Ce)),O=!N(r),w.attributes=i(function(e){return e.className="i",!e.getAttribute("className")}),w.getElementsByTagName=i(function(e){return e.appendChild(r.createComment("")),!e.getElementsByTagName("*").length}),w.getElementsByClassName=ve.test(r.getElementsByClassName),w.getById=i(function(e){return H.appendChild(e).id=W,!r.getElementsByName||!r.getElementsByName(W).length}),w.getById?(T.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&O){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},T.filter.ID=function(e){var t=e.replace(we,Te);return function(e){return e.getAttribute("id")===t}}):(delete T.find.ID,T.filter.ID=function(e){var t=e.replace(we,Te);return function(e){var n="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}}),T.find.TAG=w.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):w.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},T.find.CLASS=w.getElementsByClassName&&function(e,t){if(O)return t.getElementsByClassName(e)},P=[],F=[],(w.qsa=ve.test(r.querySelectorAll))&&(i(function(e){H.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&F.push("[*^$]="+ne+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||F.push("\\["+ne+"*(?:value|"+te+")"),e.querySelectorAll("[id~="+W+"-]").length||F.push("~="),e.querySelectorAll(":checked").length||F.push(":checked"),e.querySelectorAll("a#"+W+"+*").length||F.push(".#.+[+~]")}),i(function(e){var t=r.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&F.push("name"+ne+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||F.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),F.push(",.*:")})),(w.matchesSelector=ve.test(R=H.matches||H.webkitMatchesSelector||H.mozMatchesSelector||H.oMatchesSelector||H.msMatchesSelector))&&i(function(e){w.disconnectedMatch=R.call(e,"div"),R.call(e,"[s!='']:x"),P.push("!=",se)}),F=F.length&&new RegExp(F.join("|")),P=P.length&&new RegExp(P.join("|")),t=ve.test(H.compareDocumentPosition),M=t||ve.test(H.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},U=t?function(e,t){if(e===t)return A=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n?n:(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&n||!w.sortDetached&&t.compareDocumentPosition(e)===n?e===r||e.ownerDocument===$&&M($,e)?-1:t===r||t.ownerDocument===$&&M($,t)?1:j?ee(j,e)-ee(j,t):0:4&n?-1:1)}:function(e,t){if(e===t)return A=!0,0;var n,i=0,o=e.parentNode,a=t.parentNode,u=[e],l=[t];if(!o||!a)return e===r?-1:t===r?1:o?-1:a?1:j?ee(j,e)-ee(j,t):0;if(o===a)return s(e,t);for(n=e;n=n.parentNode;)u.unshift(n);for(n=t;n=n.parentNode;)l.unshift(n);for(;u[i]===l[i];)i++;return i?s(u[i],l[i]):u[i]===$?-1:l[i]===$?1:0},r):q},t.matches=function(e,n){return t(e,null,null,n)},t.matchesSelector=function(e,n){if((e.ownerDocument||e)!==q&&L(e),n=n.replace(fe,"='$1']"),w.matchesSelector&&O&&(!P||!P.test(n))&&(!F||!F.test(n)))try{var r=R.call(e,n);if(r||w.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(i){}return t(n,q,null,[e]).length>0},t.contains=function(e,t){return(e.ownerDocument||e)!==q&&L(e),M(e,t)},t.attr=function(e,t){(e.ownerDocument||e)!==q&&L(e);var n=T.attrHandle[t.toLowerCase()],r=n&&Y.call(T.attrHandle,t.toLowerCase())?n(e,t,!O):void 0;return void 0!==r?r:w.attributes||!O?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},t.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},t.uniqueSort=function(e){var t,n=[],r=0,i=0;if(A=!w.detectDuplicates,j=!w.sortStable&&e.slice(0),e.sort(U),A){for(;t=e[i++];)t===e[i]&&(r=n.push(i));for(;r--;)e.splice(n[r],1)}return j=null,e},C=t.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=C(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r++];)n+=C(t);return n},T=t.selectors={cacheLength:50,createPseudo:r,match:he,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(we,Te),e[3]=(e[3]||e[4]||e[5]||"").replace(we,Te),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||t.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&t.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return he.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&pe.test(n)&&(t=k(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(we,Te).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=_[e+" "];return t||(t=new RegExp("(^|"+ne+")"+e+"("+ne+"|$)"))&&_(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,n,r){return function(i){var o=t.attr(i,e);return null==o?"!="===n:!n||(o+="","="===n?o===r:"!="===n?o!==r:"^="===n?r&&0===o.indexOf(r):"*="===n?r&&o.indexOf(r)>-1:"$="===n?r&&o.slice(-r.length)===r:"~="===n?(" "+o.replace(ae," ")+" ").indexOf(r)>-1:"|="===n&&(o===r||o.slice(0,r.length+1)===r+"-"))}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),s="last"!==e.slice(-4),a="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var l,c,f,p,d,h,g=o!==s?"nextSibling":"previousSibling",m=t.parentNode,v=a&&t.nodeName.toLowerCase(),y=!u&&!a;if(m){if(o){for(;g;){for(f=t;f=f[g];)if(a?f.nodeName.toLowerCase()===v:1===f.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[s?m.firstChild:m.lastChild],s&&y){for(c=m[W]||(m[W]={}),l=c[e]||[],d=l[0]===I&&l[1],p=l[0]===I&&l[2],f=d&&m.childNodes[d];f=++d&&f&&f[g]||(p=d=0)||h.pop();)if(1===f.nodeType&&++p&&f===t){c[e]=[I,d,p];break}}else if(y&&(l=(t[W]||(t[W]={}))[e])&&l[0]===I)p=l[1];else for(;(f=++d&&f&&f[g]||(p=d=0)||h.pop())&&((a?f.nodeName.toLowerCase()!==v:1!==f.nodeType)||!++p||(y&&((f[W]||(f[W]={}))[e]=[I,p]),f!==t)););return p-=i,p===r||p%r===0&&p/r>=0}}},PSEUDO:function(e,n){var i,o=T.pseudos[e]||T.setFilters[e.toLowerCase()]||t.error("unsupported pseudo: "+e);return o[W]?o(n):o.length>1?(i=[e,e,"",n],T.setFilters.hasOwnProperty(e.toLowerCase())?r(function(e,t){for(var r,i=o(e,n),s=i.length;s--;)r=ee(e,i[s]),e[r]=!(t[r]=i[s])}):function(e){return o(e,0,i)}):o}},pseudos:{not:r(function(e){var t=[],n=[],i=E(e.replace(ue,"$1"));return i[W]?r(function(e,t,n,r){for(var o,s=i(e,null,r,[]),a=e.length;a--;)(o=s[a])&&(e[a]=!(t[a]=o))}):function(e,r,o){return t[0]=e,i(t,null,o,n),t[0]=null,!n.pop()}}),has:r(function(e){return function(n){return t(e,n).length>0}}),contains:r(function(e){return e=e.replace(we,Te),function(t){return(t.textContent||t.innerText||C(t)).indexOf(e)>-1}}),lang:r(function(e){return de.test(e||"")||t.error("unsupported lang: "+e),e=e.replace(we,Te).toLowerCase(),function(t){var n;do if(n=O?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===H},focus:function(e){return e===q.activeElement&&(!q.hasFocus||q.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!T.pseudos.empty(e)},header:function(e){return me.test(e.nodeName)},input:function(e){return ge.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:l(function(){return[0]}),last:l(function(e,t){return[t-1]}),eq:l(function(e,t,n){return[n<0?n+t:n]}),even:l(function(e,t){for(var n=0;n=0;)e.push(r);return e}),gt:l(function(e,t,n){for(var r=n<0?n+t:n;++r2&&"ID"===(s=o[0]).type&&w.getById&&9===t.nodeType&&O&&T.relative[o[1].type]){if(t=(T.find.ID(s.matches[0].replace(we,Te),t)||[])[0],!t)return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}for(i=he.needsContext.test(e)?0:o.length;i--&&(s=o[i],!T.relative[a=s.type]);)if((u=T.find[a])&&(r=u(s.matches[0].replace(we,Te),xe.test(o[0].type)&&c(t.parentNode)||t))){if(o.splice(i,1),e=r.length&&p(o),!e)return K.apply(n,r),n;break}}return(l||E(e,f))(r,t,!O,n,xe.test(e)&&c(t.parentNode)||t),n},w.sortStable=W.split("").sort(U).join("")===W,w.detectDuplicates=!!A,L(),w.sortDetached=i(function(e){return 1&e.compareDocumentPosition(q.createElement("div"))}),i(function(e){return e.innerHTML="","#"===e.firstChild.getAttribute("href")})||o("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),w.attributes&&i(function(e){return e.innerHTML="",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||o("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),i(function(e){return null==e.getAttribute("disabled")})||o(te,function(e,t,n){var r;if(!n)return e[t]===!0?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),t}(e);Z.find=ie,Z.expr=ie.selectors,Z.expr[":"]=Z.expr.pseudos,Z.unique=ie.uniqueSort,Z.text=ie.getText,Z.isXMLDoc=ie.isXML,Z.contains=ie.contains;var oe=Z.expr.match.needsContext,se=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,ae=/^.[^:#\[\.,]*$/;Z.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?Z.find.matchesSelector(r,e)?[r]:[]:Z.find.matches(e,Z.grep(t,function(e){return 1===e.nodeType}))},Z.fn.extend({find:function(e){var t,n=this.length,r=[],i=this;if("string"!=typeof e)return this.pushStack(Z(e).filter(function(){
-for(t=0;t1?Z.unique(r):r),r.selector=this.selector?this.selector+" "+e:e,r},filter:function(e){return this.pushStack(r(this,e||[],!1))},not:function(e){return this.pushStack(r(this,e||[],!0))},is:function(e){return!!r(this,"string"==typeof e&&oe.test(e)?Z(e):e||[],!1).length}});var ue,le=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,ce=Z.fn.init=function(e,t){var n,r;if(!e)return this;if("string"==typeof e){if(n="<"===e[0]&&">"===e[e.length-1]&&e.length>=3?[null,e,null]:le.exec(e),!n||!n[1]&&t)return!t||t.jquery?(t||ue).find(e):this.constructor(t).find(e);if(n[1]){if(t=t instanceof Z?t[0]:t,Z.merge(this,Z.parseHTML(n[1],t&&t.nodeType?t.ownerDocument||t:J,!0)),se.test(n[1])&&Z.isPlainObject(t))for(n in t)Z.isFunction(this[n])?this[n](t[n]):this.attr(n,t[n]);return this}return r=J.getElementById(n[2]),r&&r.parentNode&&(this.length=1,this[0]=r),this.context=J,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):Z.isFunction(e)?"undefined"!=typeof ue.ready?ue.ready(e):e(Z):(void 0!==e.selector&&(this.selector=e.selector,this.context=e.context),Z.makeArray(e,this))};ce.prototype=Z.fn,ue=Z(J);var fe=/^(?:parents|prev(?:Until|All))/,pe={children:!0,contents:!0,next:!0,prev:!0};Z.extend({dir:function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&Z(e).is(n))break;r.push(e)}return r},sibling:function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}}),Z.fn.extend({has:function(e){var t=Z(e,this),n=t.length;return this.filter(function(){for(var e=0;e-1:1===n.nodeType&&Z.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?Z.unique(o):o)},index:function(e){return e?"string"==typeof e?U.call(Z(e),this[0]):U.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(Z.unique(Z.merge(this.get(),Z(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),Z.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return Z.dir(e,"parentNode")},parentsUntil:function(e,t,n){return Z.dir(e,"parentNode",n)},next:function(e){return i(e,"nextSibling")},prev:function(e){return i(e,"previousSibling")},nextAll:function(e){return Z.dir(e,"nextSibling")},prevAll:function(e){return Z.dir(e,"previousSibling")},nextUntil:function(e,t,n){return Z.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return Z.dir(e,"previousSibling",n)},siblings:function(e){return Z.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return Z.sibling(e.firstChild)},contents:function(e){return e.contentDocument||Z.merge([],e.childNodes)}},function(e,t){Z.fn[e]=function(n,r){var i=Z.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=Z.filter(r,i)),this.length>1&&(pe[e]||Z.unique(i),fe.test(e)&&i.reverse()),this.pushStack(i)}});var de=/\S+/g,he={};Z.Callbacks=function(e){e="string"==typeof e?he[e]||o(e):Z.extend({},e);var t,n,r,i,s,a,u=[],l=!e.once&&[],c=function(o){for(t=e.memory&&o,n=!0,a=i||0,i=0,s=u.length,r=!0;u&&a-1;)u.splice(n,1),r&&(n<=s&&s--,n<=a&&a--)}),this},has:function(e){return e?Z.inArray(e,u)>-1:!(!u||!u.length)},empty:function(){return u=[],s=0,this},disable:function(){return u=l=t=void 0,this},disabled:function(){return!u},lock:function(){return l=void 0,t||f.disable(),this},locked:function(){return!l},fireWith:function(e,t){return!u||n&&!l||(t=t||[],t=[e,t.slice?t.slice():t],r?l.push(t):c(t)),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!n}};return f},Z.extend({Deferred:function(e){var t=[["resolve","done",Z.Callbacks("once memory"),"resolved"],["reject","fail",Z.Callbacks("once memory"),"rejected"],["notify","progress",Z.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return Z.Deferred(function(n){Z.each(t,function(t,o){var s=Z.isFunction(e[t])&&e[t];i[o[1]](function(){var e=s&&s.apply(this,arguments);e&&Z.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[o[0]+"With"](this===r?n.promise():this,s?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?Z.extend(e,r):r}},i={};return r.pipe=r.then,Z.each(t,function(e,o){var s=o[2],a=o[3];r[o[1]]=s.add,a&&s.add(function(){n=a},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=s.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t,n,r,i=0,o=_.call(arguments),s=o.length,a=1!==s||e&&Z.isFunction(e.promise)?s:0,u=1===a?e:Z.Deferred(),l=function(e,n,r){return function(i){n[e]=this,r[e]=arguments.length>1?_.call(arguments):i,r===t?u.notifyWith(n,r):--a||u.resolveWith(n,r)}};if(s>1)for(t=new Array(s),n=new Array(s),r=new Array(s);i0||(ge.resolveWith(J,[Z]),Z.fn.triggerHandler&&(Z(J).triggerHandler("ready"),Z(J).off("ready"))))}}),Z.ready.promise=function(t){return ge||(ge=Z.Deferred(),"complete"===J.readyState?setTimeout(Z.ready):(J.addEventListener("DOMContentLoaded",s,!1),e.addEventListener("load",s,!1))),ge.promise(t)},Z.ready.promise();var me=Z.access=function(e,t,n,r,i,o,s){var a=0,u=e.length,l=null==n;if("object"===Z.type(n)){i=!0;for(a in n)Z.access(e,t,a,n[a],!0,o,s)}else if(void 0!==r&&(i=!0,Z.isFunction(r)||(s=!0),l&&(s?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(Z(e),n)})),t))for(;a1,null,!0)},removeData:function(e){return this.each(function(){ye.remove(this,e)})}}),Z.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=ve.get(e,t),n&&(!r||Z.isArray(n)?r=ve.access(e,t,Z.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=Z.queue(e,t),r=n.length,i=n.shift(),o=Z._queueHooks(e,t),s=function(){Z.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,s,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return ve.get(e,n)||ve.access(e,n,{empty:Z.Callbacks("once memory").add(function(){ve.remove(e,[t+"queue",n])})})}}),Z.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.lengthx",Q.noCloneChecked=!!t.cloneNode(!0).lastChild.defaultValue}();var ke="undefined";Q.focusinBubbles="onfocusin"in e;var Ee=/^key/,Se=/^(?:mouse|pointer|contextmenu)|click/,De=/^(?:focusinfocus|focusoutblur)$/,je=/^([^.]*)(?:\.(.+)|)$/;Z.event={global:{},add:function(e,t,n,r,i){var o,s,a,u,l,c,f,p,d,h,g,m=ve.get(e);if(m)for(n.handler&&(o=n,n=o.handler,i=o.selector),n.guid||(n.guid=Z.guid++),(u=m.events)||(u=m.events={}),(s=m.handle)||(s=m.handle=function(t){return typeof Z!==ke&&Z.event.triggered!==t.type?Z.event.dispatch.apply(e,arguments):void 0}),t=(t||"").match(de)||[""],l=t.length;l--;)a=je.exec(t[l])||[],d=g=a[1],h=(a[2]||"").split(".").sort(),d&&(f=Z.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=Z.event.special[d]||{},c=Z.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&Z.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||(p=u[d]=[],p.delegateCount=0,f.setup&&f.setup.call(e,r,h,s)!==!1||e.addEventListener&&e.addEventListener(d,s,!1)),f.add&&(f.add.call(e,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),Z.event.global[d]=!0)},remove:function(e,t,n,r,i){var o,s,a,u,l,c,f,p,d,h,g,m=ve.hasData(e)&&ve.get(e);if(m&&(u=m.events)){for(t=(t||"").match(de)||[""],l=t.length;l--;)if(a=je.exec(t[l])||[],d=g=a[1],h=(a[2]||"").split(".").sort(),d){for(f=Z.event.special[d]||{},d=(r?f.delegateType:f.bindType)||d,p=u[d]||[],a=a[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),s=o=p.length;o--;)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||a&&!a.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));s&&!p.length&&(f.teardown&&f.teardown.call(e,h,m.handle)!==!1||Z.removeEvent(e,d,m.handle),delete u[d])}else for(d in u)Z.event.remove(e,d+t[l],n,r,!0);Z.isEmptyObject(u)&&(delete m.handle,ve.remove(e,"events"))}},trigger:function(t,n,r,i){var o,s,a,u,l,c,f,p=[r||J],d=G.call(t,"type")?t.type:t,h=G.call(t,"namespace")?t.namespace.split("."):[];if(s=a=r=r||J,3!==r.nodeType&&8!==r.nodeType&&!De.test(d+Z.event.triggered)&&(d.indexOf(".")>=0&&(h=d.split("."),d=h.shift(),h.sort()),l=d.indexOf(":")<0&&"on"+d,t=t[Z.expando]?t:new Z.Event(d,"object"==typeof t&&t),t.isTrigger=i?2:3,t.namespace=h.join("."),t.namespace_re=t.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:Z.makeArray(n,[t]),f=Z.event.special[d]||{},i||!f.trigger||f.trigger.apply(r,n)!==!1)){if(!i&&!f.noBubble&&!Z.isWindow(r)){for(u=f.delegateType||d,De.test(u+d)||(s=s.parentNode);s;s=s.parentNode)p.push(s),a=s;a===(r.ownerDocument||J)&&p.push(a.defaultView||a.parentWindow||e)}for(o=0;(s=p[o++])&&!t.isPropagationStopped();)t.type=o>1?u:f.bindType||d,c=(ve.get(s,"events")||{})[t.type]&&ve.get(s,"handle"),c&&c.apply(s,n),c=l&&s[l],c&&c.apply&&Z.acceptData(s)&&(t.result=c.apply(s,n),t.result===!1&&t.preventDefault());return t.type=d,i||t.isDefaultPrevented()||f._default&&f._default.apply(p.pop(),n)!==!1||!Z.acceptData(r)||l&&Z.isFunction(r[d])&&!Z.isWindow(r)&&(a=r[l],a&&(r[l]=null),Z.event.triggered=d,r[d](),Z.event.triggered=void 0,a&&(r[l]=a)),t.result}},dispatch:function(e){e=Z.event.fix(e);var t,n,r,i,o,s=[],a=_.call(arguments),u=(ve.get(this,"events")||{})[e.type]||[],l=Z.event.special[e.type]||{};if(a[0]=e,e.delegateTarget=this,!l.preDispatch||l.preDispatch.call(this,e)!==!1){for(s=Z.event.handlers.call(this,e,u),t=0;(i=s[t++])&&!e.isPropagationStopped();)for(e.currentTarget=i.elem,n=0;(o=i.handlers[n++])&&!e.isImmediatePropagationStopped();)e.namespace_re&&!e.namespace_re.test(o.namespace)||(e.handleObj=o,e.data=o.data,r=((Z.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,a),void 0!==r&&(e.result=r)===!1&&(e.preventDefault(),e.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,e),e.result}},handlers:function(e,t){var n,r,i,o,s=[],a=t.delegateCount,u=e.target;if(a&&u.nodeType&&(!e.button||"click"!==e.type))for(;u!==this;u=u.parentNode||this)if(u.disabled!==!0||"click"!==e.type){for(r=[],n=0;n=0:Z.find(i,this,null,[u]).length),r[i]&&r.push(o);r.length&&s.push({elem:u,handlers:r})}return a]*)\/>/gi,Le=/<([\w:]+)/,qe=/<|?\w+;/,He=/<(?:script|style|link)/i,Oe=/checked\s*(?:[^=]|=\s*.checked.)/i,Fe=/^$|\/(?:java|ecma)script/i,Pe=/^true\/(.*)/,Re=/^\s*\s*$/g,Me={option:[1,""],thead:[1,""],col:[2,""],tr:[2,""],td:[3,""],_default:[0,"",""]};Me.optgroup=Me.option,Me.tbody=Me.tfoot=Me.colgroup=Me.caption=Me.thead,Me.th=Me.td,Z.extend({clone:function(e,t,n){var r,i,o,s,a=e.cloneNode(!0),u=Z.contains(e.ownerDocument,e);if(!(Q.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||Z.isXMLDoc(e)))for(s=v(a),o=v(e),r=0,i=o.length;r0&&g(s,!u&&v(e,"script")),a},buildFragment:function(e,t,n,r){for(var i,o,s,a,u,l,c=t.createDocumentFragment(),f=[],p=0,d=e.length;p$2>")+a[2],l=a[0];l--;)o=o.lastChild;Z.merge(f,o.childNodes),o=c.firstChild,o.textContent=""}else f.push(t.createTextNode(i));for(c.textContent="",p=0;i=f[p++];)if((!r||Z.inArray(i,r)===-1)&&(u=Z.contains(i.ownerDocument,i),o=v(c.appendChild(i),"script"),u&&g(o),n))for(l=0;i=o[l++];)Fe.test(i.type||"")&&n.push(i);return c},cleanData:function(e){for(var t,n,r,i,o=Z.event.special,s=0;void 0!==(n=e[s]);s++){if(Z.acceptData(n)&&(i=n[ve.expando],i&&(t=ve.cache[i]))){if(t.events)for(r in t.events)o[r]?Z.event.remove(n,r):Z.removeEvent(n,r,t.handle);ve.cache[i]&&delete ve.cache[i]}delete ye.cache[n[ye.expando]]}}}),Z.fn.extend({text:function(e){return me(this,function(e){return void 0===e?Z.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=p(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=p(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){for(var n,r=e?Z.filter(e,this):this,i=0;null!=(n=r[i]);i++)t||1!==n.nodeType||Z.cleanData(v(n)),n.parentNode&&(t&&Z.contains(n.ownerDocument,n)&&g(v(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(Z.cleanData(v(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return Z.clone(this,e,t)})},html:function(e){return me(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!He.test(e)&&!Me[(Le.exec(e)||["",""])[1].toLowerCase()]){e=e.replace(Ae,"<$1>$2>");try{for(;n1&&"string"==typeof p&&!Q.checkClone&&Oe.test(p))return this.each(function(n){var r=c.eq(n);g&&(e[0]=p.call(this,n,r.html())),r.domManip(e,t)});if(l&&(n=Z.buildFragment(e,this[0].ownerDocument,!1,this),r=n.firstChild,1===n.childNodes.length&&(n=r),r)){for(i=Z.map(v(n,"script"),d),o=i.length;u1)},show:function(){return S(this,!0)},hide:function(){return S(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){Ce(this)?Z(this).show():Z(this).hide()})}}),Z.Tween=D,D.prototype={constructor:D,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(Z.cssNumber[n]?"":"px")},cur:function(){var e=D.propHooks[this.prop];return e&&e.get?e.get(this):D.propHooks._default.get(this)},run:function(e){var t,n=D.propHooks[this.prop];return this.options.duration?this.pos=t=Z.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):D.propHooks._default.set(this),this}},D.prototype.init.prototype=D.prototype,D.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=Z.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){Z.fx.step[e.prop]?Z.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[Z.cssProps[e.prop]]||Z.cssHooks[e.prop])?Z.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},D.propHooks.scrollTop=D.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},Z.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},Z.fx=D.prototype.init,Z.fx.step={};var Qe,Je,Ke=/^(?:toggle|show|hide)$/,Ze=new RegExp("^(?:([+-])=|)("+we+")([a-z%]*)$","i"),et=/queueHooks$/,tt=[q],nt={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=Ze.exec(t),o=i&&i[3]||(Z.cssNumber[e]?"":"px"),s=(Z.cssNumber[e]||"px"!==o&&+r)&&Ze.exec(Z.css(n.elem,e)),a=1,u=20;if(s&&s[3]!==o){o=o||s[3],i=i||[],s=+r||1;do a=a||".5",s/=a,Z.style(n.elem,e,s+o);while(a!==(a=n.cur()/r)&&1!==a&&--u)}return i&&(s=n.start=+s||+r||0,n.unit=o,n.end=i[1]?s+(i[1]+1)*i[2]:+i[2]),n}]};Z.Animation=Z.extend(O,{tweener:function(e,t){Z.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");for(var n,r=0,i=e.length;r1)},removeAttr:function(e){return this.each(function(){Z.removeAttr(this,e)})}}),Z.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(e&&3!==o&&8!==o&&2!==o)return typeof e.getAttribute===ke?Z.prop(e,t,n):(1===o&&Z.isXMLDoc(e)||(t=t.toLowerCase(),r=Z.attrHooks[t]||(Z.expr.match.bool.test(t)?it:rt)),void 0===n?r&&"get"in r&&null!==(i=r.get(e,t))?i:(i=Z.find.attr(e,t),null==i?void 0:i):null!==n?r&&"set"in r&&void 0!==(i=r.set(e,n,t))?i:(e.setAttribute(t,n+""),n):void Z.removeAttr(e,t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(de);if(o&&1===e.nodeType)for(;n=o[i++];)r=Z.propFix[n]||n,Z.expr.match.bool.test(n)&&(e[r]=!1),e.removeAttribute(n)},attrHooks:{type:{set:function(e,t){if(!Q.radioValue&&"radio"===t&&Z.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}}}),it={set:function(e,t,n){return t===!1?Z.removeAttr(e,n):e.setAttribute(n,n),n}},Z.each(Z.expr.match.bool.source.match(/\w+/g),function(e,t){var n=ot[t]||Z.find.attr;ot[t]=function(e,t,r){var i,o;return r||(o=ot[t],ot[t]=i,i=null!=n(e,t,r)?t.toLowerCase():null,ot[t]=o),i}});var st=/^(?:input|select|textarea|button)$/i;Z.fn.extend({prop:function(e,t){return me(this,Z.prop,e,t,arguments.length>1)},removeProp:function(e){return this.each(function(){delete this[Z.propFix[e]||e]})}}),Z.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(e,t,n){var r,i,o,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return o=1!==s||!Z.isXMLDoc(e),o&&(t=Z.propFix[t]||t,i=Z.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){return e.hasAttribute("tabindex")||st.test(e.nodeName)||e.href?e.tabIndex:-1}}}}),Q.optSelected||(Z.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null}}),Z.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){Z.propFix[this.toLowerCase()]=this});var at=/[\t\r\n\f]/g;Z.fn.extend({addClass:function(e){var t,n,r,i,o,s,a="string"==typeof e&&e,u=0,l=this.length;if(Z.isFunction(e))return this.each(function(t){Z(this).addClass(e.call(this,t,this.className))});if(a)for(t=(e||"").match(de)||[];u=0;)r=r.replace(" "+i+" "," ");s=e?Z.trim(r):"",n.className!==s&&(n.className=s)}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):Z.isFunction(e)?this.each(function(n){Z(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if("string"===n)for(var t,r=0,i=Z(this),o=e.match(de)||[];t=o[r++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else n!==ke&&"boolean"!==n||(this.className&&ve.set(this,"__className__",this.className),this.className=this.className||e===!1?"":ve.get(this,"__className__")||"")})},hasClass:function(e){for(var t=" "+e+" ",n=0,r=this.length;n=0)return!0;return!1}});var ut=/\r/g;Z.fn.extend({val:function(e){var t,n,r,i=this[0];{if(arguments.length)return r=Z.isFunction(e),this.each(function(n){var i;1===this.nodeType&&(i=r?e.call(this,n,Z(this).val()):e,null==i?i="":"number"==typeof i?i+="":Z.isArray(i)&&(i=Z.map(i,function(e){return null==e?"":e+""})),t=Z.valHooks[this.type]||Z.valHooks[this.nodeName.toLowerCase()],t&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))});if(i)return t=Z.valHooks[i.type]||Z.valHooks[i.nodeName.toLowerCase()],t&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:(n=i.value,"string"==typeof n?n.replace(ut,""):null==n?"":n)}}}),Z.extend({valHooks:{option:{get:function(e){var t=Z.find.attr(e,"value");return null!=t?t:Z.trim(Z.text(e))}},select:{get:function(e){for(var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||i<0,s=o?null:[],a=o?i+1:r.length,u=i<0?a:o?i:0;u=0)&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),Z.each(["radio","checkbox"],function(){Z.valHooks[this]={set:function(e,t){if(Z.isArray(t))return e.checked=Z.inArray(Z(e).val(),t)>=0}},Q.checkOn||(Z.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),Z.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(e,t){Z.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),Z.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var lt=Z.now(),ct=/\?/;Z.parseJSON=function(e){return JSON.parse(e+"")},Z.parseXML=function(e){var t,n;if(!e||"string"!=typeof e)return null;try{n=new DOMParser,t=n.parseFromString(e,"text/xml")}catch(r){t=void 0}return t&&!t.getElementsByTagName("parsererror").length||Z.error("Invalid XML: "+e),t};var ft=/#.*$/,pt=/([?&])_=[^&]*/,dt=/^(.*?):[ \t]*([^\r\n]*)$/gm,ht=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,gt=/^(?:GET|HEAD)$/,mt=/^\/\//,vt=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,yt={},xt={},bt="*/".concat("*"),wt=e.location.href,Tt=vt.exec(wt.toLowerCase())||[];Z.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:wt,type:"GET",isLocal:ht.test(Tt[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":bt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":Z.parseJSON,"text xml":Z.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?R(R(e,Z.ajaxSettings),t):R(Z.ajaxSettings,e)},ajaxPrefilter:F(yt),ajaxTransport:F(xt),ajax:function(e,t){function n(e,t,n,s){var u,c,v,y,b,T=t;2!==x&&(x=2,a&&clearTimeout(a),r=void 0,o=s||"",w.readyState=e>0?4:0,u=e>=200&&e<300||304===e,n&&(y=M(f,w,n)),y=W(f,y,w,u),u?(f.ifModified&&(b=w.getResponseHeader("Last-Modified"),b&&(Z.lastModified[i]=b),b=w.getResponseHeader("etag"),b&&(Z.etag[i]=b)),204===e||"HEAD"===f.type?T="nocontent":304===e?T="notmodified":(T=y.state,c=y.data,v=y.error,u=!v)):(v=T,!e&&T||(T="error",e<0&&(e=0))),w.status=e,w.statusText=(t||T)+"",u?h.resolveWith(p,[c,T,w]):h.rejectWith(p,[w,T,v]),w.statusCode(m),m=void 0,l&&d.trigger(u?"ajaxSuccess":"ajaxError",[w,f,u?c:v]),g.fireWith(p,[w,T]),l&&(d.trigger("ajaxComplete",[w,f]),--Z.active||Z.event.trigger("ajaxStop")))}"object"==typeof e&&(t=e,e=void 0),t=t||{};var r,i,o,s,a,u,l,c,f=Z.ajaxSetup({},t),p=f.context||f,d=f.context&&(p.nodeType||p.jquery)?Z(p):Z.event,h=Z.Deferred(),g=Z.Callbacks("once memory"),m=f.statusCode||{},v={},y={},x=0,b="canceled",w={readyState:0,getResponseHeader:function(e){var t;if(2===x){if(!s)for(s={};t=dt.exec(o);)s[t[1].toLowerCase()]=t[2];t=s[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===x?o:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return x||(e=y[n]=y[n]||e,v[e]=t),this},overrideMimeType:function(e){return x||(f.mimeType=e),this},statusCode:function(e){var t;if(e)if(x<2)for(t in e)m[t]=[m[t],e[t]];else w.always(e[w.status]);return this},abort:function(e){var t=e||b;return r&&r.abort(t),n(0,t),this}};if(h.promise(w).complete=g.add,w.success=w.done,w.error=w.fail,f.url=((e||f.url||wt)+"").replace(ft,"").replace(mt,Tt[1]+"//"),f.type=t.method||t.type||f.method||f.type,f.dataTypes=Z.trim(f.dataType||"*").toLowerCase().match(de)||[""],null==f.crossDomain&&(u=vt.exec(f.url.toLowerCase()),f.crossDomain=!(!u||u[1]===Tt[1]&&u[2]===Tt[2]&&(u[3]||("http:"===u[1]?"80":"443"))===(Tt[3]||("http:"===Tt[1]?"80":"443")))),f.data&&f.processData&&"string"!=typeof f.data&&(f.data=Z.param(f.data,f.traditional)),P(yt,f,t,w),2===x)return w;l=Z.event&&f.global,l&&0===Z.active++&&Z.event.trigger("ajaxStart"),f.type=f.type.toUpperCase(),f.hasContent=!gt.test(f.type),i=f.url,f.hasContent||(f.data&&(i=f.url+=(ct.test(i)?"&":"?")+f.data,delete f.data),f.cache===!1&&(f.url=pt.test(i)?i.replace(pt,"$1_="+lt++):i+(ct.test(i)?"&":"?")+"_="+lt++)),f.ifModified&&(Z.lastModified[i]&&w.setRequestHeader("If-Modified-Since",Z.lastModified[i]),Z.etag[i]&&w.setRequestHeader("If-None-Match",Z.etag[i])),(f.data&&f.hasContent&&f.contentType!==!1||t.contentType)&&w.setRequestHeader("Content-Type",f.contentType),w.setRequestHeader("Accept",f.dataTypes[0]&&f.accepts[f.dataTypes[0]]?f.accepts[f.dataTypes[0]]+("*"!==f.dataTypes[0]?", "+bt+"; q=0.01":""):f.accepts["*"]);for(c in f.headers)w.setRequestHeader(c,f.headers[c]);if(f.beforeSend&&(f.beforeSend.call(p,w,f)===!1||2===x))return w.abort();b="abort";for(c in{success:1,error:1,complete:1})w[c](f[c]);if(r=P(xt,f,t,w)){w.readyState=1,l&&d.trigger("ajaxSend",[w,f]),f.async&&f.timeout>0&&(a=setTimeout(function(){w.abort("timeout")},f.timeout));try{x=1,r.send(v,n)}catch(T){if(!(x<2))throw T;n(-1,T)}}else n(-1,"No Transport");return w},getJSON:function(e,t,n){return Z.get(e,t,n,"json")},getScript:function(e,t){return Z.get(e,void 0,t,"script")}}),Z.each(["get","post"],function(e,t){Z[t]=function(e,n,r,i){return Z.isFunction(n)&&(i=i||r,r=n,n=void 0),Z.ajax({url:e,type:t,dataType:i,data:n,success:r})}}),Z._evalUrl=function(e){return Z.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},Z.fn.extend({wrapAll:function(e){var t;return Z.isFunction(e)?this.each(function(t){Z(this).wrapAll(e.call(this,t))}):(this[0]&&(t=Z(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e}).append(this)),this)},wrapInner:function(e){return Z.isFunction(e)?this.each(function(t){Z(this).wrapInner(e.call(this,t))}):this.each(function(){var t=Z(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=Z.isFunction(e);return this.each(function(n){Z(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){Z.nodeName(this,"body")||Z(this).replaceWith(this.childNodes)}).end()}}),Z.expr.filters.hidden=function(e){return e.offsetWidth<=0&&e.offsetHeight<=0},Z.expr.filters.visible=function(e){return!Z.expr.filters.hidden(e)};var Ct=/%20/g,Nt=/\[\]$/,kt=/\r?\n/g,Et=/^(?:submit|button|image|reset|file)$/i,St=/^(?:input|select|textarea|keygen)/i;Z.param=function(e,t){var n,r=[],i=function(e,t){t=Z.isFunction(t)?t():null==t?"":t,r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(void 0===t&&(t=Z.ajaxSettings&&Z.ajaxSettings.traditional),Z.isArray(e)||e.jquery&&!Z.isPlainObject(e))Z.each(e,function(){i(this.name,this.value)});else for(n in e)$(n,e[n],t,i);return r.join("&").replace(Ct,"+")},Z.fn.extend({serialize:function(){return Z.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=Z.prop(this,"elements");return e?Z.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!Z(this).is(":disabled")&&St.test(this.nodeName)&&!Et.test(e)&&(this.checked||!Ne.test(e))}).map(function(e,t){var n=Z(this).val();return null==n?null:Z.isArray(n)?Z.map(n,function(e){return{name:t.name,value:e.replace(kt,"\r\n")}}):{name:t.name,value:n.replace(kt,"\r\n")}}).get()}}),Z.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(e){}};var Dt=0,jt={},At={0:200,1223:204},Lt=Z.ajaxSettings.xhr();e.attachEvent&&e.attachEvent("onunload",function(){for(var e in jt)jt[e]()}),Q.cors=!!Lt&&"withCredentials"in Lt,Q.ajax=Lt=!!Lt,Z.ajaxTransport(function(e){var t;if(Q.cors||Lt&&!e.crossDomain)return{send:function(n,r){var i,o=e.xhr(),s=++Dt;if(o.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(i in e.xhrFields)o[i]=e.xhrFields[i];e.mimeType&&o.overrideMimeType&&o.overrideMimeType(e.mimeType),e.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest");for(i in n)o.setRequestHeader(i,n[i]);t=function(e){return function(){t&&(delete jt[s],t=o.onload=o.onerror=null,"abort"===e?o.abort():"error"===e?r(o.status,o.statusText):r(At[o.status]||o.status,o.statusText,"string"==typeof o.responseText?{text:o.responseText}:void 0,o.getAllResponseHeaders()))}},o.onload=t(),o.onerror=t("error"),t=jt[s]=t("abort");try{o.send(e.hasContent&&e.data||null)}catch(a){if(t)throw a}},abort:function(){t&&t()}}}),Z.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return Z.globalEval(e),e}}}),Z.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),Z.ajaxTransport("script",function(e){if(e.crossDomain){var t,n;return{send:function(r,i){t=Z("
-
-
-
-
-
-
-
+
+
-
+
-
+
-
-
-
-
-
-
-
-
+
+
+
-
-
+
+
-
-