Where no one has gone before

A presentation at Smashing Conference Freiburg 2022 Jam Session in September 2022 in Freiburg, Germany by Gunnar Bittersmann

Slide 1

Slide 1

Where where no one has gone before

Slide 2

Slide 2

Slide 3

Slide 3

Slide 4

Slide 4

Slide 5

Slide 5

Slide 6

Slide 6

Slide 7

Slide 7

Slide 8

Slide 8

Slide 9

Slide 9

Slide 10

Slide 10

Slide 11

Slide 11

Slide 12

Slide 12

const resizeObserver = new ResizeObserver(entries => { document.documentElement.style.setProperty( ‘—header-height’, ${entries[0].target.offsetHeight}px ); });

resizeObserver.observe(document.querySelector(‘header’));

const intersectionObserver = new IntersectionObserver(entries => { document.body.classList.toggle( ‘scrolled’, entries[0].intersectionRatio == 0 ); }, { rootMargin: ‘36px’ });

intersectionObserver.observe(document.head);

Slide 13

Slide 13

head { display: block; }

head > * { display: none; }

Slide 14

Slide 14