More Scaffold and first layouts

This commit is contained in:
2020-08-21 16:50:22 +02:00
parent fab49a09fb
commit 232c869d43
20 changed files with 495 additions and 1 deletions

View File

@@ -0,0 +1,46 @@
@mixin align-content {
* {
text-align: unset;
display: flex;
flex-direction: row;
}
&--fixedSize {
flex: 0 0;
width: min-content;
}
&--center {
text-align: center;
* {
justify-content: center;
}
}
&--left {
text-align: left;
* {
justify-content: flex-start;
}
}
&--right {
text-align: right;
* {
justify-content: flex-end;
}
}
}
@mixin reset {
margin: 0;
padding: 0;
top: 0;
bottom: 0;
left: 0;
right: 0;
}

View File

@@ -0,0 +1 @@
@import './alignment';

View File

@@ -0,0 +1,3 @@
@import 'flexRow/flexRow';
@import 'flexGrid/flexGrid';
@import 'contentCrop/contentCrop';

View File

@@ -0,0 +1,41 @@
RV-ContentCrop{
&,* {
overflow: hidden;
word-break: break-all;
}
img {
width: inherit;
height: inherit;
object-fit: cover;
object-position: center;
}
&--left {
img {
object-position: left;
}
}
&--right {
img {
object-position: right;
}
}
&--top {
img {
object-position: top;
}
}
&--bottom {
img {
object-position: bottom;
}
}
}
.RV-ContentCrop__Container {
@extend RV-ContentCrop;
}

View File

@@ -0,0 +1 @@
{}

View File

@@ -0,0 +1,52 @@
<h2>Square</h2>
<div class="square RV-ContentCrop__Container">
<img src="https://chaos.social/system/cache/media_attachments/files/104/671/839/925/195/715/original/e4f70d2ece69c688.png?1598017940"/>
</div>
<div class="square RV-ContentCrop__Container">
<p>You could see there was text coming out of her eyes, text coming out of her wherever. Trump Ipsum is calling for a total and complete shutdown of Muslim text entering your website. Does everybody know that pig named Lorem Ipsum? She's a disgusting pig, right? When other websites give you text, theyre not sending the best. Theyre not sending you, theyre sending words that have lots of problems and theyre bringing those problems with us. Theyre bringing mistakes. Theyre bringing misspellings. Theyre typists… And some, I assume, are good words. I'm speaking with myself, number one, because I have a very good brain and I've said a lot of things. Podcasting operational change management inside of workflows to establish a framework. Taking seamless key performance indicators offline to maximise the long tail. Keeping your eye on the ball while performing a deep dive on the start-up mentality to derive convergence on cross-platform integration.</p>
</div>
<div class="square RV-ContentCrop__Container">
<div class="portrait red"></div>
</div>
<h2>Landscape</h2>
<div class="landscape RV-ContentCrop__Container">
<img src="https://chaos.social/system/cache/media_attachments/files/104/671/839/925/195/715/original/e4f70d2ece69c688.png?1598017940"/>
</div>
<div class="landscape RV-ContentCrop__Container">
<p>You could see there was text coming out of her eyes, text coming out of her wherever. Trump Ipsum is calling for a total and complete shutdown of Muslim text entering your website. Does everybody know that pig named Lorem Ipsum? She's a disgusting pig, right? When other websites give you text, theyre not sending the best. Theyre not sending you, theyre sending words that have lots of problems and theyre bringing those problems with us. Theyre bringing mistakes. Theyre bringing misspellings. Theyre typists… And some, I assume, are good words. I'm speaking with myself, number one, because I have a very good brain and I've said a lot of things. Podcasting operational change management inside of workflows to establish a framework. Taking seamless key performance indicators offline to maximise the long tail. Keeping your eye on the ball while performing a deep dive on the start-up mentality to derive convergence on cross-platform integration.</p>
</div>
<div class="landscape RV-ContentCrop__Container">
<div class="portrait red"></div>
</div>
<h2>Portrait</h2>
<div class="portrait RV-ContentCrop__Container">
<img src="https://chaos.social/system/cache/media_attachments/files/104/671/839/925/195/715/original/e4f70d2ece69c688.png?1598017940"/>
</div>
<div class="portrait RV-ContentCrop__Container">
<p>You could see there was text coming out of her eyes, text coming out of her wherever. Trump Ipsum is calling for a total and complete shutdown of Muslim text entering your website. Does everybody know that pig named Lorem Ipsum? She's a disgusting pig, right? When other websites give you text, theyre not sending the best. Theyre not sending you, theyre sending words that have lots of problems and theyre bringing those problems with us. Theyre bringing mistakes. Theyre bringing misspellings. Theyre typists… And some, I assume, are good words. I'm speaking with myself, number one, because I have a very good brain and I've said a lot of things. Podcasting operational change management inside of workflows to establish a framework. Taking seamless key performance indicators offline to maximise the long tail. Keeping your eye on the ball while performing a deep dive on the start-up mentality to derive convergence on cross-platform integration.</p>
</div>
<div class="portrait RV-ContentCrop__Container">
<div class="landscape red"></div>
</div>
<h2>Full width</h2>
<div class="full-width RV-ContentCrop__Container">
<img src="https://chaos.social/system/cache/media_attachments/files/104/671/839/925/195/715/original/e4f70d2ece69c688.png?1598017940"/>
</div>
<div class="ull-width RV-ContentCrop__Container">
<p>You could see there was text coming out of her eyes, text coming out of her wherever. Trump Ipsum is calling for a total and complete shutdown of Muslim text entering your website. Does everybody know that pig named Lorem Ipsum? She's a disgusting pig, right? When other websites give you text, theyre not sending the best. Theyre not sending you, theyre sending words that have lots of problems and theyre bringing those problems with us. Theyre bringing mistakes. Theyre bringing misspellings. Theyre typists… And some, I assume, are good words. I'm speaking with myself, number one, because I have a very good brain and I've said a lot of things. Podcasting operational change management inside of workflows to establish a framework. Taking seamless key performance indicators offline to maximise the long tail. Keeping your eye on the ball while performing a deep dive on the start-up mentality to derive convergence on cross-platform integration.</p>
</div>
<div class="full-width RV-ContentCrop__Container">
<div class="portrait red"></div>
</div>

