Skip to content

Commit

Permalink
Site redesign (#234)
Browse files Browse the repository at this point in the history
* Convert design to site

- converted home page - updated styles to match design files - updated Bootstrap library

* Update Explore button to go to the Design page

* Fix alignment on mobile and adjust spacing

* Fix image URLs breaking on nested pages

* Update Resume and Development pages

* Updates to Design, Prototypes, Development, and compression of images

* Fix overlap due to excess padding and margin

* Update About and Resume pages

* Finalize Contact page and update page header overflow

* Remove contact form

* Fix typography bug and update styling
  • Loading branch information
AdamJ authored Aug 23, 2023
1 parent 0155811 commit 6b41153
Show file tree
Hide file tree
Showing 97 changed files with 17,678 additions and 5,383 deletions.
49 changes: 21 additions & 28 deletions .eleventy.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,7 @@ const markdownItAnchor = require("markdown-it-anchor");
const packageVersion = require("./package.json").version;
const fs = require("fs");
const eleventyNavigationPlugin = require("@11ty/eleventy-navigation");
const Image = require("@11ty/eleventy-img");

(async () => {
let url = "https://images.unsplash.com/photo-1608178398319-48f814d0750c";
let stats = await Image(url, {
widths: ["auto"],
urlPath: "./src/img/",
outputDir: "./docs/img/"
});

console.log( stats );
})();
// const Image = require("@11ty/eleventy-img");

module.exports = function (eleventyConfig) {
eleventyConfig.addPlugin(syntaxHighlight);
Expand All @@ -27,6 +16,7 @@ module.exports = function (eleventyConfig) {

eleventyConfig.addWatchTarget("./src/sass/");

eleventyConfig.addPassthroughCopy("assets");
eleventyConfig.addPassthroughCopy("./src/keybase.txt");
eleventyConfig.addPassthroughCopy("./src/fonts");
eleventyConfig.addPassthroughCopy("./src/webfonts");
Expand All @@ -40,22 +30,25 @@ module.exports = function (eleventyConfig) {
eleventyConfig.addShortcode("year", () => `${new Date().getFullYear()}`);
eleventyConfig.addShortcode("packageVersion", () => `v${packageVersion}`);

eleventyConfig.addShortcode("image", async function(src, alt, sizes) {
let metadata = await Image(src, {
widths: ["auto"],
urlPath: "./src/img/",
outputDir: "./docs/img/"
});

let imageAttributes = {
alt,
sizes,
loading: "lazy",
decoding: "async",
};

return Image.generateHTML(metadata, imageAttributes);
});
// eleventyConfig.addShortcode("image", async function(src, alt, sizes) {
// if(alt === undefined) {
// // You bet we throw an error on missing alt (alt="" works okay)
// throw new Error(`Missing \`alt\` on myImage from: ${src}`);
// }

// let metadata = await Image(src, {
// widths: ["auto"],
// urlPath: "/src/img/",
// outputDir: "./docs/img/",
// formats: "png",
// loading: "lazy",
// decoding: "async",
// });

// let data = metadata.png[metadata.png.length - 1];
// return `<img src="${data.url}" width="${data.width}" height="${data.height}" alt="${alt}" loading="lazy" decoding="async">`;

// });

eleventyConfig.setBrowserSyncConfig({
callbacks: {
Expand Down
1 change: 0 additions & 1 deletion docs/CNAME

This file was deleted.

Loading

0 comments on commit 6b41153

Please sign in to comment.