Skip to main content

What Is Autolayout & Expanding Buttons In Figma?

Lesson 60 from: Figma UI UX Design Essentials

Daniel Walter Scott

What Is Autolayout & Expanding Buttons In Figma?

Lesson 60 from: Figma UI UX Design Essentials

Daniel Walter Scott

buy this class

$00

$00
Sale Ends Soon!

starting under

$13/month*

Unlock this classplus 2200+ more >

Lesson Info

60. What Is Autolayout & Expanding Buttons In Figma?

<b>In this lesson we will make fancy buttons! You will use autolayout and create expanding buttons in Figma.</b>

Lessons

Class Trailer
1

Introduction to Figma Essentials

02:53
2

Getting Started with Figma Training

03:06
3

What Is Figma For & Does It Do The Coding?

03:46
4

What's The Difference Between UI And UX In Figma

05:22
5

What We Are Making In This Figma Course

09:18
6

Class Project 01 - Create Your Own Brief

04:01
7

What is Lo Fi Wireframe vs High Fidelity in Figma?

02:34
8

Creating Our Design File & Introducing Frames In Figma

08:29
9

The Basics Of Type & Fonts In Figma

10:51
10

Rectangles, Circles, Buttons And Rounded Corners In Figma

06:50
11

How To Use Color In Figma

05:45
12

Strokes Plus Updating Color Defaults In Figma

09:28
13

Object Editing And How To Escape In Figma

01:47
14

Scale vs Selection Tool in Figma

02:39
15

Frames vs Groups in Figma

09:24
16

Class Project 02 - Wireframe

03:00
17

Where To Get Free Icons For Figma

09:10
18

Matching The Stroke Of Our Icons

05:16
19

How To Use Plugins In Figma For Icons

04:31
20

Class Project 03 - Icons

03:48
21

How to Use Pages in Figma

08:31
22

How to Prototype in Figma

10:46
23

Prototype Animation and Easing In Figma

10:53
24

Testing On Your Phone with Figma Mirror

05:40
25

Class Project 04 - Testing On Your Phone

03:51
26

What is Smart Animation & Delays in Figma?

08:44
27

Class Project 05 - My First Animation

02:01
28

Sharing & Commenting on a Figma File with Stakeholders

07:10
29

Sharing & Editing With Other Ux Designers In Figma

06:58
30

How I Get Inspiration For Ux Projects

06:39
31

How To Create A Mood Board In Figma

05:33
32

Class Project 06 - Moodboard

01:26
33

How to Work with Columns & Grids in Figma

13:54
34

Tips, Tricks, Preferences, and Weirdness in Figma

07:21
35

Color Inspiration & The Eyedropper In Figma

06:34
36

How To Create A Color Palette In Figma

09:02
37

How to Make Gradients in Figma

07:09
38

How to Create & Use Color Styles in Figma

08:01
39

Class Project 07 - Colors & Columns

04:00
40

Fonts on Desktop vs in Browser in Figma

01:30
41

What Fonts Can I Use? Plus Font Pairing In Figma

06:01
42

What Common Font Sizes Should I Choose In Web Design?

11:30
43

How to Make Character Styles in Figma

06:36
44

Lorem Ipsum & Placeholder Text In Figma

04:28
45

Useful Things To Know About Text In Figma

09:35
46

How To Fix Missing Fonts In Figma

02:42
47

Class Project 08 - Text

05:19
48

Drawing Tips And Tricks In Figma

09:38
49

Squircle Buttons with ios Rounded Courses In Figma

02:48
50

Boolean, Union, Subtract, Intersect and Exclude with Pathfinder in Figma

07:25
51

What Is The Difference? Union vs Flatten In Figma

03:36
52

Class Project 09 - Making Stuff

03:29
53

Smart Selection & Tidy Up in Figma

08:40
54

Do I Need To Know Illustrator With Figma?

04:15
55

Tips & Tricks For Using Images In Figma

