Compare commits
No commits in common. "monogram-with-one-image" and "main" have entirely different histories.
monogram-w
...
main
|
|
@ -1,29 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
|
||||||
<svg width="100%" height="100%" viewBox="0 0 600 900" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;">
|
|
||||||
<g id="Artboard1" transform="matrix(0.133333,0,0,0.1875,0,0)">
|
|
||||||
<rect x="0" y="0" width="4500" height="4800" style="fill:none;"/>
|
|
||||||
<clipPath id="_clip1">
|
|
||||||
<rect x="0" y="0" width="4500" height="4800"/>
|
|
||||||
</clipPath>
|
|
||||||
<g clip-path="url(#_clip1)">
|
|
||||||
<g transform="matrix(1,0,0,1,-6960,-6096)">
|
|
||||||
<g transform="matrix(3.30882,0,0,2.35294,3710.74,3458.35)">
|
|
||||||
<path d="M1662,1801L982,1121L982,1801L1662,1801Z" style="fill:rgb(35,31,32);"/>
|
|
||||||
</g>
|
|
||||||
<g transform="matrix(3.30882,0,0,2.35294,5960.74,3458.35)">
|
|
||||||
<path d="M1662,1801L982,1121L982,1801L1662,1801Z" style="fill:rgb(35,31,32);"/>
|
|
||||||
</g>
|
|
||||||
<g transform="matrix(2.02607e-16,2.35294,-3.30882,1.44076e-16,15169.2,5385.41)">
|
|
||||||
<path d="M1662,1801L982,1121L982,1801L1662,1801Z" style="fill:rgb(35,31,32);"/>
|
|
||||||
</g>
|
|
||||||
<g transform="matrix(3.30882,0,0,2.35294,3710.74,5058.35)">
|
|
||||||
<path d="M1662,1801L982,1121L982,1801L1662,1801Z" style="fill:rgb(35,31,32);"/>
|
|
||||||
</g>
|
|
||||||
<g transform="matrix(3.30882,0,0,2.35294,3710.74,6658.35)">
|
|
||||||
<path d="M1662,1801L982,1121L982,1801L1662,1801Z" style="fill:rgb(35,31,32);"/>
|
|
||||||
</g>
|
|
||||||
</g>
|
|
||||||
</g>
|
|
||||||
</g>
|
|
||||||
</svg>
|
|
||||||
|
Before Width: | Height: | Size: 1.8 KiB |
74
index.html
74
index.html
|
|
@ -10,48 +10,44 @@
|
||||||
|
|
||||||
<div class="main">
|
<div class="main">
|
||||||
<div class="monogram">
|
<div class="monogram">
|
||||||
|
|
||||||
|
<div class="column">
|
||||||
|
<a href="#" class="triangle triangle-bottom">
|
||||||
|
<img src="https://placekitten.com/300/300">
|
||||||
|
<div class="triangle-label">Linguist</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="#" class="triangle triangle-bottom">
|
||||||
|
<img src="https://placekitten.com/300/300">
|
||||||
|
<div class="triangle-label">Quilter</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="#" class="triangle triangle-bottom">
|
||||||
|
<img src="https://placekitten.com/300/300">
|
||||||
|
<div class="triangle-label">Blog</div>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="column">
|
||||||
|
<a href="#" class="triangle triangle-bottom">
|
||||||
|
<img src="https://placekitten.com/300/300">
|
||||||
|
<div class="triangle-label multiline">Applied<br>Statistician</div>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
<a href="#" class="triangle triangle-top">
|
||||||
|
<img src="https://placekitten.com/200/200">
|
||||||
|
<div class="triangle-label">Knitter</div>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="intro">
|
|
||||||
<div class="bio"> I'm <h1>Elizabeth Pankratz</h1>,<br>
|
<div class="navigation">
|
||||||
a <a class="linguist" href="#">linguist</a>,
|
<h1> Elizabeth Pankratz </h1>
|
||||||
<a class="textileartist" href="#">textile artist</a>,
|
<a href="#">about</a>
|
||||||
and <a class="statistician" href="#">applied statistician</a>
|
<a href="#">blog</a>
|
||||||
</div>
|
<a href="#">contact</a>
|
||||||
<div class="links">
|
|
||||||
<a href="#">about</a>
|
|
||||||
<a href="#">blog</a>
|
|
||||||
<a href="#">contact</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script>
|
|
||||||
|
|
||||||
const monogram = document.querySelector('.monogram');
|
|
||||||
|
|
||||||
const links = [
|
|
||||||
{ element: document.querySelector('.intro a.linguist'), name: 'linguist' },
|
|
||||||
{ element: document.querySelector('.intro a.statistician'), name: 'statistician' },
|
|
||||||
{ element: document.querySelector('.intro a.textileartist'), name: 'textileartist' },
|
|
||||||
];
|
|
||||||
|
|
||||||
const bgs = {
|
|
||||||
linguist: 'http://placekitten.com/200/300',
|
|
||||||
textileartist: 'http://placekitten.com/500/300',
|
|
||||||
statistician: 'http://placekitten.com/200/400',
|
|
||||||
};
|
|
||||||
|
|
||||||
links.forEach((link) => {
|
|
||||||
console.log(link);
|
|
||||||
link.element.addEventListener('mouseover', (event) => {
|
|
||||||
monogram.style.backgroundImage = `url(${bgs[link.name]})`;
|
|
||||||
});
|
|
||||||
link.element.addEventListener('mouseout', (event) => {
|
|
||||||
monogram.style.backgroundImage = 'none';
|
|
||||||
});
|
|
||||||
})
|
|
||||||
|
|
||||||
</script>
|
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
106
style.css
106
style.css
|
|
@ -26,7 +26,7 @@ body {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: [gutter-left] 1fr [content-column] max(25vw) [gutter-right] 1fr;
|
grid-template-columns: [gutter-left] 1fr [content-column] 1fr [gutter-right] 1fr;
|
||||||
grid-template-rows: [header] 1fr [center] 1fr [footer] 1fr;
|
grid-template-rows: [header] 1fr [center] 1fr [footer] 1fr;
|
||||||
font-family: 'Fira Sans', sans-serif;
|
font-family: 'Fira Sans', sans-serif;
|
||||||
}
|
}
|
||||||
|
|
@ -40,52 +40,98 @@ body {
|
||||||
/* Monogram */
|
/* Monogram */
|
||||||
|
|
||||||
.monogram {
|
.monogram {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle {
|
||||||
|
display: block; /* Because these are <a> tags */
|
||||||
|
background-color: black;
|
||||||
|
position: relative; /* Required for the absolute positioning of the triangle-label */
|
||||||
|
width: 20vh;
|
||||||
|
height: 20vh;
|
||||||
|
max-width: 40vw;
|
||||||
|
max-height: 40vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle-bottom {
|
||||||
|
clip-path: polygon(0 0, 0 100%, 100% 100%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle-top {
|
||||||
|
clip-path: polygon(0 0, 0 100%, 100% 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle img {
|
||||||
|
display: block; /* Prevents the annoying inline-block gap after */
|
||||||
|
filter: grayscale(100%);
|
||||||
|
mix-blend-mode: overlay;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
aspect-ratio: 2 / 3;
|
height: 100%;
|
||||||
mask-image: url('assets/images/monogram.svg');
|
}
|
||||||
background: black;
|
|
||||||
background-size: cover;
|
.triangle:hover {
|
||||||
|
background-color: hsl(50, 90%, 50%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle-label {
|
||||||
|
position: absolute;
|
||||||
|
color: black;
|
||||||
|
left: 0.5rem;
|
||||||
|
bottom: 0.5rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle-label.multiline {
|
||||||
|
margin-top: -2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle-top .triangle-label {
|
||||||
|
top: 0.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* Title and links */
|
/* Title and links */
|
||||||
|
|
||||||
h1 {
|
h1 {
|
||||||
display: inline;
|
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
font-size: 1em;
|
font-size: 1.7rem;
|
||||||
|
margin-top: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.intro {
|
.navigation {
|
||||||
margin-top: 2em;
|
font-size: 1.4rem;
|
||||||
font-size: 1.5rem;
|
|
||||||
line-height: 1.4;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.intro .bio {
|
.navigation a {
|
||||||
margin-bottom: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.intro .links {
|
|
||||||
display: flex;
|
|
||||||
gap: 1.5ch;
|
|
||||||
}
|
|
||||||
|
|
||||||
.intro a {
|
|
||||||
color: black;
|
color: black;
|
||||||
border-left: 0.33ch solid rgba(0,0,0,0);
|
text-decoration: none;
|
||||||
border-right: 0.33ch solid rgba(0,0,0,0);
|
margin-left: -0.25ch;
|
||||||
margin-left: -0.33ch;
|
border-left: 0.25ch solid rgba(0,0,0,0);
|
||||||
margin-right: -0.33ch;
|
border-right: 0.25ch solid rgba(0,0,0,0);
|
||||||
|
margin-right: 0.75ch;
|
||||||
}
|
}
|
||||||
|
|
||||||
.intro a:visited {
|
.navigation a:visited {
|
||||||
color: black;
|
color: black;
|
||||||
}
|
}
|
||||||
|
|
||||||
.intro a:active,
|
.navigation a:active,
|
||||||
.intro a:hover {
|
.navigation a:hover {
|
||||||
background-color:hsl(50, 100%, 70%);
|
background-color:hsl(50, 100%, 70%);
|
||||||
border-left: 0.33ch solid hsl(50, 100%, 70%);
|
border-left: 0.25ch solid hsl(50, 100%, 70%);
|
||||||
border-right: 0.33ch solid hsl(50, 100%, 70%);
|
border-right: 0.25ch solid hsl(50, 100%, 70%);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Adjustments for touchscreen devices */
|
||||||
|
|
||||||
|
@media (hover: none) {
|
||||||
|
.triangle-label {
|
||||||
|
color: white;
|
||||||
|
opacity: 0.75;
|
||||||
|
}
|
||||||
|
|
||||||
|
.triangle:hover .triangle-label {
|
||||||
|
color: black;
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue