diff --git a/assets/css/icon.css b/assets/css/icon.css new file mode 100644 index 0000000..f330b9c --- /dev/null +++ b/assets/css/icon.css @@ -0,0 +1,32 @@ +main { + display: grid; + + grid-template-columns: repeat( auto-fit, minmax(256px, 1fr) ); + overflow-x: hidden; + gap: 32px; +} + +/* @media screen and (min-width: ){ + +} */ + +Icon { + display: flex; + + padding: 32px; + text-align: end; + + justify-content: space-between; + align-items: center; + + outline: 1px solid black; +} + +Icon:hover { + cursor: pointer; +} + +Icon img { + width: 8rem; + height: 8rem; +} \ No newline at end of file diff --git a/assets/images/cashapp.png b/assets/images/cashapp.png new file mode 100644 index 0000000..088dafe Binary files /dev/null and b/assets/images/cashapp.png differ diff --git a/assets/images/discord.ico b/assets/images/discord.ico new file mode 100644 index 0000000..1a6733f Binary files /dev/null and b/assets/images/discord.ico differ diff --git a/assets/images/tiktok.jpg b/assets/images/tiktok.jpg new file mode 100644 index 0000000..f0c2853 Binary files /dev/null and b/assets/images/tiktok.jpg differ diff --git a/assets/images/tiktok.png b/assets/images/tiktok.png new file mode 100644 index 0000000..634020d Binary files /dev/null and b/assets/images/tiktok.png differ diff --git a/assets/js/icon.js b/assets/js/icon.js new file mode 100644 index 0000000..737121b --- /dev/null +++ b/assets/js/icon.js @@ -0,0 +1,35 @@ +const main = document.querySelector("main"); + +const icons = main.querySelectorAll("Icon"); + +icons.forEach((icon) => { + let iconImage = icon.getAttribute("image"); + let link = icon.getAttribute("href"); + let title = icon.getAttribute("title"); + + console.log(iconImage, link, title); + + if (iconImage) { + let imageElement = document.createElement("img"); + + imageElement.src = iconImage; + imageElement.height = 64; + imageElement.width = 64; + + icon.appendChild(imageElement); + } + + if (link) { + icon.addEventListener('click', (e) => { + window.open(link, "_blank"); + }); + } + + if (title) { + let titleElement = document.createElement("span"); + + titleElement.textContent = title; + icon.appendChild(titleElement); + } + +}); \ No newline at end of file diff --git a/links.html b/links.html index 0e12875..0a61ffc 100644 --- a/links.html +++ b/links.html @@ -5,12 +5,20 @@ Links are pretty cool - + + + +
- + + + + +
+ \ No newline at end of file diff --git a/projects.html b/projects.html index 1ee84b9..312730e 100644 --- a/projects.html +++ b/projects.html @@ -1,16 +1,21 @@ + Projects 'n' stuff - + + + +
- +
+ \ No newline at end of file