Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
158 commits
Select commit Hold shift + click to select a range
4bc9bd7
- maps the JSON field shared_code to the Kotlin property sharedCode
Jiyu13 Jul 23, 2025
6988d20
- add colours
Jiyu13 Jul 23, 2025
3c32beb
- Create app top bar composable
Jiyu13 Jul 23, 2025
d227eab
- Create search bar composable
Jiyu13 Jul 23, 2025
1449a21
- add isLoading state
Jiyu13 Jul 23, 2025
fe499a3
- add top bar + search bar
Jiyu13 Jul 23, 2025
d2f7e6f
- ignore file
Jiyu13 Jul 23, 2025
c606fb7
- create User model
Jiyu13 Jul 24, 2025
df6e157
- add sharedWidth field
Jiyu13 Jul 24, 2025
c77faa7
- create composable to show info of each list
Jiyu13 Jul 24, 2025
b1347d4
- rename composable
Jiyu13 Jul 24, 2025
f9def51
- render ListRow
Jiyu13 Jul 24, 2025
8ff17e2
- add padding to list info column
Jiyu13 Jul 24, 2025
d183880
- check if input is empty
Jiyu13 Jul 24, 2025
51f611b
- filter lists by input
Jiyu13 Jul 24, 2025
6c5ee1e
- comment out reseting search text
Jiyu13 Jul 24, 2025
f631965
- create dialog
Jiyu13 Jul 24, 2025
f5a09b3
- pass in onAddButtonClick to handle showing dialog
Jiyu13 Jul 24, 2025
78d51d5
- show FormDialog when isDialogShown is true
Jiyu13 Jul 24, 2025
b11e00e
- create add list screen composable
Jiyu13 Jul 25, 2025
cf6430a
- add let text param
Jiyu13 Jul 25, 2025
ebaf7cd
- add route for ListifyNewListScreen
Jiyu13 Jul 25, 2025
cad53ac
- create input field for adding new list
Jiyu13 Jul 25, 2025
8710f2e
- rename function
Jiyu13 Jul 25, 2025
0527bd1
- add NewListScreen
Jiyu13 Jul 25, 2025
d0c9b94
- remove isDialogShown state + if statement
Jiyu13 Jul 25, 2025
192e5f4
- add BaseList + listName models
Jiyu13 Jul 30, 2025
6658056
- add onRightButtonClick()
Jiyu13 Jul 30, 2025
aa168e2
- add post request insertList() api
Jiyu13 Jul 30, 2025
35a307c
- commit out broken import
Jiyu13 Jul 30, 2025
dadbbe8
- create insertListByUser api call
Jiyu13 Jul 30, 2025
7c2420f
- implement list creation with state management
Jiyu13 Jul 31, 2025
1b94579
- add LaunchedEffect to observe navigation events
Jiyu13 Jul 31, 2025
632b002
Fix merge conflicts
Jiyu13 Jul 31, 2025
8e8d703
Fix merge conflicts
Jiyu13 Jul 31, 2025
0c14a4f
delete file
Jiyu13 Jul 31, 2025
0623055
delete file
Jiyu13 Jul 31, 2025
db1bd9f
- add sign in button
Jiyu13 Jul 31, 2025
396e824
- move button columns to a separate file
Jiyu13 Jul 31, 2025
d58d485
- uncomment ListifyLoginScreen
Jiyu13 Jul 31, 2025
30d5ab2
- rename file
Jiyu13 Jul 31, 2025
948cce8
- add material icons implementation
Jiyu13 Jul 31, 2025
03cd240
- add material icons implementation
Jiyu13 Jul 31, 2025
bceff1f
- create viewModel to manage email input + validation
Jiyu13 Jul 31, 2025
96bbfef
- display a email field with validation feedback
Jiyu13 Jul 31, 2025
fd82ce8
- change padding
Jiyu13 Aug 1, 2025
f1ccc43
- create password input field with toggle to show/hide password
Jiyu13 Aug 1, 2025
d2a0c16
- create login screen
Jiyu13 Aug 1, 2025
a598c68
- create reusable filled button
Jiyu13 Aug 1, 2025
b597ceb
- implement reusable filled button
Jiyu13 Aug 1, 2025
7d80569
- implement reusable filled button
Jiyu13 Aug 1, 2025
2918c71
- add Keyboard Configuration
Jiyu13 Aug 1, 2025
630c73c
- clean code
Jiyu13 Aug 1, 2025
ef3ec29
- add top padding
Jiyu13 Aug 1, 2025
198260f
- add top bar container color to SplashYellow
Jiyu13 Aug 1, 2025
84f1679
- import ListifyScreens
Jiyu13 Aug 1, 2025
6c8bd92
- add new list navigation
Jiyu13 Aug 6, 2025
ee31a3b
- add UserWithoutPassword model
Jiyu13 Aug 6, 2025
45176f5
- add models for login
Jiyu13 Aug 6, 2025
55c8571
- add login post request
Jiyu13 Aug 6, 2025
79e56a2
- refactor routes
Jiyu13 Aug 6, 2025
3c7d439
- refactor navigation graph + destinations
Jiyu13 Aug 6, 2025
520803b
- define a sealed class
Jiyu13 Aug 6, 2025
842f912
- define repository to make login request to api
Jiyu13 Aug 6, 2025
e6cd44b
- define login view model
Jiyu13 Aug 6, 2025
b1767be
- create global object to store current user
Jiyu13 Aug 6, 2025
68ec632
- set global object currentUser after fetching user successfully
Jiyu13 Aug 6, 2025
6060827
- install serializable plugin
Jiyu13 Aug 6, 2025
c37390b
- fix navigate route
Jiyu13 Aug 6, 2025
9d667d1
- refactor email + password validation and update
Jiyu13 Aug 6, 2025
ca0dfaa
- fix route for onRightButtonClick
Jiyu13 Aug 6, 2025
630b0d6
- install dataStore
Jiyu13 Aug 12, 2025
45a8fe8
create dataStorage
Jiyu13 Aug 12, 2025
b2dedb7
okHttp Interceptor + Authenticator
Jiyu13 Aug 12, 2025
f8f803c
add refresh token api
Jiyu13 Aug 12, 2025
2ab1c5a
define data models for auth flow
Jiyu13 Aug 13, 2025
6c1f890
Login repository
Jiyu13 Aug 13, 2025
d6c72f0
add LoginViewModel + token persistence
Jiyu13 Aug 13, 2025
8ed66d9
- remove .value when accessing mutable state
Jiyu13 Aug 13, 2025
8f005bc
- inject storageManager
Jiyu13 Aug 13, 2025
2dec3c6
- LaunchedEffect(Unit) to fetch user lists.
Jiyu13 Aug 13, 2025
3c63380
delete file
Jiyu13 Aug 13, 2025
0435166
- isLoggedIn() reads current isLogin
Jiyu13 Aug 13, 2025
6bdeac4
- check isLoggedIn state + call checkAccessToken() to ensure access t…
Jiyu13 Aug 13, 2025
e65929e
rename file + function
Jiyu13 Aug 13, 2025
a80699f
- rename api
Jiyu13 Aug 14, 2025
3d7064d
- define type-safe route with @Serializable
Jiyu13 Aug 14, 2025
a69a977
- extract args with backStateEntry
Jiyu13 Aug 14, 2025
126caae
- add on click callback for each list row
Jiyu13 Aug 14, 2025
45c1fa1
- create list item model data class
Jiyu13 Aug 14, 2025
ae9f464
- create repository
Jiyu13 Aug 14, 2025
1d5cd9e
- create view model
Jiyu13 Aug 14, 2025
69a0088
add on click callback
Jiyu13 Aug 14, 2025
61d350e
create util function to filter items by input
Jiyu13 Aug 14, 2025
c230048
commit
Jiyu13 Aug 14, 2025
1b9a708
Create screen
Jiyu13 Aug 14, 2025
e39528c
Create screen
Jiyu13 Aug 14, 2025
4edfedb
item row
Jiyu13 Aug 14, 2025
40c5f85
create view model
Jiyu13 Aug 14, 2025
279a6c3
show ListItemActionSheet if activeItemId is not null
Jiyu13 Aug 14, 2025
d5f31f2
- add haptic feedback (vibration)
Jiyu13 Aug 14, 2025
9742cd2
create ModalBottomSheet
Jiyu13 Aug 14, 2025
8cf7644
update item checked state
Jiyu13 Aug 15, 2025
fecace4
create callback to update checked state
Jiyu13 Aug 15, 2025
512b3e4
add data model, api, repository, view model for updating list item info
Jiyu13 Aug 15, 2025
e39fdcd
create form for editing list description + units
Jiyu13 Aug 15, 2025
6619df6
Implement updating item description + units
Jiyu13 Aug 15, 2025
95f5072
- refactor rows
Jiyu13 Aug 15, 2025
3a462f6
close edit form when row is clicked
Jiyu13 Aug 15, 2025
8e5ecd8
remove code related to ModalBottomSheet
Jiyu13 Aug 15, 2025
f60f850
create custom outlined button
Jiyu13 Aug 15, 2025
e34a866
implement custom outlined button
Jiyu13 Aug 15, 2025
dffaa0d
change broder color to red
Jiyu13 Aug 15, 2025
c8b66ad
handle deleting list item by calling the delete api
Jiyu13 Aug 16, 2025
667a263
create userId
Jiyu13 Aug 16, 2025
5648932
- get userid from viewModel
Jiyu13 Aug 16, 2025
3b03ebe
- call onGoBackButtonClicked
Jiyu13 Aug 16, 2025
d1eef44
commit
Jiyu13 Aug 16, 2025
471d405
restructure navigation
Jiyu13 Aug 16, 2025
024acb0
add resource string
Jiyu13 Aug 16, 2025
1b82cd5
call no_items resource string
Jiyu13 Aug 16, 2025
7c6c468
apply Material typography styles for all Text() at top bar
Jiyu13 Aug 16, 2025
8cdf137
apply Material typography styles to search bar text
Jiyu13 Aug 16, 2025
1646850
create component for showing text with custom style
Jiyu13 Aug 18, 2025
63185c4
- apply custom style for text
Jiyu13 Aug 18, 2025
a306101
- apply EmptyList compenent
Jiyu13 Aug 18, 2025
67979f7
commit
Jiyu13 Aug 18, 2025
71cc156
apply custom text style
Jiyu13 Aug 18, 2025
6fe57b4
remove unused code
Jiyu13 Aug 18, 2025
2675d62
create custom input label/placeholder text component
Jiyu13 Aug 18, 2025
aa9a243
commit
Jiyu13 Aug 18, 2025
ac2d7ae
apply custom text style
Jiyu13 Aug 18, 2025
31ff95e
add custom text styles
Jiyu13 Aug 18, 2025
f92b758
rename file
Jiyu13 Aug 18, 2025
db05937
organize files
Jiyu13 Aug 19, 2025
d1ff55a
add placeHolder as param
Jiyu13 Aug 19, 2025
19eb1c2
- add AddNewItemScreen
Jiyu13 Aug 19, 2025
3df7ee7
- organize code
Jiyu13 Aug 19, 2025
1ff4fff
- add onAddClick callback to navigate to AddNewItemScreen
Jiyu13 Aug 19, 2025
f7a1731
rename model
Jiyu13 Aug 19, 2025
186eba9
- replace text type to be just String type
Jiyu13 Aug 19, 2025
1579829
define AddNewItemScreen with listId as argument
Jiyu13 Aug 19, 2025
7d070a8
- defines a POST request using Retrofit to add a new item to a specif…
Jiyu13 Aug 19, 2025
3b732da
- add onAddClick call back
Jiyu13 Aug 19, 2025
593b677
- set up AddNewItemScreen navigation
Jiyu13 Aug 19, 2025
3f4dc66
- add insertListItem API call for creating list items
Jiyu13 Aug 19, 2025
754799e
- add ViewModel logic for creating list items with state handling
Jiyu13 Aug 19, 2025
42febde
feat: add new item creation screen
Jiyu13 Aug 19, 2025
48cbc2f
add checking if error exists + show error supporting text
Jiyu13 Aug 19, 2025
8a0afcd
- check if description field is empty
Jiyu13 Aug 19, 2025
708eb4f
- change icon content description
Jiyu13 Aug 19, 2025
b5ad072
- create functionalities to edit list name / delete list
Jiyu13 Aug 20, 2025
dad3e4c
- check if new list name is empty
Jiyu13 Aug 20, 2025
e4a949f
- replace outline button with CustomOutlinedButton
Jiyu13 Aug 20, 2025
a0380fd
- add text style
Jiyu13 Aug 20, 2025
3168355
- create ButtonStyle file
Jiyu13 Aug 20, 2025
f40bc63
- change button shape
Jiyu13 Aug 20, 2025
717e2e5
- set isError to false when close the form
Jiyu13 Aug 20, 2025
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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@
.externalNativeBuild
.cxx
local.properties
/app/src/main/java/com/example/listifyjetapp/utils/constants/Constants.kt
2 changes: 1 addition & 1 deletion .idea/deploymentTargetSelector.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

