Skip to content
This repository has been archived by the owner on May 19, 2023. It is now read-only.

Commit

Permalink
Added folder icon and minor changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Simba-97 committed Sep 7, 2022
1 parent bc893e7 commit cd3a78c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 34 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,39 +82,7 @@ fun NoteFolderScreen(
folderType = NoteFolder,
createdOn = Instant.now(),
updatedOn = Instant.now()
),
Folder(
folderId = 12350,
title = "Android5",
description = "Android Notes",
folderType = NoteFolder,
createdOn = Instant.now(),
updatedOn = Instant.now()
),
Folder(
folderId = 12351,
title = "Android6",
description = "Android Notes",
folderType = NoteFolder,
createdOn = Instant.now(),
updatedOn = Instant.now()
),
Folder(
folderId = 12352,
title = "Android7",
description = "Android Notes",
folderType = NoteFolder,
createdOn = Instant.now(),
updatedOn = Instant.now()
),
Folder(
folderId = 12352,
title = "Android8",
description = "Android Notes",
folderType = NoteFolder,
createdOn = Instant.now(),
updatedOn = Instant.now()
),
)
)
val state = rememberLazyGridState()
Surface {
Expand Down Expand Up @@ -194,6 +162,7 @@ fun NoteFolderItemUI(
modifier = modifier.fillMaxWidth(),
horizontalAlignment = Alignment.CenterHorizontally
) {
Icon(painterResource(id = R.drawable.ic_folder_filled), contentDescription = null)
Text(
text = "Item ${data.title}",
style = MaterialTheme.typography.bodyLarge,
Expand Down Expand Up @@ -266,13 +235,17 @@ private fun NoteFolderScreenPreview() {
modifier = Modifier.fillMaxWidth(),
horizontalAlignment = Alignment.CenterHorizontally
) {
Icon(
painterResource(id = R.drawable.ic_folder_filled),
contentDescription = null
)
Text(
text = "Item $noteFolderItems",
style = MaterialTheme.typography.bodyLarge,
fontWeight = FontWeight.Bold
)
Text(
text = "$noteFolderItems notes",
text = "$noteFolderItems item description",
style = MaterialTheme.typography.bodyMedium
)
}
Expand Down
5 changes: 5 additions & 0 deletions app/src/main/res/drawable/ic_folder_filled.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<vector android:height="24dp" android:tint="#000000"
android:viewportHeight="24" android:viewportWidth="24"
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:fillColor="@android:color/white" android:pathData="M10,4H4c-1.1,0 -1.99,0.9 -1.99,2L2,18c0,1.1 0.9,2 2,2h16c1.1,0 2,-0.9 2,-2V8c0,-1.1 -0.9,-2 -2,-2h-8l-2,-2z"/>
</vector>

0 comments on commit cd3a78c

Please sign in to comment.