Meta: New website features

  • Posts with thumbnails.
  • Enlarging the thumbnail inside a post.
  • Basic deployment script.
  • New [WIP]s and plans.

This post informs of new things that I added to the website.

Thumbnails to posts

A couple of posts now have a thumbnail image! Also during the image load (I'm hotlinking btw.) I'm allocating UI space equal to the image size to make it not jump around after the image is loaded. I hate when the page shifts when something loads.

How did I achieve this seemingly impossible task?

I just added an <img/> tag with width="129" height="200" and I'm unsetting the with and height with javascript whenever I want to enlarge the image.

Enlarging the thumbnails = lightbox gallery at home

I thought about adding a proper Lightbox (Modal Image Gallery) that shows a nice big picture on fullscreen. It would have the background going dark and nice navigation arrows and keyboard shortcuts and stuff, but then I thought nah. That sounds like it requires design to make it look and work just right. Instead I just made a function that makes an image bigger when you click it.

Show code
function enlargeThumb(clickEvent){
    const target = clickEvent.target;
    target.src = target.src.replace("Thumb", "");
    target.style.maxHeight="900px";
    target.style.cursor="unset";
    target.style.width="unset";
    target.style.height="unset";
}

I realize the full image load may shift the UI with unexpected delay but I'm gonna fix that later.

I can now push changes with a CMD!

This website doesn't use any professional CMS, I just have an FTP server with PHP.

Before making a simple deployment script, I was... I was drag and dropping files to the server via WinSCP in window mode. Ok, I'm not proud of it.

New [WIP]s and plans and wishes

Other changes