Julia Miocene

On animating and drawing with pure CSS.

Week seven | March 18th, 2024 | sell CSS sell Code samples

Julia Miocene is a product designer and pure CSS animator based in Amsterdam. Her work as a pure CSS animator is what she came to our classroom for on March 18th, 2024. We were in the process of finishing up our course CSS to the Rescue, in which we were challenged to create interactive apps using absolutely no JavaScript, and as a pioneer in the CSS world, Julia was the perfect person to come and inspire us.

Just CSS?

Let's admit it: animating with just CSS is kind of insane. At least, that's what my mind was saying right before Julia took the stage and showcased her projects. She has imitated videogames, created detailed animated scenes and designed her own characters, each of them livelier than the one before.

She couldn't help but notice our awestruck expressions, and was of course armed with an explanation and brief break-down of what she made, exactly.

One thing that really stood out to me in her explanations was the fact that generally, she makes use of concepts that I'm already familiar with. A character's body, she explained, is really just a div inside of a div inside of a div. The head is a div, then inside of the head the eyes are div's, and inside of the eyes the pupils are divs as well. Additionally, Julia uses absolute positioning to 'draw' each of these elements exactly where they are supposed to be, relative to their parents. When she explained it like this, something admittedly clicked in my head.

<!-- HEAD -->
<div>
    <div> <!-- EYES -->
        <div> <!-- EYE 1 -->
            <div></div> <!-- PUPIL-->
        </div>
        <div> <!-- EYE 2 -->
            <div></div> <!-- PUPIL -->
        </div>
    </div>

    <div></div> <!-- NOSE -->
    ...
<div>

Additionally, Julia clarified that we could also make use of CSS's features like ::before and ::after, gradients, and transform-origin.

Transform-origin

Transform-origin allows you to specify where an element should "transform from" in CSS. Coincidentally, at the time of this talk, I had just used this for the first time in my assignment for CSS to the Rescue. I had a pin needle (a long, vertical element) that was meant to turn to the left and right from a fixed spot, but when I used the plain old rotate, the entire element would spin around. Transform-origin allowed me to say,

div {
    transform-origin: bottom center;
}

which meant that when it rotated, the bottom of the pin needle would stay fixed, and the top would transform, kind of like a windshield wiper.

When animating

Julia spoke of transform-origin like a joint. In the same way that my pin needle wiped from a fixed spot, it could be used to make arms move from shoulders and hands from wrists. This might scare you a bit, but you really don't need an extensive understanding of the human body. All you have to do is define where these elements should transform from.

Conclusion

I humbly admit that I spent the most of this talk with my eyes glued to the screen, so these notes (recollected from my memory) are all I have to offer. I think that what this all comes down to, is that the possibilities of CSS are limitless - which doesn't necessarily mean that I have a limitless amount of things yet to learn. In fact, Julia challenges us to rediscover that what we already know (or, think we know) and create new things with them.

My use, opinions and ideas

  • How likely to use in the future: Likely
  • Impact on current projects: Small impact
  • Inspiration level: Very inspired

Opinions

Animating and drawing in itself is already quite a feat, so the fact that Julia casually does so with nothing but code knocked my socks off, to put it lightly. As she explained, everything made sense, but there still needs to be an incredible understanding and intuition present to logically be able to build visual things with nothing but text. A website and the placement of and seamless collaboration between each of your elements is one thing, let alone make something artistic like Julia does! I'm extremely impressed and was hooked throughout the entirety of her talk.

Integration

I believe that it will take me years to get to Julia's level, but I am very inspired to pursue my own creative visions. If there's anything her art has taught me, it's that nothing is impossible. It might just be hard, or require some serious time investment. I'm very curious to see what I can do myself after this talk and might try it out soon!

Blogs you'll like

Did you like this blog about Julia Miocene's guest lecture? Then you'll love these!

2024-06-05

Bramus

On view transitions for single-page applications.

CSS JavaScript

north_east
2024-03-13

Jeremy Keith

On declarative and imperative design and programming.

CSS HTML JavaScript

north_east
2024-02-07

Kilian Valkhof

On the (near) future of code capabilities in HTML and CSS.

CSS HTML Code samples

north_east
View all blogs