06:11
56

Masking & Cropping Images In Figma

09:12
57

Free Images & Plugins For Figma

02:31
58

Do You Need Photoshop For Ux Design In Figma?

10:40
59

Class Project 10 - Images

01:17
60

What Is Autolayout & Expanding Buttons In Figma?

10:27
61

Class Project 11 - Buttons

01:15
62

Auto Layout For Spacing

05:47
63

How To Use Constraints In Figma

08:22
64

Combining Nested Frames Auto Layout & Constraints in Figma

11:54
65

Adding Text Box Autoheight to Autolayout in Figma

08:27
66

Class Project 12 - Responsive Design

02:19
67

Nice Drop Shadow & Inner Drop Shadow Effects In Figma

05:56
68

Blur Layer, Background Blur & Image Blur in Figma

05:57
69

How to Make Neumorphic UI buttons in Figma

07:37
70

Class Project 13 - Effects

01:53
71

How To Save Locally & Save History In Figma

05:42
72

What are Components in Figma?

06:19
73

Updating, Changing & Resetting Your Components

07:47
74

You Can’t Kill Main Components In Figma

07:22
75

Where Should You Keep Your Main Components In Figma

05:02
76

Intro To The Forward Slash / Naming Convention In Figma

08:55
77

Class Project 14 - Components

00:44
78

How To Make Component Variants In Figma

06:41
79

Another Way To Make Variables In Figma

06:14
80

How to Make a Multi Dimensional Variant in Figma

11:13
81

Class Project 15 - Variants

01:41
82

How To Make A Form Using Variants In Figma

12:52
83

Class Project 16 - Form

01:27
84

Putting It All Together In A Desktop Example

19:44
85

How To Add A Popup Overlay Modal In Figma

03:03
86

How To Make & Prototype A Tool Tip In Figma

07:26
87

What are Flows in Figma?

05:39
88

Slide In Mobile Nav Menu Overlay In Figma

03:55
89

Class Project 17 - Prototyping

01:10
90

How To Pin Navigation To The Top In Figma

10:17
91

How To Make A Horizontal Scrolling Swipe In Figma

06:36
92

Automatic Scroll Down The Page To Anchor Point In Figma

04:50
93

What are Teams vs Projects vs Files in Figma?

05:18
94

How Do You Use Team Libraries In Figma

11:03
95

The Difference Between Animation & Micro Interactions

02:55
96

Animation With Custom Easing In Figma

25:36
97

Class Project 18 - My Second Animation

01:54
98

How To Make Animated Transitions In Figma

12:34
99

Class Project 19 - Page Transition

01:31
100

Micro Interactions Using Interactive Components In Figma

05:54
101

Micro Interaction Toggle Switch In Figma

04:23
102

Micro Interaction Burger Menu Turned Into A Cross In Figma

04:23
103

Class Project 20 - Micro Interaction

01:35
104

How To Change The Thumbnail For Figma Files

04:10
105

How To Export Images Out Of Figma

07:40
106

How To Share Your Document With Clients & Stakeholders

07:09
107

Talking To Your Developer Early In The Figma Design Process

03:55
108

Sharing Figma With Developers & Engineers Handoff

06:07
109

What Are The Next Level Handoffs Aka Design Systems

03:18
110

Class Project 21 - Finish your design

04:57
111

What Next?

06:08

Lesson Info

What Is Autolayout & Expanding Buttons In Figma?

Hi, everyone in this video we're gonna make buttons. You're like we already made buttons. There they are there. Ah, we're gonna make fancy buttons ready? Hey, look how fancy that is. Ok. We're gonna look at something called auto layout. Ok. And it's gonna expand. Look at that gets bigger and smaller. So we're going to do another one that stretches. Ok. It's different. Ok. Uses the same sort of principles, but instead of expanding, we expand the parent outside part and this guy sticks in the middle and that's for no reason other than danger, it's basically another one of these. All right, let's go make some expanding buttons and I'll explain why I'm wearing that shirt that says, hug me. All right. It'll all become clear. Ok? To get started with our, um, stretchy button. Ok. We're going to start with the mechanics of a button. So background rectangle with a bit of texts on top shift to zoom out one. Ok. So I've just got text sitting on top of a rectangle. See them there. Nothing fancy go...