View File

@@ -0,0 +1,20 @@
RV-FlexGrid{
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
&--sameHeight {
grid-auto-rows: 1fr;
}
&--spacing {
gap: 10px;
}
}
.RV-FlexGrid__Container {
@extend RV-FlexGrid;
.RV-FlexGrid__Item {
@include align-content;
}
}

View File

@@ -0,0 +1 @@
{}

View File

@@ -0,0 +1,31 @@
<div class="RV-FlexGrid__Container">
<div class="red RV-FlexGrid__Item">Heres</div>
<div class="green RV-FlexGrid__Item">some</div>
<div class="red RV-FlexGrid__Item">totally</div>
<div class="green RV-FlexGrid__Item">awesome</div>
<div class="red RV-FlexGrid__Item">content</div>
<div class="green RV-FlexGrid__Item">for</div>
<div class="red RV-FlexGrid__Item">you</div>
<div class="green RV-FlexGrid__Item">only</div>
<div class="red RV-FlexGrid__Item">for</div>
<div class="green RV-FlexGrid__Item">you</div>
<div class="red RV-FlexGrid__Item">to</div>
<div class="green RV-FlexGrid__Item">enjoy</div>
</div>
<br><br>
<div class="RV-FlexGrid__Container RV-FlexGrid__Container--sameHeight">
<div class="red RV-FlexGrid__Item">Heres</div>
<div class="green RV-FlexGrid__Item">some</div>
<div class="red RV-FlexGrid__Item RV-FlexGrid__Item--right">totally (right)</div>
<div class="green RV-FlexGrid__Item RV-FlexGrid__Item--center">awesome</div>
<div class="red RV-FlexGrid__Item">content</div>
<div class="green RV-FlexGrid__Item">for</div>
<div class="red RV-FlexGrid__Item">you <br>(im sneaking in some height)</div>
<div class="green RV-FlexGrid__Item">only</div>
<div class="red RV-FlexGrid__Item RV-FlexGrid__Item--fixedSize">fixed for</div>
<div class="green RV-FlexGrid__Item">you</div>
<div class="red RV-FlexGrid__Item">to</div>
<div class="green RV-FlexGrid__Item">enjoy</div>
</div>

View File

@@ -0,0 +1,22 @@
RV-FlexRow {
display: flex;
flex-direction: row;
gap: 10px;
justify-content: space-around;
&--wrap {
flex-wrap: wrap;
}
* {
width: 100%;
}
}
.RV-FlexRow__Container {
@extend RV-FlexRow;
.RV-FlexRow__Item {
@include align-content;
}
}

View File

@@ -0,0 +1 @@
{}

View File

@@ -0,0 +1,12 @@
<div class="RV-FlexRow__Container">
<div class="red RV-FlexRow__Item">Im normal</div>
<div class="green RV-FlexRow__Item RV-FlexRow__Item--right">Right</div>
<div class="red RV-FlexRow__Item RV-FlexRow__Item--center">Center</div>
<div class="green RV-FlexRow__Item RV-FlexRow__Item--left"><span>wrapped content left</span></div>
<div class="red RV-FlexRow__Item RV-FlexRow__Item--fixedSize">Fixed</div>
</div>
<br></br>
<div class="RV-FlexRow__Container">
<div class="red RV-FlexRow__Item">Im normal</div>
<div class="green RV-FlexRow__Item RV-FlexRow__Item--right RV-FlexRow__Item--fixedSize">Right</div>
</div>

View File

@@ -0,0 +1,2 @@
@import '00_Global/global';
@import '01_Layouts/layouts';

41
components/_preview.hbs Normal file
View File

@@ -0,0 +1,41 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="{{ path '/rcss.css' }}">
<title>Preview</title>
<style>
.red{
background-color: firebrick;
}
.green {
background-color: forestgreen;
}
.square {
height: 300px;
width: 300px;
}
.portrait {
height: 320px;
width: 180px;
}
.landscape {
width: 320px;
height: 180px;
}
.full-width {
width: 100%;
height: 300px;
}
</style>
</head>
<body>
{{{ yield }}}
</body>
</html>

3
components/pink.css Normal file
View File

@@ -0,0 +1,3 @@
.pink {
background-color: pink;
}

View File

@@ -0,0 +1,2 @@
@import './components';
@import './pink.css';