-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
1 parent
db4f000
commit ba390aa
Showing
19 changed files
with
118 additions
and
11 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
.blocks { | ||
display: flex; | ||
flex-direction: column; | ||
} | ||
|
||
.blocks__block + .blocks__block { | ||
margin-top: $gutter; | ||
} | ||
|
||
.blocks__block--divider { | ||
display: flex; | ||
flex-direction: row; | ||
flex-wrap: wrap; | ||
font-family: $font-family-sans; | ||
font-size: rem(18); | ||
justify-content: center; | ||
margin: 1rem 0; | ||
position: relative; | ||
width: 100%; | ||
|
||
&::before { | ||
border-bottom: solid rem(2); | ||
content: ""; | ||
display: block; | ||
position: absolute; | ||
top: 0.75em; | ||
width: 100%; | ||
} | ||
} | ||
|
||
.blocks__block--divider span { | ||
background-color: var(--parent-background-color, $white); | ||
padding: 0 rem(12); | ||
z-index: 1; | ||
} | ||
|
||
@include breakpoint-up(md) { | ||
.blocks { | ||
flex-direction: row; | ||
} | ||
|
||
.blocks__block + .blocks__block { | ||
margin-left: $gutter; | ||
margin-top: 0; | ||
} | ||
|
||
.blocks__block--divider { | ||
display: block; | ||
margin: 0 1.5rem; | ||
width: auto; | ||
|
||
&::before { | ||
border-bottom: 0; | ||
border-left: solid rem(2); | ||
height: 100%; | ||
left: 50%; | ||
top: 0; | ||
width: rem(2); | ||
} | ||
} | ||
|
||
.blocks__block--divider span { | ||
padding: rem(12) 0; | ||
position: relative; | ||
top: calc(50% - 1em); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
module.exports = { | ||
status: 'wip', | ||
title: 'Block Divider', | ||
context: { | ||
text: 'or' | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<div class="blocks__block--divider"> | ||
<span>{{ text }}</span> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
module.exports = { | ||
title: 'Colors', | ||
status: 'ready', | ||
order: 1, | ||
order: 10, | ||
context: { | ||
colors: { | ||
brand: [ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
module.exports = { | ||
status: 'ready', | ||
title: 'Dividers', | ||
order: 4, | ||
order: 40, | ||
context: { | ||
dividers: [ | ||
{ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module.exports = { | ||
title: 'Form Elements', | ||
order: 10, | ||
order: 100, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
module.exports = { | ||
title: 'Typography', | ||
status: 'wip', | ||
order: 3 | ||
order: 30 | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Responsive Blocks | ||
|
||
This molecule presents two blocks stacked on mobile and as columns on desktop, with an optional text divider. |
19 changes: 19 additions & 0 deletions
19
src/components/molecules/responsive-blocks/responsive-blocks.config.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
module.exports = { | ||
title: 'Responsive Blocks', | ||
status: 'wip', | ||
order: 17, | ||
context: { | ||
divider: true, | ||
dividerText: 'or' | ||
}, | ||
variants: [ | ||
{ | ||
name: 'Inverse', | ||
label: 'Inverse', | ||
context: { | ||
modifier: 'inverse', | ||
bodyClass: 'has-blue-500-background-color' | ||
} | ||
} | ||
] | ||
}; |
7 changes: 7 additions & 0 deletions
7
src/components/molecules/responsive-blocks/responsive-blocks.njk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<div class="blocks{% if modifier %} blocks--{{ modifier }}{% endif %}"> | ||
<div class="blocks__block">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.</div> | ||
{% if divider %} | ||
{% render '@block-divider', {text: dividerText}, true %} | ||
{% endif %} | ||
<div class="blocks__block">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.</div> | ||
</div> |