Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,25 +7,25 @@ export default function App() {
🐨 We need to wrap our entire markup inside two container divs.

The first one is the full-page container. It needs to:
- have at minimum the full screen height (min-h-screen)
- have at minimum the full screen height (min-h-screen)
- centers its children with a grid (grid place-items-center)
- handle horizontal and verticall padding (see Figma)
- handle horizontal and vertical padding (see Figma)
*/}

{/*
🐨 Inside of that, wrap the entire markup in another 'div'.
🐨 Inside of that, wrap the entire markup in another 'div'.
This is our layout container, a common parent to both
the logo list and the text content.
the logo list and the text content.

It needs to:
- be a grid (grid) that contains two children (cells)
- have a gap (gap-12)
- center its children (place-items-center)
*/}

{/*
{/*
🐨 Wrap the Logo, h1 and paragraph in a common parent 'div'.
It will become one of the two grid cells in our layout.
It will become one of the two grid cells in our layout.
*/}
<EpicStackLogo className="size-20" />
<h1>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function App() {
🐨
Set a max-width of 'md' on the wrapping div below.
Center the elements horizontally:
- Setup a veritcal flexbox container with 'flex flex-col'
- Setup a vertical flexbox container with 'flex flex-col'
- Align the items horizontally with 'items-center'
- Center the children text elements with 'text-center'
*/}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@

Whew! That was actually pretty easy 😁

🦉 **Warning**: One thing to keep in mind is that when you start placing items manually in your grid like that, any element that _does not_ have a `grid-colum-start` or `grid-row-start` property will find the first available cell in the flow of the grid, and occupy that!
🦉 **Warning**: One thing to keep in mind is that when you start placing items manually in your grid like that, any element that _does not_ have a `grid-column-start` or `grid-row-start` property will find the first available cell in the flow of the grid, and occupy that!
22 changes: 11 additions & 11 deletions exercises/06.animation/03.problem.roll-reveal/tailwind.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import easings from 'open-props/src/easing'
import { type Config } from 'tailwindcss'

/*
🧝‍♀️ I've added the 'open-props' npm package and
🧝‍♀️ I've added the 'open-props' npm package and
imported a series of easing timing functions.

You can use one of these to fine-tune the "roll-reveal" animation below!
*/

Expand All @@ -27,7 +27,7 @@ export default {
'5.5xl': ['3.375rem', '1'],
},
keyframes: {
/*
/*
🐨 1. Create a 'roll-reveal' keyframe object.

It should start with...
Expand All @@ -43,10 +43,10 @@ export default {

/*
👨‍💼 We want to respect the user's system preferences for reduced motion,
so let's also create an "alternative", simpler reveal.
so let's also create an "alternative", simpler reveal.

🐨 2. Create a 'fade-in' keyframes definition.

🐨 2. Create a 'fade-in' keyframes definition.

It should start at 0% opacity and end at 100% opacity.
*/
'slide-left': {
Expand All @@ -59,17 +59,17 @@ export default {
},
},
animation: {
/*
/*
🐨 1. Add a 'roll-reveal' animation. It should use the 'roll-reveal' keyframe
you just created, and animate once over 0.4 seconds.

Try your own easigns (https://cubic-bezier.com is a great resource ✨),
or have fun playing with Open Props' easing function we've imported!
Try your own easings (https://cubic-bezier.com is a great resource ✨),
or have fun playing with Open Props' easing function we've imported!

In the solution, we use the `--ease-spring-2` easing function.
*/

/*
/*
🐨 2. Add a 'fade-in' animation. It should use the 'fade-in' keyframe
you just created, and animate once over 0.4 seconds.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,14 @@ export default function App() {
guide file for how to get your project off the ground!
</p>
</div>
{/*
{/*
🐨 At the `xl` breakpoint...

1. Defer the grid rows to the parent grid with `subgrid`
2. Span the grid across 6 rows

💰 You can define grid-template-rows as a `subgrid` with `grid-rows-subgrid`
💰 You can span an element acorss multiple rows with the `row-span-*` utilities
💰 You can span an element across multiple rows with the `row-span-*` utilities
*/}
<ul className="flex max-w-3xl flex-wrap justify-center gap-2 sm:gap-4 xl:grid xl:grid-flow-col xl:grid-cols-5 xl:grid-rows-6">
{logos.map((logo, i) => (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ The Vite plugin version of Tailwind CSS v4 is _not_ a PostCSS plugin. We've also

Currently, the <InlineFile file='src/styles/tailwind.css' /> uses `@tailwind` PostCSS directives.

BUT — we're not using PostCSS anymore! Instead, we're going to use a regular CSS import, and import the Tailwind CSS syles like so:
BUT — we're not using PostCSS anymore! Instead, we're going to use a regular CSS import, and import the Tailwind CSS styles like so:

```css filename=src/styles/tailwind.css
@import 'tailwindcss';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ The `--line-height` appended to the `woof` font size variable will compose that

## Working around the `.` character in variable names

👨‍💼 Whoops — we've named our custom font sizes `4.5xl` and `5.5xl`, but I'm told that a period (`.`) is not a valid characted for a CSS variable name.
👨‍💼 Whoops — we've named our custom font sizes `4.5xl` and `5.5xl`, but I'm told that a period (`.`) is not a valid character for a CSS variable name.

👨‍💼 In other words, `--font-size-4.5xl` won't work.

Expand Down