ing on. If I select both of them, we need to turn them into a frame. This is one of those special powers that I talked about earlier that frames have. So any way you want to commit it, convert it into a frame, I'm just right clicking it and saying frame selection. OK? So here we go, there's my frame. I'm going to give it a name just to be clear. OK. I'm going to call this one BT N and this is going to be my button medium. No, this is my small bun. OK? So keep an eye on that structure there. So the next thing you want to do, we've done frames before. It's kind of like grouping. The extra special thing is this auto layout, watch this click this button and now go in here and start typing, start typing. Woohoo. We've got a super stretchy button. OK? So that's what auto layout does. Now a couple of things to be mindful of let's uh change this to per per we're gonna use that button in a sec. OK? The thing that changed is auto layout. You don't have to notice. But can you see this changed that button that was in the background actually disappeared. Where did it go? So there's my um you know, there was that thing that said by now, but where did that little rectangle go? Basically, it got sucked up into the parent frame. And the other thing that happened. So it renamed it good work then button small. OK. The other thing that happened is the icon changed. This is a little pause button. Ok. There's an auto layout icon. So if you're copying and pasting from some other person's document, it's gonna have some magic built into it because it's an auto layout. So it doesn't really matter that the rectangle is gone because it's been smooshed into the sea here. This thing here is got the right color and there's no background layer anymore. Really? Alright. That doesn't really matter right? All you care about is that it's uh stretchy. Ok. So let's look at how to change things like the padding cos we had ours lined up nicely. You might not, you might go actually, I need to bring in the sides and push out the top. Ok. The way to do it though is it's a little strange you've got kind of two parts to this button. There's the child and parent, ok. The parent is the boss, he's on top, ok? And he controls everything inside of it, the child. Ok. The padding is actually controlled by the parent, ok. This parent uh frame here, which is also an auto layout frame. Ok. So you can start to see things over here. Nope. Well, they actually hide it. It's this thing here, alignment and padding. I don't know why it's so small in there. It's quite important. I know when I first started it was kind of tricky to find. So you click the parent, click on this thing and there's the padding. Ok. I'm going to say actually I want it to be eight for the top and bottom. I'm just tapping around and for the sides. I'm going to do 24 either side. All right. That's my kind of sizing. Gonna go to capitals and I'm gonna go back to that purchase. Now, one thing that might not be working if you are having problems with it, that initial, I'm going to copy paste that thing. So this is the original one I started with. Let's change the color of it just because. So this is the one that I started with. If you start here and say actually I'm going to start with a text box that is a fixed size that causes problems because we know from earlier on if we have a fixed size button, it doesn't like where we go and doing. Yeah. So fixed size, it means that I'm going to type and it's gonna break onto other lines. It's breaking down here. It's white text. So if you do that first, that won't work the little stretchy thing. So you just need to make sure that you select all your text, OK? Or select it with the selection tool and say you are this one here. Remember the auto width means auto width just means I keep going. OK? And if you start with that, hey, let's run through it one more time you guys convert to frame, frame selection order layout. Yeah. Alright. So that is that one. So that's the first type of button. This one will automatically get bigger and smaller. I use this one quite a lot. It's the main one that you'll use expanding buttons. The one that you'll use less is that stretchy button we saw at the beginning. So I'm gonna make another one so I'm just going back to like text with uh background rectangle. Ok. We'll change this to the cool. Huh? And let's change the color. So we know what we're doing. There's the rectangle. There it is. You're gonna be that color. So you get started the same way you select both of them. You say you are a frame frame, the selection and you say you're an auto layout. The differences here is to do with the constraints and resizing. OK? By default, it wants to hug contents. Remember that gag? You've seen the t-shirt? OK. And if you're wondering why he was wearing hug contents, dad t-shirt? It is a dad joke, but it's a UX dad joke. OK. So by default, what it wants to do is hug the contents. OK? The parent on the outside wants to hug this inside stuff as close as it can. But listening to the padding, that doesn't make sense. Let's look at his nemesis. OK? So let's look at the we're going to rename this one. Let's call this one button two and we've got, remember our parent and our child. So the child on the inside is how this one works. We say the child, what I'd like you to do is not be hugged by the parent. You're too tight. Parent go away. What I want you to do is for the left and the right, this one, I want you to just to fill the container and you're like, huh? That's done nothing. So, what that means is Mr Parent? Ok, I'm gonna drag him out and look at that. He fills either side all the way to the edges there. That's his job now. So the child will fill it. So it depends on what kind of button you want. Leave it all by default, you get the expanding box. OK? And if you try and drag the side of it to make it bigger, let's grab the side of it even. OK? It doesn't do what you want. Well, it doesn't do what this one does. This one does that this one doesn't do the expanding thing, ok? If you wanted to get expand up and down, are you ready for this? We're going, we're going down another level. You ready a little bit inception? OK. I feel like I've given you too much but you're gonna go. Why isn't that going that way? We've done left and right. Do I just go in here instead of saying? So remember it's the stretchy buttons. You have to do it with the child. Here you go. OK. We say, stop hugging me, I'll fill the container and you go, OK, we'll just do it at the top and the bottom as well. You can say, ok, fill the container and then you go. It's still not works. It kind of working the text box in here. Let's have a look. If I be right back, the actual text box is actually filling the container. That's his job. Look, he's doing exactly what we told him to do. The problem is, is this text is aligned at the top so you can go over here and say uh the default is aligned up. You just say align center. So now we've got this kind of like stretchy thing. Um I show you this cos you're gonna get other people's buttons and you're gonna be not freaked out, but you're gonna be like this is amazing. Why didn't Dan show me how to do stretchy buttons as well? Basic one super easy, make it a frame, make it auto layout, adjust the padding as necessary. This one here make a frame, make auto layout, but then deal with the child and say fill container, please fill container and you might actually for the up and down have to adjust the text box itself to the center. Now we're going to go one step level down this inception wormhole. We're going to do one more. OK? I just because we have to, I'm going to change this. We're going to cut this calling, cutting to the chase. We're making a clumsy button. We're taking a long time to do it often. What I'll do is let's just actually pin that. Let's grab some text. Let's type it out. Let's call this our more button. Ok? You don't need to draw a rectangle in the background because we know that if you do, like if you do just take a rectangle first with text and you turn it into a frame and then you click auto layout. It turns, it gets rid of my rectangle already. So we can cut to the chase. Watch this, grab the text right, click it, frame selection, auto layout. We've still got that strange structure. There you go. OK without the box. But we can say you the frame here is give you a background color. Let's give him some round the corners and the padding. Where do they hide that padding? It's in there there it is. We can say actually give me eight top and bottom and 24 side by side. I don't know. How do you feel? Just draw the rectangle or turn your text into a frame start that way and just color it and style it. The chicken works. There's definitely a danger button red is danger. All right. That is it for auto layout. It is pretty amazing. It's one of the perks for frames and we are slowly learning what constraints are. There's more to constraints, but we've done the basics we looked at hugging because by default, at this initial first one, the contents gets hugged as tightly as it can while acknowledging your padding. And then we learned a stretchy one. And then tan told us how we didn't need a rectangle. Oh, have I made it easier or harder? Well, I don't know. That's what you're getting. I will see you in the next video.

Class Materials

Bonus Materials

BYOL_Figma_Cheatsheet.pdf
Exercise_Files_-_Figma_Essentials.zip

RELATED ARTICLES

RELATED ARTICLES