diff --git a/README.md b/README.md index b93ec95..6d71ac3 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,11 @@ -# Personal website +# Personal website project A really great way to stand out during the job hunting process is to have a personal website where hiring managers can learn a bit more about your skills and interests. Throughout the course you will produce projects which will demonstrate the skills you have learned. By publishing your favourite projects on the web alongside the source code on Github you will be able to share your understanding and ability with potential hiring companies. +## Brief + For this weekend project, create a personal website which should contain some interesting info about you, what you are working on and what you would like to do in future. We would like to see clean and well structured HTML and CSS. Feel free to include any images and cool fonts from Google Fonts. Avoid using external frameworks and libraries. Focus on practicing your HTML and CSS skills. @@ -11,30 +13,3 @@ We would like to see clean and well structured HTML and CSS. Feel free to includ Add links to any public social media accounts such as Twitter, LinkedIn or your blog. Avoid including Facebook or any other social media is overly personal. Create the site using 'mobile first' that is create a single column layout that looks great on mobile and then using media queries add layouts for larger screen sizes. - -Neat resources you can use to create a great looking website include -- [CSS colours](https://www.quackit.com/css/css_color_codes.cfm) contains names of colours available in CSS -- [Coolors](http://coolors.co/) is a great palette generate website -- [Unsplash](https://unsplash.com/) has lots of great imagery you can use -- [Google Fonts](https://fonts.google.com/) provides plenty of free fonts you can use to enhance your website - -Some great personal websites we like include - -- [http://tjholowaychuk.com/](http://tjholowaychuk.com/) -- [http://mattfarley.ca/](http://mattfarley.ca/) -- [http://timroussilhe.com/](http://timroussilhe.com/) -- [http://www.adamhartwig.co.uk/](http://www.adamhartwig.co.uk/) -- [http://www.garysheng.com/](http://www.garysheng.com/) -- [https://roybarber.com/](https://roybarber.com/) -- [https://www.alexlakas.com/](https://www.alexlakas.com/) -- [https://www.devonstank.com/](https://www.devonstank.com/) -- [http://www.ryanmiglavs.com/](http://www.ryanmiglavs.com/) -- [http://tdr.io/](http://tdr.io/) - -Don't worry too much about getting same level of visual polish. You will have plenty of time to enhance an improve your site over the next few months, as well as add your projects. - -## Instructions - -1. Fork and clone this repo -2. Commit frequently while working -3. Once ready push your changes and create a `Pull Request`. This will allow us to review your code and progress. diff --git a/assets/.DS_Store b/assets/.DS_Store new file mode 100644 index 0000000..5008ddf Binary files /dev/null and b/assets/.DS_Store differ diff --git a/assets/elevenplustwo.png b/assets/elevenplustwo.png new file mode 100644 index 0000000..881c10b Binary files /dev/null and b/assets/elevenplustwo.png differ diff --git a/assets/joe.jpg b/assets/joe.jpg new file mode 100644 index 0000000..4896938 Binary files /dev/null and b/assets/joe.jpg differ diff --git a/assets/placeholder.jpg b/assets/placeholder.jpg new file mode 100644 index 0000000..feb6bb5 Binary files /dev/null and b/assets/placeholder.jpg differ diff --git a/index.html b/index.html new file mode 100644 index 0000000..911f95b --- /dev/null +++ b/index.html @@ -0,0 +1,135 @@ + + + + + + + + Joe Lamb - 1/12 Stack Javascript Developer + + + + + + + + + + +
+
+
+ +

+ My working life has been pretty varied – careering from one thing to another. + Take a look at my LinkedIn profile + for the full story. +

+

+ But I believe code can help make the world a happier, fairer place. So, I’m learning how to do that + at + Constructor + Labs. +

+
+
+ + +
+
+

Skills

+
+

Code

+
    +
  • HTML
  • +
  • CSS
  • +
  • JavaScript
  • +
+
+ +
+

Content

+
    +
  • Strategy
  • +
  • Marketing
  • +
  • Brand Voice
  • +
+
+
+
+ + +
+
+
+

Portfolio

