‫Hello my friends.
‫In this video we will start designing the layouts for the fragments.
‫But first I will go to the activity underscore main and here for the fragment container view.
‫I will click on this infer constraints button and everything will work fine.
‫As we know, inside our nav graph, we've created three fragments the home fragment, new node fragment
‫and update node fragment.
‫So we'll start designing these three layouts.
‫This is the frame layout.
‫I will change it to constraintlayout and.
‫Remember we are working with the fragment underscore home XML.
‫This is the first fragment.
‫Okay.
‫I will start copying and pasting the codes one by one in order not to make the video lengthy and you
‫can pause the video or get the source code from the resources folder in the description below.
‫At first I will add a floating action button.
‫So this is our action button.
‫I will add this strings later on and these resources create namespace by pressing alt enter.
‫And here we've created the app namespace.
‫Now I will add the recycler view.
‫This is our recycler view.
‫Its ID is recycler view.
‫Also I will create a card view here in this card view will contain the the, the recycler, the text
‫view for displaying the notes.
‫Okay.
‫So I will create here a text view.
‫And now I will paste the.
‫Attributes for this text view.
‫Okay.
‫Don't miss the close.
‫The closing tag for this card review.
‫So here I will start with.
‫Android x Cardview Widget Card view.
‫Now let's add these resources.
‫So in order to create the background, you can go to color dash hex, dot com or any other website.
‫I can get these colors.
‫Choose one of them.
‫I prefer using.
‫This.
‫This color.
‫Maybe we will change it later on.
‫And here I will click on this red bulb, Create color source file.
‫Valley resource.
‫Here resource value.
‫You can see it, guys.
‫This is the color primary.
‫Its resource name is color primary, and this is the value.
‫Or you can simply go to the colors.
‫That and right by your own.
‫Okay.
‫This is the color primary.
‫The content description, I will change it directly to image.
‫You can change it to using the string resources and here the source compat I will add.
‫A new vector asset inside the drawable new.
‫Click on the drawable folder.
‫Click new.
‫Click on.
‫Vector asset.
‫You can change it from here.
‫Clip Art.
‫I would add, this is the.
‫Vector that I need.
‫I will name it as add and click next.
‫And here we go.
‫Click, finish, and everything will work fine if you can see that the.
‫Preview is enabled.
‫You can see the the floating action bar here with this color.
‫And this is the card view with recycler view here.
‫Okay, So congratulations, guys.
‫We've created our first.
‫For a fragment.