61 changes: 61 additions & 0 deletions .idea/inspectionProfiles/Project_Default.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 25 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ plugins {

alias(libs.plugins.hilt)
alias(libs.plugins.ksp)

// Kotlin serialization plugin for type safe routes and navigation arguments
kotlin("plugin.serialization") version "2.0.21"
}

android {
Expand Down Expand Up @@ -105,4 +108,26 @@ dependencies {
// google font
implementation(libs.androidx.ui.text.google.fonts)

// material icons
implementation (libs.androidx.material.icons.extended)

// ================= Kotlin serialization =======================
// Jetpack Compose integration
implementation(libs.androidx.navigation.compose)

// Views/Fragments integration
implementation(libs.androidx.navigation.fragment)
implementation(libs.androidx.navigation.ui)

// Feature module support for Fragments
implementation(libs.androidx.navigation.dynamic.features.fragment)

// Testing Navigation
androidTestImplementation(libs.androidx.navigation.testing)

// JSON serialization library, works with the Kotlin serialization plugin
implementation(libs.kotlinx.serialization.json)

// Typed DataStore (Typed API surface, such as Proto)
implementation(libs.androidx.datastore.preferences)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
package com.example.listifyjetapp.components.authButtons

import androidx.compose.foundation.BorderStroke
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.automirrored.filled.ExitToApp
import androidx.compose.material.icons.filled.MailOutline
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.unit.dp
import com.example.listifyjetapp.ui.theme.ButtonPaddings
import com.example.listifyjetapp.ui.theme.ButtonShape
import com.example.listifyjetapp.ui.theme.ListifyColor
import com.example.listifyjetapp.widgets.buttons.CustomOutlinedButton
import com.example.listifyjetapp.widgets.buttons.FilledButton

@Composable
fun AuthButtons(onGoToLoginScreen: () -> Unit) {
Column(
modifier = Modifier
.fillMaxSize()
.padding(16.dp),
verticalArrangement = Arrangement.Bottom,
horizontalAlignment = Alignment.CenterHorizontally
) {
CustomOutlinedButton(
modifier = ButtonPaddings.fillMaxWidth(),
shape = ButtonShape,
border = BorderStroke(2.dp, color = Color.White),
text = "SIGN UP WITH EMAIL",
textColor = ListifyColor.TextDark,
buttonIcon = Icons.Default.MailOutline,
iconDescription = "Sign In Email",
onClick = {}
)

FilledButton(
modifier = ButtonPaddings.fillMaxWidth(),
shape = ButtonShape,
containerColor = Color.White,
contentColor = ListifyColor.TextDark,
text = "LOG IN",
buttonIcon = Icons.AutoMirrored.Filled.ExitToApp,
iconDescription = "Log In",
onClick = { onGoToLoginScreen() }
)
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
package com.example.listifyjetapp.components.bottomMenus

import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.Delete
import androidx.compose.material.icons.filled.Edit
import androidx.compose.material3.ExperimentalMaterial3Api
import androidx.compose.material3.Icon
import androidx.compose.material3.ListItem
import androidx.compose.material3.ModalBottomSheet
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.hilt.navigation.compose.hiltViewModel
import com.example.listifyjetapp.ui.screens.listItem.ListItemViewModel

@OptIn(ExperimentalMaterial3Api::class)
@Composable
fun ListItemActionSheet(
onDismissSheet: () -> Unit,
viewModel: ListItemViewModel = hiltViewModel()
) {
ModalBottomSheet(
onDismissRequest = onDismissSheet,
modifier = Modifier.fillMaxWidth(),
) {

Text(
modifier = Modifier.fillMaxWidth().padding(8.dp),
textAlign = TextAlign.Center,
text = viewModel.activeItemDescription,
fontSize = 20.sp
)

ListItem(
headlineContent = { Text(text = "Edit", fontSize = 20.sp) },
leadingContent = { Icon(Icons.Default.Edit, null) }
)
ListItem(
headlineContent = { Text(text = "Delete", fontSize = 20.sp) },
leadingContent = { Icon(Icons.Default.Delete, null) }
)
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
package com.example.listifyjetapp.components.formModals

import androidx.compose.foundation.BorderStroke
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.runtime.Composable
import androidx.compose.runtime.MutableState
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.unit.dp
import com.example.listifyjetapp.ui.theme.ButtonBorderStroke
import com.example.listifyjetapp.ui.theme.ButtonPaddings
import com.example.listifyjetapp.ui.theme.ButtonShape
import com.example.listifyjetapp.ui.theme.ListifyColor
import com.example.listifyjetapp.widgets.buttons.CustomOutlinedButton
import com.example.listifyjetapp.widgets.buttons.FilledButton
import com.example.listifyjetapp.widgets.inputFields.FormInputField

@Composable
fun EditItemForm(
description: String,
units: String,
isError: Boolean,
onDescriptionChange: (String) -> Unit,
onUnitsChange: (String) -> Unit,
onEditFormSubmit: () -> Unit,
onDeleteItem: () -> Unit
) {

Column(
modifier = Modifier.fillMaxWidth()
) {
FormInputField(
placerHolder = "e.g., grocery list",
textState = description,
isError = isError,
onValueChange = onDescriptionChange
)

FormInputField(
placerHolder = "e.g., 1 lbs",
textState = units,
onValueChange = onUnitsChange
)

FilledButton(
modifier = ButtonPaddings.fillMaxWidth(),
shape = ButtonShape,
containerColor = ListifyColor.SplashYellow,
contentColor = Color.White,
text = "Update",
buttonIcon = null,
iconDescription = null,
onClick = { onEditFormSubmit() }
)
CustomOutlinedButton(
modifier = ButtonPaddings.fillMaxWidth(),
shape = ButtonShape,
border = BorderStroke(ButtonBorderStroke, color = Color.Red),
text = "Delete",
textColor = Color.Red,
onClick = { onDeleteItem() }
)
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
package com.example.listifyjetapp.components.formModals

import androidx.compose.foundation.BorderStroke
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.unit.dp
import com.example.listifyjetapp.ui.theme.ButtonBorderStroke
import com.example.listifyjetapp.ui.theme.ButtonPaddings
import com.example.listifyjetapp.ui.theme.ButtonShape
import com.example.listifyjetapp.ui.theme.ListifyColor
import com.example.listifyjetapp.widgets.buttons.CustomOutlinedButton
import com.example.listifyjetapp.widgets.buttons.FilledButton
import com.example.listifyjetapp.widgets.inputFields.FormInputField

@Composable
fun EditListForm(
listName: String,
isError: Boolean,
onListNameChange: (String) -> Unit,
onEditFormSubmit: () -> Unit,
onDeleteItem: () -> Unit
) {

Column(
modifier = Modifier.fillMaxWidth()
) {
FormInputField(
placerHolder = "e.g., grocery list",
textState = listName,
isError = isError,
onValueChange = onListNameChange
)

FilledButton(
modifier = ButtonPaddings.fillMaxWidth(),
shape = ButtonShape,
containerColor = ListifyColor.SplashYellow,
contentColor = Color.White,
text = "Update",
buttonIcon = null,
iconDescription = null,
onClick = { onEditFormSubmit() }
)
CustomOutlinedButton(
modifier = ButtonPaddings.fillMaxWidth(),
shape = ButtonShape,
border = BorderStroke(ButtonBorderStroke, color = Color.Red),
text = "Delete",
textColor = Color.Red,
onClick = { onDeleteItem() }
)
}
}
Loading