+ +
+
+
+ Visit site + +
+
+

Coming soon

+
+
+

Coming soon

+
+
+

Coming soon

+
+
+

Coming soon

+
+
+

Coming soon

+
+
+
+
+ + +
+
+

About

+

When I’m not writing, debugging and pushing code to + Github, I enjoy cycling and you can follow me, literally, on + Strava (you can also see my series of abandoned shopping + trolley photographs there).

+

My other passion is music. I play with The Crooks Saxophone Quartet and we've got a + few tunes up on + Soundcloud. + I was also a member of The Sons of Silence (the band not the motorbike gang) and + you + can listen on + Spotify.

+

Oh, and I used to be called Joe Gardiner, but took my wife’s surname, Lamb, in the summer of 2018.

+
+
+ +
+ + + + + \ No newline at end of file diff --git a/main.js b/main.js new file mode 100644 index 0000000..325a27c --- /dev/null +++ b/main.js @@ -0,0 +1,37 @@ +// get elements +const contact = document.getElementById('contact'); +const content = document.getElementById('content'); +const header = document.getElementById('header'); +const nav = document.getElementById('nav--main'); +const sectionHeaders = Array.from( + document.getElementsByClassName('section-header') +); + +// set scroll offset for mobile (based on height of title and stapline) +const offset = 53; + +// define scroll function +const scrollFunction = () => { + // Add sticky class to header & nav and offset content + if (window.innerWidth > 767) { + header.style.position = 'fixed'; + nav.style.position = 'fixed'; + content.style.marginTop = '210px'; + if (window.innerWidth > 960) { + content.style.marginTop = '140px'; + } + } else { + // Add sticky class to the contact button when page top reaches offset position. + if (window.pageYOffset > offset) { + contact.classList.add('sticky'); + content.style.marginTop = '64px'; + } else { + // Remove sticky class when page top leaves offset position. + contact.classList.remove('sticky'); + content.style.marginTop = 0; + } + } +}; + +// call scroll function on scroll event +window.addEventListener('scroll', scrollFunction); diff --git a/normalize.css b/normalize.css new file mode 100644 index 0000000..47b010e --- /dev/null +++ b/normalize.css @@ -0,0 +1,341 @@ +/*! normalize.css v8.0.0 | MIT License | github.com/necolas/normalize.css */ + +/* Document + ========================================================================== */ + +/** + * 1. Correct the line height in all browsers. + * 2. Prevent adjustments of font size after orientation changes in iOS. + */ + +html { + line-height: 1.15; /* 1 */ + -webkit-text-size-adjust: 100%; /* 2 */ +} + +/* Sections + ========================================================================== */ + +/** + * Remove the margin in all browsers. + */ + +body { + margin: 0; +} + +/** + * Correct the font size and margin on `h1` elements within `section` and + * `article` contexts in Chrome, Firefox, and Safari. + */ + +h1 { + font-size: 2em; + margin: 0.67em 0; +} + +/* Grouping content + ========================================================================== */ + +/** + * 1. Add the correct box sizing in Firefox. + * 2. Show the overflow in Edge and IE. + */ + +hr { + box-sizing: content-box; /* 1 */ + height: 0; /* 1 */ + overflow: visible; /* 2 */ +} + +/** + * 1. Correct the inheritance and scaling of font size in all browsers. + * 2. Correct the odd `em` font sizing in all browsers. + */ + +pre { + font-family: monospace, monospace; /* 1 */ + font-size: 1em; /* 2 */ +} + +/* Text-level semantics + ========================================================================== */ + +/** + * Remove the gray background on active links in IE 10. + */ + +a { + background-color: transparent; +} + +/** + * 1. Remove the bottom border in Chrome 57- + * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari. + */ + +abbr[title] { + border-bottom: none; /* 1 */ + text-decoration: underline; /* 2 */ + text-decoration: underline dotted; /* 2 */ +} + +/** + * Add the correct font weight in Chrome, Edge, and Safari. + */ + +b, +strong { + font-weight: bolder; +} + +/** + * 1. Correct the inheritance and scaling of font size in all browsers. + * 2. Correct the odd `em` font sizing in all browsers. + */ + +code, +kbd, +samp { + font-family: monospace, monospace; /* 1 */ + font-size: 1em; /* 2 */ +} + +/** + * Add the correct font size in all browsers. + */ + +small { + font-size: 80%; +} + +/** + * Prevent `sub` and `sup` elements from affecting the line height in + * all browsers. + */ + +sub, +sup { + font-size: 75%; + line-height: 0; + position: relative; + vertical-align: baseline; +} + +sub { + bottom: -0.25em; +} + +sup { + top: -0.5em; +} + +/* Embedded content + ========================================================================== */ + +/** + * Remove the border on images inside links in IE 10. + */ + +img { + border-style: none; +} + +/* Forms + ========================================================================== */ + +/** + * 1. Change the font styles in all browsers. + * 2. Remove the margin in Firefox and Safari. + */ + +button, +input, +optgroup, +select, +textarea { + font-family: inherit; /* 1 */ + font-size: 100%; /* 1 */ + line-height: 1.15; /* 1 */ + margin: 0; /* 2 */ +} + +/** + * Show the overflow in IE. + * 1. Show the overflow in Edge. + */ + +button, +input { /* 1 */ + overflow: visible; +} + +/** + * Remove the inheritance of text transform in Edge, Firefox, and IE. + * 1. Remove the inheritance of text transform in Firefox. + */ + +button, +select { /* 1 */ + text-transform: none; +} + +/** + * Correct the inability to style clickable types in iOS and Safari. + */ + +button, +[type="button"], +[type="reset"], +[type="submit"] { + -webkit-appearance: button; +} + +/** + * Remove the inner border and padding in Firefox. + */ + +button::-moz-focus-inner, +[type="button"]::-moz-focus-inner, +[type="reset"]::-moz-focus-inner, +[type="submit"]::-moz-focus-inner { + border-style: none; + padding: 0; +} + +/** + * Restore the focus styles unset by the previous rule. + */ + +button:-moz-focusring, +[type="button"]:-moz-focusring, +[type="reset"]:-moz-focusring, +[type="submit"]:-moz-focusring { + outline: 1px dotted ButtonText; +} + +/** + * Correct the padding in Firefox. + */ + +fieldset { + padding: 0.35em 0.75em 0.625em; +} + +/** + * 1. Correct the text wrapping in Edge and IE. + * 2. Correct the color inheritance from `fieldset` elements in IE. + * 3. Remove the padding so developers are not caught out when they zero out + * `fieldset` elements in all browsers. + */ + +legend { + box-sizing: border-box; /* 1 */ + color: inherit; /* 2 */ + display: table; /* 1 */ + max-width: 100%; /* 1 */ + padding: 0; /* 3 */ + white-space: normal; /* 1 */ +} + +/** + * Add the correct vertical alignment in Chrome, Firefox, and Opera. + */ + +progress { + vertical-align: baseline; +} + +/** + * Remove the default vertical scrollbar in IE 10+. + */ + +textarea { + overflow: auto; +} + +/** + * 1. Add the correct box sizing in IE 10. + * 2. Remove the padding in IE 10. + */ + +[type="checkbox"], +[type="radio"] { + box-sizing: border-box; /* 1 */ + padding: 0; /* 2 */ +} + +/** + * Correct the cursor style of increment and decrement buttons in Chrome. + */ + +[type="number"]::-webkit-inner-spin-button, +[type="number"]::-webkit-outer-spin-button { + height: auto; +} + +/** + * 1. Correct the odd appearance in Chrome and Safari. + * 2. Correct the outline style in Safari. + */ + +[type="search"] { + -webkit-appearance: textfield; /* 1 */ + outline-offset: -2px; /* 2 */ +} + +/** + * Remove the inner padding in Chrome and Safari on macOS. + */ + +[type="search"]::-webkit-search-decoration { + -webkit-appearance: none; +} + +/** + * 1. Correct the inability to style clickable types in iOS and Safari. + * 2. Change font properties to `inherit` in Safari. + */ + +::-webkit-file-upload-button { + -webkit-appearance: button; /* 1 */ + font: inherit; /* 2 */ +} + +/* Interactive + ========================================================================== */ + +/* + * Add the correct display in Edge, IE 10+, and Firefox. + */ + +details { + display: block; +} + +/* + * Add the correct display in all browsers. + */ + +summary { + display: list-item; +} + +/* Misc + ========================================================================== */ + +/** + * Add the correct display in IE 10+. + */ + +template { + display: none; +} + +/** + * Add the correct display in IE 10. + */ + +[hidden] { + display: none; +} diff --git a/styles.css b/styles.css new file mode 100644 index 0000000..b71204f --- /dev/null +++ b/styles.css @@ -0,0 +1,666 @@ +/* variables */ + +:root { + --color1: rgba(169, 200, 205, 1); + --color2: rgba(138, 34, 43, 1); + --color3: rgba(171, 145, 128, 1); + --color4: rgba(226, 207, 172, 1); + --color5: rgba(240, 234, 212, 1); + + --text-color: rgb(44, 44, 44); + --shadow-color: rgba(0, 0, 0, 0.3); + + --logo-font: 'Montserrat', sans-serif; + --sans-font: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', + 'Lucida Sans Unicode', Geneva, Verdana, sans-serif; + + --stickyHeaderHeight: 68px; + --animationSlideOffset: -99em; +} + +/* +Styles +- global +- header +- navigation +- content + - sections +- footer +- media queries +- utility +*/ + +/*****************/ +/* global styles */ + +html { + padding-top: 0; +} + +body { + color: var(--text-color); +} + +/* typography */ + +h2, +h3 { + font-family: var(--sans-font); +} + +p { + line-height: 1.45; +} + +ul { + list-style-type: none; + margin: 0; + padding: 0; +} + +a { + text-decoration: none; + display: inline-block; + border-bottom: 1px solid var(--color2); + color: #2e4756; + font-weight: 700; +} + +/* utility classes */ + +.skill { + background: var(--color3); +} + +.portfolio { + background: var(--color5); +} + +.about { + background: var(--color4); +} + +.button { + background: orange; + border-top: 1px solid rgb(248, 200, 97); + padding: 0.25rem 1rem; + border: none; + border-radius: 1rem; + box-shadow: 0px 3px 5px var(--shadow-color); + color: white; + font-family: var(--sans-font); + text-shadow: 0 -1px 0 var(--shadow-color); +} +.button:hover { + background: green; +} + +.button--portfolio { + background: rgba(0, 0, 0, 0.5); + border-top: rgba(0, 0, 0, 0.4); +} + +.sticky { + position: fixed; + top: var(--stickyHeaderHeight); + width: 100%; + z-index: 20; +} + +.anchor { + display: block; + position: relative; + top: -162px; + visibility: hidden; +} + +/*****************/ +/* header styles */ + +header { + background: var(--color2); + text-align: center; + width: 100%; +} + +#title { + background: var(--color2); + margin: 0; + padding: 1rem 0; + position: fixed; + top: 0; + width: 100%; + z-index: 10; +} + +#title a { + color: rgba(255, 255, 255, 1); + font-family: var(--logo-font); + border-bottom: none; +} + +.strapline { + color: white; + font-size: 1rem; + font-weight: 100; + margin: 4rem 0 1.5rem 0; + padding: 0.5rem 0 0 0; +} + +.strapline .blur { + color: transparent; +} + +.strapline .fraction.blur--reverse { + color: white; + display: inline-block; + font-size: 1.2rem; + margin-left: -3rem; +} + +#contact { + background: var(--color2); + padding-bottom: 1rem; + width: 100%; +} + +.button--contact { + /* display: inline-block; */ + position: relative; + margin: 0 auto; +} + +/*********************/ +/* navigation styles */ + +.section-nav { + background: var(--color2); + display: none; + overflow: hidden; +} + +.section-nav ul { + display: flex; + justify-content: flex-start; + max-width: 960px; + margin: 0 auto; +} + +.section-nav ul li { + flex: 1; + font-family: var(--sans-font); + padding: 1rem 0; + text-align: center; +} + +.section-nav ul li a { + border-bottom: none; + height: 14px; + padding-bottom: 2px; +} +.section-nav ul li a:hover { + border-bottom: 2px solid var(--color2); +} + +/****************************/ +/* main content area styles */ + +#content { + display: flex; + flex-direction: column; + /* flex: 1; */ +} + +/******************/ +/* section styles */ + +/* general styles */ + +section { + box-shadow: 0 0 1rem var(--shadow-color); +} + +.section-wrapper { + display: flex; + flex-wrap: wrap; +} + +.section-header { + min-width: 100%; + text-align: center; +} + +h2.section-header { + font-family: var(--logo-font); +} + +.section--portfolio .section-header { + margin-bottom: 0; +} + +.section-header::before { + content: '⫱'; + display: inline-block; + padding-right: 1rem; + position: relative; + top: 0.5rem; + transform: rotate(90deg); +} + +.section-header::after { + content: '⫱'; + display: inline-block; + padding-left: 0.75rem; + position: relative; + top: 0.4rem; + transform: rotate(-90deg); +} + +/* biog */ + +section.biog.section--biog { + box-shadow: none; + padding: 0 1rem 1rem 1rem; +} + +.biog p { + font-size: 1.25rem; + font-style: italic; + margin-bottom: 0; +} + +.biog--photo { + display: none; +} + +/* skill */ + +.section--skill { + padding: 0 0.5rem; +} + +.section--skill .section-wrapper div { + flex: 1; + margin: 0 0.5rem; + padding-bottom: 1rem; +} + +.section--skill h3 { + border-top: 1px solid var(--text-color); + border-bottom: 1px solid var(--text-color); + margin-top: 0; + padding: 0.25rem 0; + text-transform: uppercase; + font-size: 1rem; +} + +.section--skill ul li { + font-family: var(--sans-font); + margin-bottom: 0.25rem; + font-size: 1rem; +} + +.section--skill ul li::before { + border-radius: 1rem; + content: '✓'; + color: white; + display: inline-block; + background: var(--color2); + margin-right: 0.5rem; + padding: 0.3rem 0.4rem 0.2rem 0.4rem; +} + +/* portfolio */ + +.section--portfolio { + padding-bottom: 1rem; +} + +.section--portfolio .section-wrapper { + justify-content: center; +} + +.section-wrapper--description { + min-width: 100%; + text-align: center; +} + +.portfolio--project { + background-position: center; + min-width: 275px; + min-height: 175px; + margin: 1rem; + display: flex; + flex-direction: column; + align-items: center; + justify-content: space-around; + overflow: hidden; +} + +.portfolio--project--coming { + background: black; + background-image: url(assets/placeholder.jpg); + background-size: cover; +} + +.portfolio--project--coming p { + font-family: var(--sans-font); + text-transform: uppercase; + font-weight: 700; + color: rgba(0, 0, 0, 0.3); +} + +.portfolio--project--elevenplustwo { + background-image: url(assets/elevenplustwo.png); + background-size: cover; +} + +/*********/ +/* about */ + +.section--about { + padding: 0 1rem; +} + +.section--about p { + margin-top: 0; +} + +/*****************/ +/* footer styles */ +footer { + background: var(--color2); + color: white; + font-family: var(--sans-font); + padding: 0.5rem 0; + text-align: center; +} + +/*****************/ +/* media queries */ + +/* iPad / tablet */ + +@media (min-width: 768px) { + body { + /* make page full height in browser */ + display: flex; + flex-direction: column; + min-height: 100vh; + } + + header { + /* position: fixed; */ + width: 100%; + } + + .section-nav { + /* position: fixed; */ + top: 165px; + width: 100%; + } + + .strapline { + font-size: 1.5rem; + } + + .section-nav { + display: block; + } + + #content { + flex-grow: 1; + } + + section { + flex: 3; + } + + .section-wrapper--description { + max-width: 25%; + } + .section-header { + min-width: 25%; + text-align: left; + } + + .section-header::before, + .section-header::after { + display: none; + } + + section .section-wrapper { + max-width: 960px; + margin: auto; + padding: 0 2rem; + flex-wrap: nowrap; + } + + .section--biog { + flex: 1; + padding: 1rem 0; + } + + .section--biog .section-wrapper { + display: block; + padding-bottom: 2rem; + } + + .section--biog p { + font-size: 1.4rem; + margin-bottom: 0; + line-height: 1.2; + width: 100%; + } + + .biog p:first-child:first-letter { + color: white; + font-family: var(--sans-font); + font-style: normal; + font-weight: 900; + background: black; + font-size: 3rem; + line-height: 2.75rem; + margin-right: 0.5rem; + padding: 0.25rem 0.75rem; + float: left; + } + + .section--portfolio--projects { + display: flex; + flex-wrap: wrap; + } + + .section-wrapper--description { + min-width: 25%; + text-align: left; + } + + .portfolio--project { + min-width: 230px; + min-height: 160px; + } + + .section--skill .section-wrapper div { + margin-top: 1rem; + } + + .section--about .section-wrapper { + align-items: flex-start; + } + + .section--about p { + margin: 1rem 1rem; + flex: 1; + } + + .section--skill h3 { + border-top: none; + text-align: left; + } +} +/* desktop */ + +@media (min-width: 1012px) { + /* animations */ + + @keyframes slideInFromLeft { + to { + } + from { + margin-left: var(--animationSlideOffset); + } + } + + @keyframes blur { + to { + color: transparent; + text-shadow: 0 0 15px rgba(255, 255, 255, 0); + } + from { + } + } + + @keyframes blur--reverse { + to { + color: white; + } + from { + color: transparent; + text-shadow: 0 0 15px rgba(255, 255, 255, 0); + } + } + + @keyframes slideInFromBottom { + to { + margin-bottom: 0; + padding-top: 0; + } + from { + margin-bottom: var(--animationSlideOffset); + padding-top: var(--animationSlideOffset); + } + } + + /* slide in header elements */ + #title { + animation-name: slideInFromLeft; + animation-duration: 1s; + animation-fill-mode: forwards; + } + + /* slide in nav */ + .section-nav ul { + margin-bottom: var(--animationSlideOffset); + padding-top: var(--animationSlideOffset); + animation-name: slideInFromBottom; + animation-duration: 2s; + animation-fill-mode: forwards; + } + + .header-wrapper { + display: flex; + justify-content: center; + align-items: baseline; + max-width: 960px; + margin: 0 auto; + } + + #title { + position: relative; + flex: 2; + } + + h1 { + font-size: 2.5rem; + } + + .strapline { + flex: 3; + margin: 2.5rem 0; + text-align: left; + } + + .strapline .blur { + color: white; + } + .strapline .blur { + animation-name: blur; + animation-delay: 1s; + animation-duration: 1s; + animation-fill-mode: forwards; + } + + .strapline .fraction.blur--reverse { + color: transparent; + font-size: 1.5rem; + } + + .strapline .fraction.blur--reverse { + animation-name: blur--reverse; + animation-delay: 1.5s; + animation-duration: 1s; + animation-fill-mode: forwards; + } + + .section-nav { + top: 115px; + } + + #contact { + flex: 1; + } + + .biog--photo { + border-radius: 150px; + display: block; + float: left; + margin: 1rem 2rem 1rem 0; + width: 25%; + } + + .section--biog .section-wrapper p:first-of-type { + margin-top: 1.5rem; + padding-top: 3.5rem; + } + + .section-header { + padding-top: 2rem; + text-orientation: mixed; + writing-mode: vertical-lr; + } + + .portfolio--project { + min-width: 205px; + min-height: 205px; + transition: all, 0.5s; + } + .portfolio--project:hover { + transition: all, 0.5s; + transform: scale(1.05); + transform: translate(0, 2%); + box-shadow: 0 6px 10px rgba(0, 0, 0, 0.4); + } +} + +/***********/ +/* utility */ + +.desktop-only { + display: none; +} + +.ipad-only { + display: none; +} +@media (min-width: 768px) { + .ipad-only { + display: flex; + } +} + +@media (min-width: 960px) { + .desktop-only { + display: flex; + } +}