diff --git a/packages/development-edition-engine-twig/patternlab-config.json b/packages/development-edition-engine-twig/patternlab-config.json
index 8fba803bd..c50ccbcda 100644
--- a/packages/development-edition-engine-twig/patternlab-config.json
+++ b/packages/development-edition-engine-twig/patternlab-config.json
@@ -114,7 +114,7 @@
"organisms": "source/_patterns/organisms/",
"templates": "source/_patterns/templates/",
"pages": "source/_patterns/pages/",
- "macros": "source/_macros/"
+ "macros": "source/_patterns/macros/"
}
}
}
diff --git a/packages/starterkit-twig-demo/dist/_data/data.json b/packages/starterkit-twig-demo/dist/_data/data.json
index 9c501164c..bd0708c07 100755
--- a/packages/starterkit-twig-demo/dist/_data/data.json
+++ b/packages/starterkit-twig-demo/dist/_data/data.json
@@ -86,7 +86,7 @@
"first_name": "Author",
"last_name": "Name"
},
- "hero": true,
+ "hero": {},
"emergency" : false,
"touts" : [
{ },
diff --git a/packages/starterkit-twig-demo/dist/_macros/.gitkeep b/packages/starterkit-twig-demo/dist/_patterns/macros/.gitkeep
similarity index 100%
rename from packages/starterkit-twig-demo/dist/_macros/.gitkeep
rename to packages/starterkit-twig-demo/dist/_patterns/macros/.gitkeep
diff --git a/packages/starterkit-twig-demo/dist/_patterns/macros/_macros.md b/packages/starterkit-twig-demo/dist/_patterns/macros/_macros.md
new file mode 100644
index 000000000..683af9f1a
--- /dev/null
+++ b/packages/starterkit-twig-demo/dist/_patterns/macros/_macros.md
@@ -0,0 +1,3 @@
+---
+hidden: true
+---
diff --git a/packages/starterkit-twig-demo/dist/_macros/forms.twig b/packages/starterkit-twig-demo/dist/_patterns/macros/forms.twig
similarity index 100%
rename from packages/starterkit-twig-demo/dist/_macros/forms.twig
rename to packages/starterkit-twig-demo/dist/_patterns/macros/forms.twig
diff --git a/packages/starterkit-twig-demo/dist/_patterns/organisms/sections/latest-posts.twig b/packages/starterkit-twig-demo/dist/_patterns/organisms/sections/latest-posts.twig
index 16e2d76c0..1d025439c 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/organisms/sections/latest-posts.twig
+++ b/packages/starterkit-twig-demo/dist/_patterns/organisms/sections/latest-posts.twig
@@ -2,7 +2,7 @@
Latest Posts
{% for post in latest_posts %}
- - {% include "@molecules/blocks/media-block.twig" %}
+ - {% include "@molecules/blocks/media-block.twig" with post %}
{% endfor %}
View more posts
diff --git a/packages/starterkit-twig-demo/dist/_patterns/pages/article.json b/packages/starterkit-twig-demo/dist/_patterns/pages/article.json
index 2f7eb842f..df2153ad7 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/pages/article.json
+++ b/packages/starterkit-twig-demo/dist/_patterns/pages/article.json
@@ -1,32 +1,32 @@
{
- "title" : "Top 10 Trails You Have To Hike Before You Die",
- "bodyClass": "article",
- "author" : {
- "first-name" : "Julianne",
- "last-name" : "McCormick"
- },
- "img": {
- "landscape_4x3": {
- "src": "../../images/sample/landscape-16x9-mountains.jpg",
- "alt": "Mountains",
- "width": "1151",
- "height": "638"
- },
- "landscape_16x9": {
- "src": "../../images/sample/landscape-16x9-mountains.jpg",
- "alt": "Mountains",
- "width": "1151",
- "height": "638"
- }
- },
- "inset_blocks" : [
- {
- "headline" : "This is the headline for the inset block"
- }
- ],
- "latest_block" : [
- {
- "headline" : "This is the headline for the latest block"
- }
- ]
+ "title": "Top 10 Trails You Have To Hike Before You Die",
+ "bodyClass": "article",
+ "author": {
+ "first_name": "Julianne",
+ "last_name": "McCormick"
+ },
+ "img": {
+ "landscape_4x3": {
+ "src": "../../images/sample/landscape-16x9-mountains.jpg",
+ "alt": "Mountains",
+ "width": "1151",
+ "height": "638"
+ },
+ "landscape_16x9": {
+ "src": "../../images/sample/landscape-16x9-mountains.jpg",
+ "alt": "Mountains",
+ "width": "1151",
+ "height": "638"
+ }
+ },
+ "inset_blocks": [
+ {
+ "headline": "This is the headline for the inset block"
+ }
+ ],
+ "latest_block": [
+ {
+ "headline": "This is the headline for the latest block"
+ }
+ ]
}
diff --git a/packages/starterkit-twig-demo/dist/_patterns/pages/blog.json b/packages/starterkit-twig-demo/dist/_patterns/pages/blog.json
index c5067e3e7..b702c2a95 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/pages/blog.json
+++ b/packages/starterkit-twig-demo/dist/_patterns/pages/blog.json
@@ -1,86 +1,86 @@
{
- "title" : "Blog",
- "bodyClass": "blog",
- "latest-posts" : [
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-river.jpg",
- "alt": "Post Thumbnail"
- }
- },
- "headline" : {
- "short" : "Navigate the Allegheny River"
- },
- "excerpt" : {
- "medium" : "The Allegheny River is a principal tributary of the Ohio River; it is located in the Eastern United States. The Allegheny River joins with the Monongahela River to form the Ohio River at the Point of Point State Park in Downtown Pittsburgh, Pennsylvania."
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-ivy.jpg",
- "alt": "Ivy"
- }
- },
- "headline" : {
- "short" : "How to detect and avoid poison ivy"
- },
- "excerpt" : {
- "medium" : "Toxicodendron radicans, commonly known as poison ivy is a poisonous North American plant that is well known for its production of urushiol"
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-yosemite.jpg",
- "alt": "Yosemite"
- }
- },
- "headline" : {
- "short" : "Top 10 hiking mountains"
- },
- "excerpt" : {
- "medium" : "Yosemite National Park is a United States National Park spanning eastern portions of Tuolumne, Mariposa and Madera counties in the central eastern portion of the U.S. state of California."
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-fire.jpg",
- "alt": "Fire"
- }
- },
- "headline" : {
- "short" : "How to build a campfire"
- },
- "excerpt" : {
- "medium" : "A campfire is a fire lit at a campsite, to serve the following functions: light, warmth, a beacon, an insect and/or apex predator deterrent, to cook, and for a psychological sense of security. "
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-gear.jpg",
- "alt": "Camping Gear"
- }
- },
- "headline" : {
- "short" : "Pick the right camping gear"
- },
- "excerpt" : {
- "medium" : "The equipment used in camping varies with the particular type of camping. For instance, in survival camping the equipment consists of small items which have the purpose of helping the camper in providing food, heat and safety."
- }
- }
- ],
- "inset_blocks" : [
- {
- "headline" : "This is the headline for the inset block"
- }
- ],
- "latest_block" : [
- {
- "headline" : "This is the headline for the latest block"
- }
- ]
-}
\ No newline at end of file
+ "title": "Blog",
+ "bodyClass": "blog",
+ "latest_posts": [
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-river.jpg",
+ "alt": "Post Thumbnail"
+ }
+ },
+ "headline": {
+ "short": "Navigate the Allegheny River"
+ },
+ "excerpt": {
+ "medium": "The Allegheny River is a principal tributary of the Ohio River; it is located in the Eastern United States. The Allegheny River joins with the Monongahela River to form the Ohio River at the Point of Point State Park in Downtown Pittsburgh, Pennsylvania."
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-ivy.jpg",
+ "alt": "Ivy"
+ }
+ },
+ "headline": {
+ "short": "How to detect and avoid poison ivy"
+ },
+ "excerpt": {
+ "medium": "Toxicodendron radicans, commonly known as poison ivy is a poisonous North American plant that is well known for its production of urushiol"
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-yosemite.jpg",
+ "alt": "Yosemite"
+ }
+ },
+ "headline": {
+ "short": "Top 10 hiking mountains"
+ },
+ "excerpt": {
+ "medium": "Yosemite National Park is a United States National Park spanning eastern portions of Tuolumne, Mariposa and Madera counties in the central eastern portion of the U.S. state of California."
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-fire.jpg",
+ "alt": "Fire"
+ }
+ },
+ "headline": {
+ "short": "How to build a campfire"
+ },
+ "excerpt": {
+ "medium": "A campfire is a fire lit at a campsite, to serve the following functions: light, warmth, a beacon, an insect and/or apex predator deterrent, to cook, and for a psychological sense of security. "
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-gear.jpg",
+ "alt": "Camping Gear"
+ }
+ },
+ "headline": {
+ "short": "Pick the right camping gear"
+ },
+ "excerpt": {
+ "medium": "The equipment used in camping varies with the particular type of camping. For instance, in survival camping the equipment consists of small items which have the purpose of helping the camper in providing food, heat and safety."
+ }
+ }
+ ],
+ "inset_blocks": [
+ {
+ "headline": "This is the headline for the inset block"
+ }
+ ],
+ "latest_block": [
+ {
+ "headline": "This is the headline for the latest block"
+ }
+ ]
+}
diff --git a/packages/starterkit-twig-demo/dist/_patterns/pages/homepage.json b/packages/starterkit-twig-demo/dist/_patterns/pages/homepage.json
index 9653d072c..e5446a262 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/pages/homepage.json
+++ b/packages/starterkit-twig-demo/dist/_patterns/pages/homepage.json
@@ -1,153 +1,151 @@
{
- "title" : "Home Page",
- "bodyClass": "home",
- "emergency" : false,
- "hero" : [
- {
- "img": {
- "landscape_16x9": {
- "src": "../../images/sample/landscape-16x9-mountains.jpg",
- "alt": "Mountains",
- "width": "1151",
- "height": "638"
- }
- },
- "headline" : {
- "medium" : "Top 10 mountain ranges for hiking"
- }
- }
- ],
- "touts" : [
- {
- "img": {
- "landscape_4x3": {
- "src": "../../images/sample/tout-4x3-climber.jpg",
- "alt": "Climber",
- "width": "640",
- "height": "480"
- }
- },
- "headline" : {
- "short" : "Extreme climbing tips"
- }
- },
- {
- "img": {
- "landscape_4x3": {
- "src": "../../images/sample/tout-4x3-stream.jpg",
- "alt": "Stream hiking",
- "width": "640",
- "height": "480"
- }
- },
- "headline" : {
- "short" : "Stream hiking"
- }
- },
- {
- "img": {
- "landscape_4x3": {
- "src": "../../images/sample/tout-4x3-climbers.jpg",
- "alt": "Explore hiking trails",
- "width": "640",
- "height": "480"
- }
- },
- "headline" : {
- "short" : "Explore hiking trails"
- }
- }
- ],
- "latest-posts" : [
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-river.jpg",
- "alt": "Post Thumbnail",
- "width": "600",
- "height": "600"
- }
- },
- "headline" : {
- "short" : "Navigate the Allegheny River"
- },
- "excerpt" : {
- "medium" : "The Allegheny River is a principal tributary of the Ohio River; it is located in the Eastern United States. The Allegheny River joins with the Monongahela River to form the Ohio River at the Point of Point State Park in Downtown Pittsburgh, Pennsylvania."
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-ivy.jpg",
- "alt": "Ivy",
- "width": "600",
- "height": "600"
- }
- },
- "headline" : {
- "short" : "How to detect and avoid poison ivy"
- },
- "excerpt" : {
- "medium" : "Toxicodendron radicans, commonly known as poison ivy is a poisonous North American plant that is well known for its production of urushiol"
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-yosemite.jpg",
- "alt": "Yosemite",
- "width": "600",
- "height": "600"
- }
- },
- "headline" : {
- "short" : "Top 10 hiking mountains"
- },
- "excerpt" : {
- "medium" : "Yosemite National Park is a United States National Park spanning eastern portions of Tuolumne, Mariposa and Madera counties in the central eastern portion of the U.S. state of California."
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-fire.jpg",
- "alt": "Fire",
- "width": "600",
- "height": "600"
- }
- },
- "headline" : {
- "short" : "How to build a campfire"
- },
- "excerpt" : {
- "medium" : "A campfire is a fire lit at a campsite, to serve the following functions: light, warmth, a beacon, an insect and/or apex predator deterrent, to cook, and for a psychological sense of security. "
- }
- },
- {
- "img": {
- "square": {
- "src": "../../images/sample/thumb-square-gear.jpg",
- "alt": "Camping Gear",
- "width": "600",
- "height": "600"
- }
- },
- "headline" : {
- "short" : "Pick the right camping gear"
- },
- "excerpt" : {
- "medium" : "The equipment used in camping varies with the particular type of camping. For instance, in survival camping the equipment consists of small items which have the purpose of helping the camper in providing food, heat and safety."
- }
- }
- ],
- "inset-blocks" : [
- {
- "headline" : "This is the headline for the inset block"
- }
- ],
- "latest-block" : [
- {
- "headline" : "This is the headline for the latest block"
- }
- ]
+ "title": "Home Page",
+ "bodyClass": "home",
+ "emergency": false,
+ "hero": {
+ "img": {
+ "landscape_16x9": {
+ "src": "../../images/sample/landscape-16x9-mountains.jpg",
+ "alt": "Mountains",
+ "width": "1151",
+ "height": "638"
+ }
+ },
+ "headline": {
+ "medium": "Top 10 mountain ranges for hiking"
+ }
+ },
+ "touts": [
+ {
+ "img": {
+ "landscape_4x3": {
+ "src": "../../images/sample/tout-4x3-climber.jpg",
+ "alt": "Climber",
+ "width": "640",
+ "height": "480"
+ }
+ },
+ "headline": {
+ "short": "Extreme climbing tips"
+ }
+ },
+ {
+ "img": {
+ "landscape_4x3": {
+ "src": "../../images/sample/tout-4x3-stream.jpg",
+ "alt": "Stream hiking",
+ "width": "640",
+ "height": "480"
+ }
+ },
+ "headline": {
+ "short": "Stream hiking"
+ }
+ },
+ {
+ "img": {
+ "landscape_4x3": {
+ "src": "../../images/sample/tout-4x3-climbers.jpg",
+ "alt": "Explore hiking trails",
+ "width": "640",
+ "height": "480"
+ }
+ },
+ "headline": {
+ "short": "Explore hiking trails"
+ }
+ }
+ ],
+ "latest_posts": [
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-river.jpg",
+ "alt": "Post Thumbnail",
+ "width": "600",
+ "height": "600"
+ }
+ },
+ "headline": {
+ "short": "Navigate the Allegheny River"
+ },
+ "excerpt": {
+ "medium": "The Allegheny River is a principal tributary of the Ohio River; it is located in the Eastern United States. The Allegheny River joins with the Monongahela River to form the Ohio River at the Point of Point State Park in Downtown Pittsburgh, Pennsylvania."
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-ivy.jpg",
+ "alt": "Ivy",
+ "width": "600",
+ "height": "600"
+ }
+ },
+ "headline": {
+ "short": "How to detect and avoid poison ivy"
+ },
+ "excerpt": {
+ "medium": "Toxicodendron radicans, commonly known as poison ivy is a poisonous North American plant that is well known for its production of urushiol"
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-yosemite.jpg",
+ "alt": "Yosemite",
+ "width": "600",
+ "height": "600"
+ }
+ },
+ "headline": {
+ "short": "Top 10 hiking mountains"
+ },
+ "excerpt": {
+ "medium": "Yosemite National Park is a United States National Park spanning eastern portions of Tuolumne, Mariposa and Madera counties in the central eastern portion of the U.S. state of California."
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-fire.jpg",
+ "alt": "Fire",
+ "width": "600",
+ "height": "600"
+ }
+ },
+ "headline": {
+ "short": "How to build a campfire"
+ },
+ "excerpt": {
+ "medium": "A campfire is a fire lit at a campsite, to serve the following functions: light, warmth, a beacon, an insect and/or apex predator deterrent, to cook, and for a psychological sense of security. "
+ }
+ },
+ {
+ "img": {
+ "square": {
+ "src": "../../images/sample/thumb-square-gear.jpg",
+ "alt": "Camping Gear",
+ "width": "600",
+ "height": "600"
+ }
+ },
+ "headline": {
+ "short": "Pick the right camping gear"
+ },
+ "excerpt": {
+ "medium": "The equipment used in camping varies with the particular type of camping. For instance, in survival camping the equipment consists of small items which have the purpose of helping the camper in providing food, heat and safety."
+ }
+ }
+ ],
+ "inset-blocks": [
+ {
+ "headline": "This is the headline for the inset block"
+ }
+ ],
+ "latest-block": [
+ {
+ "headline": "This is the headline for the latest block"
+ }
+ ]
}
diff --git a/packages/starterkit-twig-demo/dist/_patterns/pages/homepage~emergency.json b/packages/starterkit-twig-demo/dist/_patterns/pages/homepage~emergency.json
index 0f4e4c393..c289ece6c 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/pages/homepage~emergency.json
+++ b/packages/starterkit-twig-demo/dist/_patterns/pages/homepage~emergency.json
@@ -1,8 +1,8 @@
{
- "emergency": {
- "additionalClasses": "error",
- "excerpt" : {
- "short" : "Emergency! This is a variation of the core homepage template."
- }
- }
+ "emergency": {
+ "additionalClasses": "error",
+ "excerpt": {
+ "short": "Emergency! This is a variation of the core homepage template."
+ }
+ }
}
diff --git a/packages/starterkit-twig-demo/dist/_patterns/templates/blog.twig b/packages/starterkit-twig-demo/dist/_patterns/templates/blog.twig
index 3aa69798a..d8baef2b0 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/templates/blog.twig
+++ b/packages/starterkit-twig-demo/dist/_patterns/templates/blog.twig
@@ -1,8 +1,8 @@
-{% extends "@templates/layouts/site.twig" %}
+{% extends "@templates/layouts/page-2col.twig" %}
{% block title %}Our Outdoor Blog
{% endblock %}
{% block main %}
- {% include "@organisms/sections/latest-posts.twig" %}
+ {% include "@organisms/sections/latest-posts.twig" with { 'latest_posts': latest_posts} %}
{% include "@molecules/navigation/pagination.twig" %}
{% endblock %}
diff --git a/packages/starterkit-twig-demo/dist/_patterns/templates/homepage.twig b/packages/starterkit-twig-demo/dist/_patterns/templates/homepage.twig
index 742e10621..3313e7bc2 100644
--- a/packages/starterkit-twig-demo/dist/_patterns/templates/homepage.twig
+++ b/packages/starterkit-twig-demo/dist/_patterns/templates/homepage.twig
@@ -4,13 +4,13 @@
{% include "@molecules/messaging/alert.twig" with emergency %}
{% endif %}
{% if hero %}
- {% include "@molecules/blocks/block-hero.twig" %}
+ {% include "@molecules/blocks/block-hero.twig" with hero %}
{% endif %}
{% for tout in touts %}
- {% include "@molecules/blocks/block-inset.twig" %}
+ {% include "@molecules/blocks/block-inset.twig" with tout %}
{% endfor %}
@@ -23,7 +23,7 @@
Latest Posts
{% for post in latest_posts %}
- - {% include "@molecules/blocks/media-block.twig" %}
+ - {% include "@molecules/blocks/media-block.twig" with post %}
{% endfor %}
View more posts
diff --git a/packages/starterkit-twig-demo/patternlab-config.json b/packages/starterkit-twig-demo/patternlab-config.json
index 099f03c03..f63ce7a53 100644
--- a/packages/starterkit-twig-demo/patternlab-config.json
+++ b/packages/starterkit-twig-demo/patternlab-config.json
@@ -45,7 +45,7 @@
"id": "macros",
"recursive": true,
"paths": [
- "source/_macros"
+ "source/_patterns/macros"
]
}
]