From e534e95020eff1f7569bd8f1b7d1b65cc44c680c Mon Sep 17 00:00:00 2001 From: f1rq Date: Tue, 29 Apr 2025 16:10:25 +0200 Subject: [PATCH] Updates --- .idea/appInsightsSettings.xml | 50 +- .idea/discord.xml | 12 +- app/build.gradle.kts | 116 +-- .../java/com/f1rq/lifemap/MainActivity.kt | 164 ++-- .../f1rq/lifemap/components/AddEventCard.kt | 200 ++-- .../com/f1rq/lifemap/components/NavBar.kt | 224 ++--- .../f1rq/lifemap/components/SettingsLabel.kt | 126 +-- .../com/f1rq/lifemap/components/TopBar.kt | 224 ++--- .../java/com/f1rq/lifemap/screens/ListView.kt | 38 +- .../java/com/f1rq/lifemap/screens/MapView.kt | 68 +- .../lifemap/screens/NotificationsScreen.kt | 76 +- .../f1rq/lifemap/screens/SettingsScreen.kt | 154 +-- .../SettingsNotificationsScreen.kt | 36 +- .../java/com/f1rq/lifemap/ui/theme/Color.kt | 24 +- .../main/res/drawable/add_event_button.xml | 18 +- app/src/main/res/drawable/contact_icon.xml | 10 +- app/src/main/res/drawable/feedback_icon.xml | 10 +- .../res/drawable/navbar_listview_button.xml | 18 +- .../res/drawable/navbar_mapview_button.xml | 18 +- .../res/drawable/notifications_button.xml | 18 +- app/src/main/res/drawable/settings_button.xml | 18 +- .../main/ui-packages/add_event/add_event.json | 718 +++++++------- .../main/ui-packages/add_event/config.json | 6 +- app/src/main/ui-packages/add_event/icon.svg | 6 +- .../navigation_bar/navigation_bar.json | 662 ++++++------- .../ui-packages/navigation_bar/vector.svg | 6 +- .../ui-packages/navigation_bar/vector1.svg | 6 +- .../main/ui-packages/top_app_bar/config.json | 6 +- app/src/main/ui-packages/top_app_bar/icon.svg | 6 +- .../main/ui-packages/top_app_bar/icon1.svg | 6 +- .../ui-packages/top_app_bar/top_app_bar.json | 912 +++++++++--------- gradle/libs.versions.toml | 68 +- gradlew | 370 +++---- 33 files changed, 2197 insertions(+), 2197 deletions(-) diff --git a/.idea/appInsightsSettings.xml b/.idea/appInsightsSettings.xml index 371f2e2..fd8246c 100644 --- a/.idea/appInsightsSettings.xml +++ b/.idea/appInsightsSettings.xml @@ -1,26 +1,26 @@ - - - - - + + + + + \ No newline at end of file diff --git a/.idea/discord.xml b/.idea/discord.xml index d8e9561..66c4b97 100644 --- a/.idea/discord.xml +++ b/.idea/discord.xml @@ -1,7 +1,7 @@ - - - - + + + + \ No newline at end of file diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 67bbb5a..d6305f1 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -1,59 +1,59 @@ -plugins { - alias(libs.plugins.android.application) - alias(libs.plugins.kotlin.android) - alias(libs.plugins.kotlin.compose) -} - -android { - namespace = "com.f1rq.lifemap" - compileSdk = 35 - - defaultConfig { - applicationId = "com.f1rq.lifemap" - minSdk = 26 - targetSdk = 35 - versionCode = 1 - versionName = "1.0" - - testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" - } - - buildTypes { - release { - isMinifyEnabled = false - proguardFiles( - getDefaultProguardFile("proguard-android-optimize.txt"), - "proguard-rules.pro" - ) - } - } - compileOptions { - sourceCompatibility = JavaVersion.VERSION_11 - targetCompatibility = JavaVersion.VERSION_11 - } - kotlinOptions { - jvmTarget = "11" - } - buildFeatures { - compose = true - } -} - -dependencies { - implementation(libs.androidx.core.ktx) - implementation(libs.androidx.lifecycle.runtime.ktx) - implementation(libs.androidx.activity.compose) - implementation(platform(libs.androidx.compose.bom)) - implementation(libs.androidx.ui) - implementation(libs.androidx.ui.graphics) - implementation(libs.androidx.ui.tooling.preview) - implementation(libs.androidx.material3) - implementation(libs.androidx.navigation.compose) - testImplementation(libs.junit) - androidTestImplementation(libs.androidx.junit) - androidTestImplementation(libs.androidx.espresso.core) - androidTestImplementation(platform(libs.androidx.compose.bom)) - androidTestImplementation(libs.androidx.ui.test.junit4) - debugImplementation(libs.androidx.ui.tooling) - debugImplementation(libs.androidx.ui.test.manifest) +plugins { + alias(libs.plugins.android.application) + alias(libs.plugins.kotlin.android) + alias(libs.plugins.kotlin.compose) +} + +android { + namespace = "com.f1rq.lifemap" + compileSdk = 35 + + defaultConfig { + applicationId = "com.f1rq.lifemap" + minSdk = 26 + targetSdk = 35 + versionCode = 1 + versionName = "1.0" + + testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" + } + + buildTypes { + release { + isMinifyEnabled = false + proguardFiles( + getDefaultProguardFile("proguard-android-optimize.txt"), + "proguard-rules.pro" + ) + } + } + compileOptions { + sourceCompatibility = JavaVersion.VERSION_11 + targetCompatibility = JavaVersion.VERSION_11 + } + kotlinOptions { + jvmTarget = "11" + } + buildFeatures { + compose = true + } +} + +dependencies { + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.lifecycle.runtime.ktx) + implementation(libs.androidx.activity.compose) + implementation(platform(libs.androidx.compose.bom)) + implementation(libs.androidx.ui) + implementation(libs.androidx.ui.graphics) + implementation(libs.androidx.ui.tooling.preview) + implementation(libs.androidx.material3) + implementation(libs.androidx.navigation.compose) + testImplementation(libs.junit) + androidTestImplementation(libs.androidx.junit) + androidTestImplementation(libs.androidx.espresso.core) + androidTestImplementation(platform(libs.androidx.compose.bom)) + androidTestImplementation(libs.androidx.ui.test.junit4) + debugImplementation(libs.androidx.ui.tooling) + debugImplementation(libs.androidx.ui.test.manifest) } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/MainActivity.kt b/app/src/main/java/com/f1rq/lifemap/MainActivity.kt index b229687..e6c806d 100644 --- a/app/src/main/java/com/f1rq/lifemap/MainActivity.kt +++ b/app/src/main/java/com/f1rq/lifemap/MainActivity.kt @@ -1,82 +1,82 @@ -package com.f1rq.lifemap - -import android.os.Bundle -import androidx.activity.ComponentActivity -import androidx.activity.compose.setContent -import androidx.activity.enableEdgeToEdge -import androidx.compose.foundation.isSystemInDarkTheme -import androidx.compose.foundation.layout.padding -import androidx.compose.material3.Scaffold -import androidx.compose.ui.Modifier -import androidx.core.view.WindowCompat -import androidx.navigation.compose.NavHost -import androidx.navigation.compose.composable -import androidx.navigation.compose.currentBackStackEntryAsState -import androidx.navigation.compose.rememberNavController -import androidx.compose.runtime.SideEffect -import androidx.compose.ui.platform.LocalView -import com.f1rq.lifemap.screens.ListView -import com.f1rq.lifemap.screens.MapView -import com.f1rq.lifemap.screens.SettingsScreen -import com.f1rq.lifemap.screens.NotificationsScreen -import com.f1rq.lifemap.ui.theme.LifeMapTheme -import com.f1rq.lifemap.ui.theme.ActiveNavColor -import com.f1rq.lifemap.ui.theme.InactiveNavColor -import com.f1rq.lifemap.components.TopBar -import com.f1rq.lifemap.components.NavBar -import com.f1rq.lifemap.screens.settingsScreens.SettingsNotificationsScreen - -class MainActivity : ComponentActivity() { - override fun onCreate(savedInstanceState: Bundle?) { - super.onCreate(savedInstanceState) - enableEdgeToEdge() - WindowCompat.setDecorFitsSystemWindows(window, false) - - setContent { - LifeMapTheme { - val navController = rememberNavController() - - val view = LocalView.current - val darkTheme = !isSystemInDarkTheme() - SideEffect { - WindowCompat.setDecorFitsSystemWindows(window, false) - val insetsController = WindowCompat.getInsetsController(window, view) - insetsController.isAppearanceLightStatusBars = true - insetsController.isAppearanceLightNavigationBars = true - } - - Scaffold( - topBar = { - TopBar( - onSettingsButtonClick = { navController.navigate("settings")}, - onNotificationsButtonClick = { navController.navigate("notifications")} - ) - }, - bottomBar = { - val navBackStackEntry = navController.currentBackStackEntryAsState() - val currentRoute = navBackStackEntry.value?.destination?.route - - NavBar( - onMapViewClicked = { navController.navigate("mapview") }, - onListViewClicked = { navController.navigate("listview") }, - mapViewBackgroundColor = if (currentRoute == "mapview") ActiveNavColor else InactiveNavColor, - listViewBackgroundColor = if (currentRoute == "listview") ActiveNavColor else InactiveNavColor - ) - } - ) { innerPadding -> - NavHost( - navController = navController, - startDestination = "mapview", - modifier = Modifier.padding(innerPadding) - ) { - composable("mapview") { MapView(Modifier) } - composable("listview") { ListView(Modifier) } - composable("settings") { SettingsScreen(navController = navController, Modifier)} - composable("notifications") { NotificationsScreen(Modifier)} - composable("settings_notifications") { SettingsNotificationsScreen(Modifier) } - } - } - } - } - } -} +package com.f1rq.lifemap + +import android.os.Bundle +import androidx.activity.ComponentActivity +import androidx.activity.compose.setContent +import androidx.activity.enableEdgeToEdge +import androidx.compose.foundation.isSystemInDarkTheme +import androidx.compose.foundation.layout.padding +import androidx.compose.material3.Scaffold +import androidx.compose.ui.Modifier +import androidx.core.view.WindowCompat +import androidx.navigation.compose.NavHost +import androidx.navigation.compose.composable +import androidx.navigation.compose.currentBackStackEntryAsState +import androidx.navigation.compose.rememberNavController +import androidx.compose.runtime.SideEffect +import androidx.compose.ui.platform.LocalView +import com.f1rq.lifemap.screens.ListView +import com.f1rq.lifemap.screens.MapView +import com.f1rq.lifemap.screens.SettingsScreen +import com.f1rq.lifemap.screens.NotificationsScreen +import com.f1rq.lifemap.ui.theme.LifeMapTheme +import com.f1rq.lifemap.ui.theme.ActiveNavColor +import com.f1rq.lifemap.ui.theme.InactiveNavColor +import com.f1rq.lifemap.components.TopBar +import com.f1rq.lifemap.components.NavBar +import com.f1rq.lifemap.screens.settingsScreens.SettingsNotificationsScreen + +class MainActivity : ComponentActivity() { + override fun onCreate(savedInstanceState: Bundle?) { + super.onCreate(savedInstanceState) + enableEdgeToEdge() + WindowCompat.setDecorFitsSystemWindows(window, false) + + setContent { + LifeMapTheme { + val navController = rememberNavController() + + val view = LocalView.current + val darkTheme = !isSystemInDarkTheme() + SideEffect { + WindowCompat.setDecorFitsSystemWindows(window, false) + val insetsController = WindowCompat.getInsetsController(window, view) + insetsController.isAppearanceLightStatusBars = true + insetsController.isAppearanceLightNavigationBars = true + } + + Scaffold( + topBar = { + TopBar( + onSettingsButtonClick = { navController.navigate("settings")}, + onNotificationsButtonClick = { navController.navigate("notifications")} + ) + }, + bottomBar = { + val navBackStackEntry = navController.currentBackStackEntryAsState() + val currentRoute = navBackStackEntry.value?.destination?.route + + NavBar( + onMapViewClicked = { navController.navigate("mapview") }, + onListViewClicked = { navController.navigate("listview") }, + mapViewBackgroundColor = if (currentRoute == "mapview") ActiveNavColor else InactiveNavColor, + listViewBackgroundColor = if (currentRoute == "listview") ActiveNavColor else InactiveNavColor + ) + } + ) { innerPadding -> + NavHost( + navController = navController, + startDestination = "mapview", + modifier = Modifier.padding(innerPadding) + ) { + composable("mapview") { MapView(Modifier) } + composable("listview") { ListView(Modifier) } + composable("settings") { SettingsScreen(navController = navController, Modifier)} + composable("notifications") { NotificationsScreen(Modifier)} + composable("settings_notifications") { SettingsNotificationsScreen(Modifier) } + } + } + } + } + } +} diff --git a/app/src/main/java/com/f1rq/lifemap/components/AddEventCard.kt b/app/src/main/java/com/f1rq/lifemap/components/AddEventCard.kt index f5b9c93..96de70b 100644 --- a/app/src/main/java/com/f1rq/lifemap/components/AddEventCard.kt +++ b/app/src/main/java/com/f1rq/lifemap/components/AddEventCard.kt @@ -1,100 +1,100 @@ -package com.f1rq.lifemap.components - -import androidx.compose.foundation.background -import androidx.compose.foundation.layout.* -import androidx.compose.foundation.shape.RoundedCornerShape -import androidx.compose.material3.* -import androidx.compose.material3.CardDefaults -import androidx.compose.material3.Icon -import androidx.compose.material3.IconButton -import androidx.compose.material3.Text -import androidx.compose.material3.MaterialTheme -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.Modifier -import androidx.compose.ui.unit.dp -import androidx.compose.material.icons.Icons -import androidx.compose.material.icons.filled.Edit -import androidx.compose.ui.draw.shadow -import androidx.compose.ui.res.painterResource -import androidx.compose.ui.tooling.preview.Preview -import com.f1rq.lifemap.ui.theme.MainBG -import com.f1rq.lifemap.ui.theme.MainTextColor -import com.f1rq.lifemap.ui.theme.PrimaryColor -import com.f1rq.lifemap.R.drawable.add_event_button -import com.f1rq.lifemap.R.drawable.navbar_mapview_button - -@Composable -fun AddEventCard( - modifier: Modifier = Modifier, - onCreateEventClick: () -> Unit = {} -) { - Card( - modifier = modifier - .fillMaxWidth() - .padding(8.dp), - shape = RoundedCornerShape(16.dp), - elevation = CardDefaults.cardElevation(defaultElevation = 4.dp), - colors = CardDefaults.cardColors( - containerColor = MainBG, - ) - ) { - Row( - modifier = Modifier - .padding( - horizontal = 16.dp, - vertical = 12.dp, - ), - verticalAlignment = Alignment.CenterVertically, - horizontalArrangement = Arrangement.SpaceBetween - ) { - Column( - modifier = Modifier - .weight(1f) - ) { - Text( - text = "Add event", - style = MaterialTheme.typography.titleMedium, - color = MainTextColor - ) - Text( - text = "With localization, date etc.", - style = MaterialTheme.typography.bodySmall, - color = MainTextColor - ) - } - - Box( - modifier = Modifier - .shadow( - elevation = 3.dp, - shape = RoundedCornerShape(12.dp), - clip = false - ) - .background( - color = MainBG, - shape = RoundedCornerShape(12.dp) - ) - .size(56.dp) - ) { - IconButton( - onClick = onCreateEventClick, - modifier = Modifier.fillMaxSize() - ) { - Icon( - painter = painterResource(id = add_event_button), - contentDescription = "Edit", - tint = PrimaryColor - ) - } - } - - } - } -} - -@Preview(showBackground = true) -@Composable -fun AddEventCardPreview() { - AddEventCard() -} +package com.f1rq.lifemap.components + +import androidx.compose.foundation.background +import androidx.compose.foundation.layout.* +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.* +import androidx.compose.material3.CardDefaults +import androidx.compose.material3.Icon +import androidx.compose.material3.IconButton +import androidx.compose.material3.Text +import androidx.compose.material3.MaterialTheme +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.unit.dp +import androidx.compose.material.icons.Icons +import androidx.compose.material.icons.filled.Edit +import androidx.compose.ui.draw.shadow +import androidx.compose.ui.res.painterResource +import androidx.compose.ui.tooling.preview.Preview +import com.f1rq.lifemap.ui.theme.MainBG +import com.f1rq.lifemap.ui.theme.MainTextColor +import com.f1rq.lifemap.ui.theme.PrimaryColor +import com.f1rq.lifemap.R.drawable.add_event_button +import com.f1rq.lifemap.R.drawable.navbar_mapview_button + +@Composable +fun AddEventCard( + modifier: Modifier = Modifier, + onCreateEventClick: () -> Unit = {} +) { + Card( + modifier = modifier + .fillMaxWidth() + .padding(8.dp), + shape = RoundedCornerShape(16.dp), + elevation = CardDefaults.cardElevation(defaultElevation = 4.dp), + colors = CardDefaults.cardColors( + containerColor = MainBG, + ) + ) { + Row( + modifier = Modifier + .padding( + horizontal = 16.dp, + vertical = 12.dp, + ), + verticalAlignment = Alignment.CenterVertically, + horizontalArrangement = Arrangement.SpaceBetween + ) { + Column( + modifier = Modifier + .weight(1f) + ) { + Text( + text = "Add event", + style = MaterialTheme.typography.titleMedium, + color = MainTextColor + ) + Text( + text = "With localization, date etc.", + style = MaterialTheme.typography.bodySmall, + color = MainTextColor + ) + } + + Box( + modifier = Modifier + .shadow( + elevation = 3.dp, + shape = RoundedCornerShape(12.dp), + clip = false + ) + .background( + color = MainBG, + shape = RoundedCornerShape(12.dp) + ) + .size(56.dp) + ) { + IconButton( + onClick = onCreateEventClick, + modifier = Modifier.fillMaxSize() + ) { + Icon( + painter = painterResource(id = add_event_button), + contentDescription = "Edit", + tint = PrimaryColor + ) + } + } + + } + } +} + +@Preview(showBackground = true) +@Composable +fun AddEventCardPreview() { + AddEventCard() +} diff --git a/app/src/main/java/com/f1rq/lifemap/components/NavBar.kt b/app/src/main/java/com/f1rq/lifemap/components/NavBar.kt index f65ca61..e7c89a6 100644 --- a/app/src/main/java/com/f1rq/lifemap/components/NavBar.kt +++ b/app/src/main/java/com/f1rq/lifemap/components/NavBar.kt @@ -1,113 +1,113 @@ -package com.f1rq.lifemap.components - -import androidx.compose.foundation.layout.* -import androidx.compose.foundation.shape.RoundedCornerShape -import androidx.compose.material3.Icon -import androidx.compose.material3.IconButton -import androidx.compose.foundation.background -import androidx.compose.foundation.layout.fillMaxWidth -import androidx.compose.foundation.layout.padding -import androidx.compose.material3.Card -import androidx.compose.material3.CardDefaults -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.unit.dp -import androidx.compose.ui.Modifier -import androidx.compose.ui.draw.drawBehind -import androidx.compose.ui.geometry.Offset -import androidx.compose.ui.geometry.Size -import androidx.compose.ui.graphics.Brush -import androidx.compose.ui.graphics.Color -import androidx.compose.ui.res.painterResource -import androidx.compose.ui.tooling.preview.Preview -import androidx.compose.ui.unit.Dp -import com.f1rq.lifemap.ui.theme.MainBG -import com.f1rq.lifemap.ui.theme.InactiveNavColor -import com.f1rq.lifemap.ui.theme.ActiveNavColor -import com.f1rq.lifemap.ui.theme.PrimaryColor -import com.f1rq.lifemap.R.drawable.navbar_listview_button -import com.f1rq.lifemap.R.drawable.navbar_mapview_button -import com.google.relay.compose.BoxScopeInstanceImpl.align - -@Composable -fun NavBar( - modifier: Modifier = Modifier, - onMapViewClicked: () -> Unit = {}, - onListViewClicked: () -> Unit = {}, - mapViewBackgroundColor: Color = ActiveNavColor, - listViewBackgroundColor: Color = InactiveNavColor, -) { - Box( - modifier = modifier - .fillMaxWidth() - ) { - - Card( - modifier = Modifier.fillMaxWidth(), - colors = CardDefaults.cardColors(containerColor = MainBG), - elevation = CardDefaults.cardElevation(defaultElevation = 6.dp), - ) { - Row( - modifier = Modifier - .padding( - top = 12.dp, - bottom = WindowInsets.navigationBars.asPaddingValues().calculateBottomPadding() + 6.dp, - ), - verticalAlignment = Alignment.CenterVertically - ) { - Box( - modifier = Modifier - .weight(1f), - contentAlignment = Alignment.Center - ) { - IconButton( - onClick = onMapViewClicked, - modifier = Modifier - .size(48.dp) - .background( - color = mapViewBackgroundColor, - shape = RoundedCornerShape(16.dp) - ) - ) { - Icon( - painter = painterResource(id = navbar_mapview_button), - contentDescription = "Map View", - modifier = Modifier.requiredSize(24.dp), - tint = PrimaryColor - ) - } - } - - Box( - modifier = Modifier - .weight(1f), - contentAlignment = Alignment.Center - ) { - IconButton( - onClick = onListViewClicked, - modifier = Modifier - .size(48.dp) - .background( - color = listViewBackgroundColor, - shape = RoundedCornerShape(16.dp) - ) - ) { - Icon( - painter = painterResource(id = navbar_listview_button), - contentDescription = "List View", - modifier = Modifier.requiredSize(24.dp), - tint = PrimaryColor - ) - } - } - } - } - } -} - - -@Preview -@Composable -fun NavBarPreview() { - NavBar() +package com.f1rq.lifemap.components + +import androidx.compose.foundation.layout.* +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.Icon +import androidx.compose.material3.IconButton +import androidx.compose.foundation.background +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.padding +import androidx.compose.material3.Card +import androidx.compose.material3.CardDefaults +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.unit.dp +import androidx.compose.ui.Modifier +import androidx.compose.ui.draw.drawBehind +import androidx.compose.ui.geometry.Offset +import androidx.compose.ui.geometry.Size +import androidx.compose.ui.graphics.Brush +import androidx.compose.ui.graphics.Color +import androidx.compose.ui.res.painterResource +import androidx.compose.ui.tooling.preview.Preview +import androidx.compose.ui.unit.Dp +import com.f1rq.lifemap.ui.theme.MainBG +import com.f1rq.lifemap.ui.theme.InactiveNavColor +import com.f1rq.lifemap.ui.theme.ActiveNavColor +import com.f1rq.lifemap.ui.theme.PrimaryColor +import com.f1rq.lifemap.R.drawable.navbar_listview_button +import com.f1rq.lifemap.R.drawable.navbar_mapview_button +import com.google.relay.compose.BoxScopeInstanceImpl.align + +@Composable +fun NavBar( + modifier: Modifier = Modifier, + onMapViewClicked: () -> Unit = {}, + onListViewClicked: () -> Unit = {}, + mapViewBackgroundColor: Color = ActiveNavColor, + listViewBackgroundColor: Color = InactiveNavColor, +) { + Box( + modifier = modifier + .fillMaxWidth() + ) { + + Card( + modifier = Modifier.fillMaxWidth(), + colors = CardDefaults.cardColors(containerColor = MainBG), + elevation = CardDefaults.cardElevation(defaultElevation = 6.dp), + ) { + Row( + modifier = Modifier + .padding( + top = 12.dp, + bottom = WindowInsets.navigationBars.asPaddingValues().calculateBottomPadding() + 6.dp, + ), + verticalAlignment = Alignment.CenterVertically + ) { + Box( + modifier = Modifier + .weight(1f), + contentAlignment = Alignment.Center + ) { + IconButton( + onClick = onMapViewClicked, + modifier = Modifier + .size(48.dp) + .background( + color = mapViewBackgroundColor, + shape = RoundedCornerShape(16.dp) + ) + ) { + Icon( + painter = painterResource(id = navbar_mapview_button), + contentDescription = "Map View", + modifier = Modifier.requiredSize(24.dp), + tint = PrimaryColor + ) + } + } + + Box( + modifier = Modifier + .weight(1f), + contentAlignment = Alignment.Center + ) { + IconButton( + onClick = onListViewClicked, + modifier = Modifier + .size(48.dp) + .background( + color = listViewBackgroundColor, + shape = RoundedCornerShape(16.dp) + ) + ) { + Icon( + painter = painterResource(id = navbar_listview_button), + contentDescription = "List View", + modifier = Modifier.requiredSize(24.dp), + tint = PrimaryColor + ) + } + } + } + } + } +} + + +@Preview +@Composable +fun NavBarPreview() { + NavBar() } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/components/SettingsLabel.kt b/app/src/main/java/com/f1rq/lifemap/components/SettingsLabel.kt index cb2952f..5771029 100644 --- a/app/src/main/java/com/f1rq/lifemap/components/SettingsLabel.kt +++ b/app/src/main/java/com/f1rq/lifemap/components/SettingsLabel.kt @@ -1,63 +1,63 @@ -package com.f1rq.lifemap.components - -import androidx.compose.foundation.layout.Row -import androidx.compose.foundation.layout.Spacer -import androidx.compose.foundation.layout.fillMaxWidth -import androidx.compose.foundation.layout.padding -import androidx.compose.foundation.layout.size -import androidx.compose.foundation.shape.RoundedCornerShape -import androidx.compose.material.icons.Icons -import androidx.compose.material.icons.filled.Edit -import androidx.compose.runtime.Composable -import androidx.compose.ui.Modifier -import androidx.compose.material3.* -import androidx.compose.material3.Icon -import androidx.compose.ui.Alignment -import androidx.compose.ui.graphics.vector.ImageVector -import androidx.compose.ui.unit.dp -import com.f1rq.lifemap.ui.theme.MainBG -import com.f1rq.lifemap.ui.theme.MainTextColor -import com.f1rq.lifemap.ui.theme.PrimaryColor - -@Composable -fun SettingsLabel( - modifier: Modifier = Modifier, - text: String, - iconResource: ImageVector = Icons.Default.Edit, - desc: String? = null, - onClick: () -> Unit = {}, -) { - Card( - modifier = modifier - .fillMaxWidth() - .padding(8.dp), - shape = RoundedCornerShape(16.dp), - colors = CardDefaults.cardColors( - containerColor = MainBG, - ), - onClick = onClick, - ) { - Row( - modifier = Modifier - .padding( - horizontal = 16.dp, - vertical = 12.dp, - ), - verticalAlignment = Alignment.CenterVertically - ) { - Icon( - imageVector = iconResource, - contentDescription = desc, - tint = PrimaryColor - ) - - Spacer(modifier = Modifier.size(12.dp)) - - Text( - text = text, - style = MaterialTheme.typography.titleMedium, - color = MainTextColor - ) - } - } -} +package com.f1rq.lifemap.components + +import androidx.compose.foundation.layout.Row +import androidx.compose.foundation.layout.Spacer +import androidx.compose.foundation.layout.fillMaxWidth +import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.size +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material.icons.Icons +import androidx.compose.material.icons.filled.Edit +import androidx.compose.runtime.Composable +import androidx.compose.ui.Modifier +import androidx.compose.material3.* +import androidx.compose.material3.Icon +import androidx.compose.ui.Alignment +import androidx.compose.ui.graphics.vector.ImageVector +import androidx.compose.ui.unit.dp +import com.f1rq.lifemap.ui.theme.MainBG +import com.f1rq.lifemap.ui.theme.MainTextColor +import com.f1rq.lifemap.ui.theme.PrimaryColor + +@Composable +fun SettingsLabel( + modifier: Modifier = Modifier, + text: String, + iconResource: ImageVector = Icons.Default.Edit, + desc: String? = null, + onClick: () -> Unit = {}, +) { + Card( + modifier = modifier + .fillMaxWidth() + .padding(8.dp), + shape = RoundedCornerShape(16.dp), + colors = CardDefaults.cardColors( + containerColor = MainBG, + ), + onClick = onClick, + ) { + Row( + modifier = Modifier + .padding( + horizontal = 16.dp, + vertical = 12.dp, + ), + verticalAlignment = Alignment.CenterVertically + ) { + Icon( + imageVector = iconResource, + contentDescription = desc, + tint = PrimaryColor + ) + + Spacer(modifier = Modifier.size(12.dp)) + + Text( + text = text, + style = MaterialTheme.typography.titleMedium, + color = MainTextColor + ) + } + } +} diff --git a/app/src/main/java/com/f1rq/lifemap/components/TopBar.kt b/app/src/main/java/com/f1rq/lifemap/components/TopBar.kt index 0551707..84396e6 100644 --- a/app/src/main/java/com/f1rq/lifemap/components/TopBar.kt +++ b/app/src/main/java/com/f1rq/lifemap/components/TopBar.kt @@ -1,112 +1,112 @@ -package com.f1rq.lifemap.components - -import android.graphics.drawable.shapes.Shape -import androidx.compose.foundation.layout.* -import androidx.compose.foundation.shape.RoundedCornerShape -import androidx.compose.material3.* -import androidx.compose.material3.CardDefaults -import androidx.compose.material3.Icon -import androidx.compose.material3.IconButton -import androidx.compose.material3.Text -import androidx.compose.material3.MaterialTheme -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.Modifier -import androidx.compose.ui.graphics.RectangleShape -import androidx.compose.ui.unit.dp -import androidx.compose.ui.res.painterResource -import androidx.compose.ui.text.font.FontWeight -import androidx.compose.ui.tooling.preview.Preview -import androidx.compose.ui.unit.Dp -import com.f1rq.lifemap.ui.theme.MainBG -import com.f1rq.lifemap.ui.theme.MainTextColor -import com.f1rq.lifemap.ui.theme.PrimaryColor -import com.f1rq.lifemap.R.drawable.notifications_button -import com.f1rq.lifemap.R.drawable.settings_button - -@Composable -fun TopBar( - modifier: Modifier = Modifier, - onNotificationsButtonClick: () -> Unit = {}, - onSettingsButtonClick: () -> Unit = {} -) { - Card( - modifier = Modifier - .fillMaxWidth(), - shape = RoundedCornerShape( - topStart = 0.dp, - topEnd = 0.dp, - bottomStart = 16.dp, - bottomEnd = 16.dp - ), - elevation = CardDefaults.cardElevation(defaultElevation = 6.dp), - colors = CardDefaults.cardColors( - containerColor = MainBG, - ) - ) { - Row( - modifier = Modifier - .padding( - start = 20.0.dp, - top = WindowInsets.statusBars.asPaddingValues().calculateTopPadding(), - end = 20.0.dp, - bottom = 15.0.dp - ), - verticalAlignment = Alignment.CenterVertically, - horizontalArrangement = Arrangement.SpaceBetween - ) { - Column( - modifier = Modifier - .weight(1f) - ) { - Text( - text = "LifeMap", - style = MaterialTheme.typography.titleMedium, - fontSize = MaterialTheme.typography.titleLarge.fontSize, - fontFamily = MaterialTheme.typography.titleLarge.fontFamily, - fontWeight = FontWeight(700.0.toInt()), - color = MainTextColor, - ) - Text( - text = "Personal life events", - style = MaterialTheme.typography.bodySmall, - fontSize = MaterialTheme.typography.labelMedium.fontSize, - color = MainTextColor - ) - } - Box( - modifier = Modifier - ) { - Row( - horizontalArrangement = Arrangement.spacedBy((-6).dp), - verticalAlignment = Alignment.CenterVertically - ) { - IconButton( - onClick = onNotificationsButtonClick, - ) { - Icon( - painter = painterResource(id = notifications_button), - contentDescription = "Notifications button", - tint = PrimaryColor - ) - } - IconButton( - onClick = onSettingsButtonClick, - ) { - Icon( - painter = painterResource(id = settings_button), - contentDescription = "Settings button", - tint = PrimaryColor - ) - } - } - } - } - } -} - -@Preview(showBackground = true) -@Composable -fun TopBarPreview() { - TopBar() -} +package com.f1rq.lifemap.components + +import android.graphics.drawable.shapes.Shape +import androidx.compose.foundation.layout.* +import androidx.compose.foundation.shape.RoundedCornerShape +import androidx.compose.material3.* +import androidx.compose.material3.CardDefaults +import androidx.compose.material3.Icon +import androidx.compose.material3.IconButton +import androidx.compose.material3.Text +import androidx.compose.material3.MaterialTheme +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.graphics.RectangleShape +import androidx.compose.ui.unit.dp +import androidx.compose.ui.res.painterResource +import androidx.compose.ui.text.font.FontWeight +import androidx.compose.ui.tooling.preview.Preview +import androidx.compose.ui.unit.Dp +import com.f1rq.lifemap.ui.theme.MainBG +import com.f1rq.lifemap.ui.theme.MainTextColor +import com.f1rq.lifemap.ui.theme.PrimaryColor +import com.f1rq.lifemap.R.drawable.notifications_button +import com.f1rq.lifemap.R.drawable.settings_button + +@Composable +fun TopBar( + modifier: Modifier = Modifier, + onNotificationsButtonClick: () -> Unit = {}, + onSettingsButtonClick: () -> Unit = {} +) { + Card( + modifier = Modifier + .fillMaxWidth(), + shape = RoundedCornerShape( + topStart = 0.dp, + topEnd = 0.dp, + bottomStart = 16.dp, + bottomEnd = 16.dp + ), + elevation = CardDefaults.cardElevation(defaultElevation = 6.dp), + colors = CardDefaults.cardColors( + containerColor = MainBG, + ) + ) { + Row( + modifier = Modifier + .padding( + start = 20.0.dp, + top = WindowInsets.statusBars.asPaddingValues().calculateTopPadding(), + end = 20.0.dp, + bottom = 15.0.dp + ), + verticalAlignment = Alignment.CenterVertically, + horizontalArrangement = Arrangement.SpaceBetween + ) { + Column( + modifier = Modifier + .weight(1f) + ) { + Text( + text = "LifeMap", + style = MaterialTheme.typography.titleMedium, + fontSize = MaterialTheme.typography.titleLarge.fontSize, + fontFamily = MaterialTheme.typography.titleLarge.fontFamily, + fontWeight = FontWeight(700.0.toInt()), + color = MainTextColor, + ) + Text( + text = "Personal life events", + style = MaterialTheme.typography.bodySmall, + fontSize = MaterialTheme.typography.labelMedium.fontSize, + color = MainTextColor + ) + } + Box( + modifier = Modifier + ) { + Row( + horizontalArrangement = Arrangement.spacedBy((-6).dp), + verticalAlignment = Alignment.CenterVertically + ) { + IconButton( + onClick = onNotificationsButtonClick, + ) { + Icon( + painter = painterResource(id = notifications_button), + contentDescription = "Notifications button", + tint = PrimaryColor + ) + } + IconButton( + onClick = onSettingsButtonClick, + ) { + Icon( + painter = painterResource(id = settings_button), + contentDescription = "Settings button", + tint = PrimaryColor + ) + } + } + } + } + } +} + +@Preview(showBackground = true) +@Composable +fun TopBarPreview() { + TopBar() +} diff --git a/app/src/main/java/com/f1rq/lifemap/screens/ListView.kt b/app/src/main/java/com/f1rq/lifemap/screens/ListView.kt index 4157a0a..52d9fdf 100644 --- a/app/src/main/java/com/f1rq/lifemap/screens/ListView.kt +++ b/app/src/main/java/com/f1rq/lifemap/screens/ListView.kt @@ -1,20 +1,20 @@ -package com.f1rq.lifemap.screens - -import androidx.compose.foundation.layout.Box -import androidx.compose.foundation.layout.fillMaxSize -import androidx.compose.foundation.layout.systemBarsPadding -import androidx.compose.material3.Text -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.Modifier - -@Composable -fun ListView(modifier: Modifier = Modifier) { - Box( - modifier = Modifier - .fillMaxSize(), - contentAlignment = Alignment.Center - ) { - Text("List view") - } +package com.f1rq.lifemap.screens + +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.systemBarsPadding +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier + +@Composable +fun ListView(modifier: Modifier = Modifier) { + Box( + modifier = Modifier + .fillMaxSize(), + contentAlignment = Alignment.Center + ) { + Text("List view") + } } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/screens/MapView.kt b/app/src/main/java/com/f1rq/lifemap/screens/MapView.kt index c58bc43..8e8f283 100644 --- a/app/src/main/java/com/f1rq/lifemap/screens/MapView.kt +++ b/app/src/main/java/com/f1rq/lifemap/screens/MapView.kt @@ -1,35 +1,35 @@ -package com.f1rq.lifemap.screens - -import androidx.compose.foundation.layout.Box -import androidx.compose.foundation.layout.fillMaxSize -import androidx.compose.material3.Text -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.Modifier -import androidx.compose.ui.tooling.preview.Preview -import com.f1rq.lifemap.components.AddEventCard - - -@Composable -fun MapView(modifier: Modifier = Modifier) { - Box( - modifier = Modifier - .fillMaxSize() - - ) { - Text( - text = "Map view", - modifier = Modifier.align(Alignment.Center) - ) - AddEventCard( - onCreateEventClick = {}, - modifier = Modifier.align(Alignment.BottomCenter) - ) - } -} - -@Preview -@Composable -fun MapViewPreview() { - MapView() +package com.f1rq.lifemap.screens + +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.tooling.preview.Preview +import com.f1rq.lifemap.components.AddEventCard + + +@Composable +fun MapView(modifier: Modifier = Modifier) { + Box( + modifier = Modifier + .fillMaxSize() + + ) { + Text( + text = "Map view", + modifier = Modifier.align(Alignment.Center) + ) + AddEventCard( + onCreateEventClick = {}, + modifier = Modifier.align(Alignment.BottomCenter) + ) + } +} + +@Preview +@Composable +fun MapViewPreview() { + MapView() } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/screens/NotificationsScreen.kt b/app/src/main/java/com/f1rq/lifemap/screens/NotificationsScreen.kt index 4b6512a..0160df9 100644 --- a/app/src/main/java/com/f1rq/lifemap/screens/NotificationsScreen.kt +++ b/app/src/main/java/com/f1rq/lifemap/screens/NotificationsScreen.kt @@ -1,39 +1,39 @@ -package com.f1rq.lifemap.screens - -import androidx.compose.foundation.layout.Arrangement -import androidx.compose.foundation.layout.Box -import androidx.compose.foundation.layout.Column -import androidx.compose.foundation.layout.fillMaxSize -import androidx.compose.foundation.layout.padding -import androidx.compose.material3.MaterialTheme -import androidx.compose.material3.Text -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.Modifier -import androidx.compose.ui.unit.dp -import com.f1rq.lifemap.ui.theme.MainTextColor - -@Composable -fun NotificationsScreen(modifier: Modifier = Modifier) { - Box( - modifier = Modifier - .fillMaxSize() - ) { - Column( - verticalArrangement = Arrangement.spacedBy(4.dp), - ) { - Text( - text = "Settings", - style = MaterialTheme.typography.titleMedium, - fontSize = MaterialTheme.typography.titleLarge.fontSize, - fontFamily = MaterialTheme.typography.titleLarge.fontFamily, - color = MainTextColor, - modifier = Modifier - .padding( - top = 24.dp, - start = 24.dp - ), - ) - } - } +package com.f1rq.lifemap.screens + +import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.padding +import androidx.compose.material3.MaterialTheme +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier +import androidx.compose.ui.unit.dp +import com.f1rq.lifemap.ui.theme.MainTextColor + +@Composable +fun NotificationsScreen(modifier: Modifier = Modifier) { + Box( + modifier = Modifier + .fillMaxSize() + ) { + Column( + verticalArrangement = Arrangement.spacedBy(4.dp), + ) { + Text( + text = "Settings", + style = MaterialTheme.typography.titleMedium, + fontSize = MaterialTheme.typography.titleLarge.fontSize, + fontFamily = MaterialTheme.typography.titleLarge.fontFamily, + color = MainTextColor, + modifier = Modifier + .padding( + top = 24.dp, + start = 24.dp + ), + ) + } + } } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/screens/SettingsScreen.kt b/app/src/main/java/com/f1rq/lifemap/screens/SettingsScreen.kt index 599fd9c..ead6b1b 100644 --- a/app/src/main/java/com/f1rq/lifemap/screens/SettingsScreen.kt +++ b/app/src/main/java/com/f1rq/lifemap/screens/SettingsScreen.kt @@ -1,78 +1,78 @@ -package com.f1rq.lifemap.screens - -import androidx.compose.foundation.layout.Arrangement -import androidx.compose.foundation.layout.Box -import androidx.compose.foundation.layout.Column -import androidx.compose.foundation.layout.fillMaxSize -import androidx.compose.foundation.layout.padding -import androidx.compose.material.icons.Icons -import androidx.compose.material.icons.automirrored.outlined.List -import androidx.compose.material.icons.filled.MailOutline -import androidx.compose.material.icons.filled.Notifications -import androidx.compose.material.icons.outlined.Email -import androidx.compose.material.icons.outlined.Notifications -import androidx.compose.material3.MaterialTheme -import androidx.compose.material3.Text -import androidx.compose.runtime.Composable -import androidx.compose.ui.Modifier -import androidx.compose.ui.unit.dp -import androidx.navigation.NavController -import com.f1rq.lifemap.components.SettingsLabel -import com.f1rq.lifemap.ui.theme.MainTextColor -import com.f1rq.lifemap.R.drawable.contact_icon -import com.f1rq.lifemap.R.drawable.feedback_icon - -@Composable -fun SettingsScreen(navController: NavController, modifier: Modifier = Modifier) { - Box( - modifier = Modifier - .fillMaxSize() - ) { - Column ( - verticalArrangement = Arrangement.spacedBy(4.dp), - ) { - Text( - text = "Settings", - style = MaterialTheme.typography.titleMedium, - fontSize = MaterialTheme.typography.titleLarge.fontSize, - fontFamily = MaterialTheme.typography.titleLarge.fontFamily, - color = MainTextColor, - modifier = Modifier - .padding( - top = 24.dp, - start = 24.dp - ), - ) - SettingsLabel( - text = "Notifications", - iconResource = Icons.Outlined.Notifications, - desc = "Notifications", - modifier = Modifier - .padding( - horizontal = 16.dp - ), - onClick = { navController.navigate("settings_notifications") } - ) - - SettingsLabel( - text = "Contact", - iconResource = Icons.Outlined.Email, - desc = "Contact us", - modifier = Modifier - .padding( - horizontal = 16.dp - ) - ) - - SettingsLabel( - text = "Report a bug", - iconResource = Icons.Outlined.Email, - desc = "Report a bug", - modifier = Modifier - .padding( - horizontal = 16.dp - ) - ) - } - } +package com.f1rq.lifemap.screens + +import androidx.compose.foundation.layout.Arrangement +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.Column +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.foundation.layout.padding +import androidx.compose.material.icons.Icons +import androidx.compose.material.icons.automirrored.outlined.List +import androidx.compose.material.icons.filled.MailOutline +import androidx.compose.material.icons.filled.Notifications +import androidx.compose.material.icons.outlined.Email +import androidx.compose.material.icons.outlined.Notifications +import androidx.compose.material3.MaterialTheme +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.ui.Modifier +import androidx.compose.ui.unit.dp +import androidx.navigation.NavController +import com.f1rq.lifemap.components.SettingsLabel +import com.f1rq.lifemap.ui.theme.MainTextColor +import com.f1rq.lifemap.R.drawable.contact_icon +import com.f1rq.lifemap.R.drawable.feedback_icon + +@Composable +fun SettingsScreen(navController: NavController, modifier: Modifier = Modifier) { + Box( + modifier = Modifier + .fillMaxSize() + ) { + Column ( + verticalArrangement = Arrangement.spacedBy(4.dp), + ) { + Text( + text = "Settings", + style = MaterialTheme.typography.titleMedium, + fontSize = MaterialTheme.typography.titleLarge.fontSize, + fontFamily = MaterialTheme.typography.titleLarge.fontFamily, + color = MainTextColor, + modifier = Modifier + .padding( + top = 24.dp, + start = 24.dp + ), + ) + SettingsLabel( + text = "Notifications", + iconResource = Icons.Outlined.Notifications, + desc = "Notifications", + modifier = Modifier + .padding( + horizontal = 16.dp + ), + onClick = { navController.navigate("settings_notifications") } + ) + + SettingsLabel( + text = "Contact", + iconResource = Icons.Outlined.Email, + desc = "Contact us", + modifier = Modifier + .padding( + horizontal = 16.dp + ) + ) + + SettingsLabel( + text = "Report a bug", + iconResource = Icons.Outlined.Email, + desc = "Report a bug", + modifier = Modifier + .padding( + horizontal = 16.dp + ) + ) + } + } } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/screens/settingsScreens/SettingsNotificationsScreen.kt b/app/src/main/java/com/f1rq/lifemap/screens/settingsScreens/SettingsNotificationsScreen.kt index c394e0b..8437da8 100644 --- a/app/src/main/java/com/f1rq/lifemap/screens/settingsScreens/SettingsNotificationsScreen.kt +++ b/app/src/main/java/com/f1rq/lifemap/screens/settingsScreens/SettingsNotificationsScreen.kt @@ -1,19 +1,19 @@ -package com.f1rq.lifemap.screens.settingsScreens - -import androidx.compose.foundation.layout.Box -import androidx.compose.foundation.layout.fillMaxSize -import androidx.compose.material3.Text -import androidx.compose.runtime.Composable -import androidx.compose.ui.Alignment -import androidx.compose.ui.Modifier - -@Composable -fun SettingsNotificationsScreen(modifier: Modifier = Modifier) { - Box( - modifier = Modifier - .fillMaxSize(), - contentAlignment = Alignment.Center - ) { - Text("Notifications settings") - } +package com.f1rq.lifemap.screens.settingsScreens + +import androidx.compose.foundation.layout.Box +import androidx.compose.foundation.layout.fillMaxSize +import androidx.compose.material3.Text +import androidx.compose.runtime.Composable +import androidx.compose.ui.Alignment +import androidx.compose.ui.Modifier + +@Composable +fun SettingsNotificationsScreen(modifier: Modifier = Modifier) { + Box( + modifier = Modifier + .fillMaxSize(), + contentAlignment = Alignment.Center + ) { + Text("Notifications settings") + } } \ No newline at end of file diff --git a/app/src/main/java/com/f1rq/lifemap/ui/theme/Color.kt b/app/src/main/java/com/f1rq/lifemap/ui/theme/Color.kt index 7c75060..84d3936 100644 --- a/app/src/main/java/com/f1rq/lifemap/ui/theme/Color.kt +++ b/app/src/main/java/com/f1rq/lifemap/ui/theme/Color.kt @@ -1,12 +1,12 @@ -package com.f1rq.lifemap.ui.theme - -import androidx.compose.ui.graphics.Color - -val MainBG = Color(0xFFECECEC) -val SecondaryBG = Color(0xFFDDDDDD) -val PrimaryColor = Color(0xFF49454F) -val MainTextColor = Color(0xFF1D1B20) - -val ActiveNavColor = Color(0xFFDDDDDD) -val InactiveNavColor = Color.Transparent - +package com.f1rq.lifemap.ui.theme + +import androidx.compose.ui.graphics.Color + +val MainBG = Color(0xFFECECEC) +val SecondaryBG = Color(0xFFDDDDDD) +val PrimaryColor = Color(0xFF49454F) +val MainTextColor = Color(0xFF1D1B20) + +val ActiveNavColor = Color(0xFFDDDDDD) +val InactiveNavColor = Color.Transparent + diff --git a/app/src/main/res/drawable/add_event_button.xml b/app/src/main/res/drawable/add_event_button.xml index c6de098..12a150b 100644 --- a/app/src/main/res/drawable/add_event_button.xml +++ b/app/src/main/res/drawable/add_event_button.xml @@ -1,9 +1,9 @@ - - - + + + diff --git a/app/src/main/res/drawable/contact_icon.xml b/app/src/main/res/drawable/contact_icon.xml index 7c88f37..59a09a3 100644 --- a/app/src/main/res/drawable/contact_icon.xml +++ b/app/src/main/res/drawable/contact_icon.xml @@ -1,5 +1,5 @@ - - - - - + + + + + diff --git a/app/src/main/res/drawable/feedback_icon.xml b/app/src/main/res/drawable/feedback_icon.xml index d23b613..f0f98e7 100644 --- a/app/src/main/res/drawable/feedback_icon.xml +++ b/app/src/main/res/drawable/feedback_icon.xml @@ -1,5 +1,5 @@ - - - - - + + + + + diff --git a/app/src/main/res/drawable/navbar_listview_button.xml b/app/src/main/res/drawable/navbar_listview_button.xml index c2a5cda..d68d5d1 100644 --- a/app/src/main/res/drawable/navbar_listview_button.xml +++ b/app/src/main/res/drawable/navbar_listview_button.xml @@ -1,9 +1,9 @@ - - - + + + diff --git a/app/src/main/res/drawable/navbar_mapview_button.xml b/app/src/main/res/drawable/navbar_mapview_button.xml index 5c9e21d..99ee2a8 100644 --- a/app/src/main/res/drawable/navbar_mapview_button.xml +++ b/app/src/main/res/drawable/navbar_mapview_button.xml @@ -1,9 +1,9 @@ - - - + + + diff --git a/app/src/main/res/drawable/notifications_button.xml b/app/src/main/res/drawable/notifications_button.xml index 507a8d3..bec2793 100644 --- a/app/src/main/res/drawable/notifications_button.xml +++ b/app/src/main/res/drawable/notifications_button.xml @@ -1,9 +1,9 @@ - - - + + + diff --git a/app/src/main/res/drawable/settings_button.xml b/app/src/main/res/drawable/settings_button.xml index b7814db..ad3e0af 100644 --- a/app/src/main/res/drawable/settings_button.xml +++ b/app/src/main/res/drawable/settings_button.xml @@ -1,9 +1,9 @@ - - - + + + diff --git a/app/src/main/ui-packages/add_event/add_event.json b/app/src/main/ui-packages/add_event/add_event.json index a23c724..e428c4e 100644 --- a/app/src/main/ui-packages/add_event/add_event.json +++ b/app/src/main/ui-packages/add_event/add_event.json @@ -1,360 +1,360 @@ -{ - "name": "add_event", - "version": 33, - "source-key": { - "type": "figma", - "file": "7RzB5mC9Qj82hGEbAM11GM", - "node": "76:4", - "version": "2205685389783780702", - "component-id": "7df95c19403de2b4b8280d6464fc1c747d4921a5" - }, - "default": "Add event", - "design": { - "atoms": [ - { - "type": "group", - "id": "top_level", - "root": "true" - }, - { - "type": "group", - "id": "top_level_synth" - }, - { - "type": "group", - "id": "Background" - }, - { - "type": "group", - "id": "Content" - }, - { - "type": "group", - "id": "Title" - }, - { - "type": "group", - "id": "FAB" - }, - { - "type": "text", - "id": "LifeMap title" - }, - { - "type": "text", - "id": "subtitle" - }, - { - "type": "group", - "id": "state-layer" - }, - { - "type": "group", - "id": "icon" - }, - { - "type": "vector", - "id": "icon1" - }, - { - "type": "group", - "id": "layer" - } - ], - "modes": { - "Add event": { - "rules": [ - { - "id": "top_level", - "is-structured": false, - "children": [ - "top_level_synth", - "Background" - ], - "clip-content": false - }, - { - "id": "top_level_synth", - "opacity": 100.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "main-axis-align": "start", - "cross-axis-align": "start", - "children": [ - "Content" - ], - "clip-content": false - }, - { - "id": "Background", - "border-radius": 12.0, - "stroke-width": 1.0, - "stroke-color": { - "alpha": 1.0, - "hue": 269.99999999999994, - "saturation": 0.057692307692307626, - "value": 0.8156862745098039 - }, - "is-structured": false, - "children": [ - "layer" - ], - "background-color": { - "alpha": 1.0, - "hue": 0.0, - "saturation": 0.0, - "value": 0.9215686274509803 - } - }, - { - "id": "Content", - "padding": 20.0, - "border-radius": 12.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 375.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 82.0 - } - }, - "arrangement": "row", - "main-axis-align": "space-between", - "children": [ - "Title", - "FAB" - ] - }, - { - "id": "Title", - "padding": { - "top": 5.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 156.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 48.0 - } - }, - "cross-axis-align": "start", - "children": [ - "LifeMap title", - "subtitle" - ], - "item-spacing": -1.0, - "clip-content": false - }, - { - "id": "FAB", - "border-radius": 16.0, - "drop-shadow": { - "color": { - "alpha": 0.2980392156862745, - "hue": 0.0, - "saturation": 0.0, - "value": 0.0 - }, - "blur": 3.0, - "offset-x": 0.0, - "offset-y": 1.0, - "spread": 0.0, - "blend-mode": "normal" - }, - "tap-handler": "$on add button tapped", - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "children": [ - "state-layer" - ], - "background-color": { - "alpha": 1.0, - "hue": 0.0, - "saturation": 0.0, - "value": 0.9215686274509803 - } - }, - { - "id": "LifeMap title", - "font-weight": "^md.sys.typescale.title-large.weight", - "color": "^md.sys.color.on-surface", - "text-content": "Add event", - "overflow": "visible", - "text-align": "left", - "text-size": "^md.sys.typescale.title-large.size", - "letter-spacing": "^md.sys.typescale.title-large.tracking", - "line-height": "^md.sys.typescale.title-large.line-height", - "typeface": "^md.sys.typescale.title-large.font" - }, - { - "id": "subtitle", - "font-weight": "^md.sys.typescale.label-medium.weight", - "color": "^md.sys.color.on-surface", - "text-content": "With localization, date etc.", - "overflow": "visible", - "text-align": "left", - "text-size": "^md.sys.typescale.label-medium.size", - "letter-spacing": "^md.sys.typescale.label-medium.tracking", - "line-height": "^md.sys.typescale.label-medium.line-height", - "typeface": "^md.sys.typescale.label-medium.font" - }, - { - "id": "state-layer", - "padding": 16.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "children": [ - "icon" - ], - "clip-content": false - }, - { - "id": "icon", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - } - }, - "is-structured": false, - "children": [ - "icon1" - ], - "clip-content": false - }, - { - "id": "icon1", - "margin": 3.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - } - }, - "vector-content": "icon.svg" - }, - { - "id": "layer", - "padding": 10.0, - "item-spacing": 10.0, - "clip-content": false - } - ] - } - } - }, - "parameters": { - "on add button tapped": { - "data-type": "void-callback", - "required": false, - "description": "" - } - }, - "ambients": { - "md.sys.color.on-surface": { - "data-type": "color", - "description": null - }, - "md.sys.typescale.title-large.font": { - "data-type": "typeface", - "description": null - }, - "md.sys.typescale.title-large.weight": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.title-large.size": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.title-large.tracking": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.title-large.line-height": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.font": { - "data-type": "typeface", - "description": null - }, - "md.sys.typescale.label-medium.weight": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.size": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.tracking": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.line-height": { - "data-type": "double", - "description": null - } - }, - "previews": [ - { - "design": "Add event", - "size": { - "width": 375.0, - "height": 82.0 - }, - "ambients": { - "md.sys.color.on-surface": { - "alpha": 1.0, - "hue": 264.0, - "saturation": 0.15625, - "value": 0.12549019607843137 - }, - "md.sys.typescale.title-large.weight": 400.0, - "md.sys.typescale.title-large.size": 22.0, - "md.sys.typescale.title-large.line-height": 1.272727279663086, - "md.sys.typescale.label-medium.weight": 500.0, - "md.sys.typescale.label-medium.size": 12.0, - "md.sys.typescale.label-medium.tracking": 0.5, - "md.sys.typescale.label-medium.line-height": 1.3333332824707032 - } - } - ], - "adin-component-search-paths": [], - "image-search-paths": [], - "vector-search-paths": [] +{ + "name": "add_event", + "version": 33, + "source-key": { + "type": "figma", + "file": "7RzB5mC9Qj82hGEbAM11GM", + "node": "76:4", + "version": "2205685389783780702", + "component-id": "7df95c19403de2b4b8280d6464fc1c747d4921a5" + }, + "default": "Add event", + "design": { + "atoms": [ + { + "type": "group", + "id": "top_level", + "root": "true" + }, + { + "type": "group", + "id": "top_level_synth" + }, + { + "type": "group", + "id": "Background" + }, + { + "type": "group", + "id": "Content" + }, + { + "type": "group", + "id": "Title" + }, + { + "type": "group", + "id": "FAB" + }, + { + "type": "text", + "id": "LifeMap title" + }, + { + "type": "text", + "id": "subtitle" + }, + { + "type": "group", + "id": "state-layer" + }, + { + "type": "group", + "id": "icon" + }, + { + "type": "vector", + "id": "icon1" + }, + { + "type": "group", + "id": "layer" + } + ], + "modes": { + "Add event": { + "rules": [ + { + "id": "top_level", + "is-structured": false, + "children": [ + "top_level_synth", + "Background" + ], + "clip-content": false + }, + { + "id": "top_level_synth", + "opacity": 100.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "main-axis-align": "start", + "cross-axis-align": "start", + "children": [ + "Content" + ], + "clip-content": false + }, + { + "id": "Background", + "border-radius": 12.0, + "stroke-width": 1.0, + "stroke-color": { + "alpha": 1.0, + "hue": 269.99999999999994, + "saturation": 0.057692307692307626, + "value": 0.8156862745098039 + }, + "is-structured": false, + "children": [ + "layer" + ], + "background-color": { + "alpha": 1.0, + "hue": 0.0, + "saturation": 0.0, + "value": 0.9215686274509803 + } + }, + { + "id": "Content", + "padding": 20.0, + "border-radius": 12.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 375.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 82.0 + } + }, + "arrangement": "row", + "main-axis-align": "space-between", + "children": [ + "Title", + "FAB" + ] + }, + { + "id": "Title", + "padding": { + "top": 5.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 156.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 48.0 + } + }, + "cross-axis-align": "start", + "children": [ + "LifeMap title", + "subtitle" + ], + "item-spacing": -1.0, + "clip-content": false + }, + { + "id": "FAB", + "border-radius": 16.0, + "drop-shadow": { + "color": { + "alpha": 0.2980392156862745, + "hue": 0.0, + "saturation": 0.0, + "value": 0.0 + }, + "blur": 3.0, + "offset-x": 0.0, + "offset-y": 1.0, + "spread": 0.0, + "blend-mode": "normal" + }, + "tap-handler": "$on add button tapped", + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "children": [ + "state-layer" + ], + "background-color": { + "alpha": 1.0, + "hue": 0.0, + "saturation": 0.0, + "value": 0.9215686274509803 + } + }, + { + "id": "LifeMap title", + "font-weight": "^md.sys.typescale.title-large.weight", + "color": "^md.sys.color.on-surface", + "text-content": "Add event", + "overflow": "visible", + "text-align": "left", + "text-size": "^md.sys.typescale.title-large.size", + "letter-spacing": "^md.sys.typescale.title-large.tracking", + "line-height": "^md.sys.typescale.title-large.line-height", + "typeface": "^md.sys.typescale.title-large.font" + }, + { + "id": "subtitle", + "font-weight": "^md.sys.typescale.label-medium.weight", + "color": "^md.sys.color.on-surface", + "text-content": "With localization, date etc.", + "overflow": "visible", + "text-align": "left", + "text-size": "^md.sys.typescale.label-medium.size", + "letter-spacing": "^md.sys.typescale.label-medium.tracking", + "line-height": "^md.sys.typescale.label-medium.line-height", + "typeface": "^md.sys.typescale.label-medium.font" + }, + { + "id": "state-layer", + "padding": 16.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "children": [ + "icon" + ], + "clip-content": false + }, + { + "id": "icon", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + } + }, + "is-structured": false, + "children": [ + "icon1" + ], + "clip-content": false + }, + { + "id": "icon1", + "margin": 3.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + } + }, + "vector-content": "icon.svg" + }, + { + "id": "layer", + "padding": 10.0, + "item-spacing": 10.0, + "clip-content": false + } + ] + } + } + }, + "parameters": { + "on add button tapped": { + "data-type": "void-callback", + "required": false, + "description": "" + } + }, + "ambients": { + "md.sys.color.on-surface": { + "data-type": "color", + "description": null + }, + "md.sys.typescale.title-large.font": { + "data-type": "typeface", + "description": null + }, + "md.sys.typescale.title-large.weight": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.title-large.size": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.title-large.tracking": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.title-large.line-height": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.font": { + "data-type": "typeface", + "description": null + }, + "md.sys.typescale.label-medium.weight": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.size": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.tracking": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.line-height": { + "data-type": "double", + "description": null + } + }, + "previews": [ + { + "design": "Add event", + "size": { + "width": 375.0, + "height": 82.0 + }, + "ambients": { + "md.sys.color.on-surface": { + "alpha": 1.0, + "hue": 264.0, + "saturation": 0.15625, + "value": 0.12549019607843137 + }, + "md.sys.typescale.title-large.weight": 400.0, + "md.sys.typescale.title-large.size": 22.0, + "md.sys.typescale.title-large.line-height": 1.272727279663086, + "md.sys.typescale.label-medium.weight": 500.0, + "md.sys.typescale.label-medium.size": 12.0, + "md.sys.typescale.label-medium.tracking": 0.5, + "md.sys.typescale.label-medium.line-height": 1.3333332824707032 + } + } + ], + "adin-component-search-paths": [], + "image-search-paths": [], + "vector-search-paths": [] } \ No newline at end of file diff --git a/app/src/main/ui-packages/add_event/config.json b/app/src/main/ui-packages/add_event/config.json index dfafd61..a03840d 100644 --- a/app/src/main/ui-packages/add_event/config.json +++ b/app/src/main/ui-packages/add_event/config.json @@ -1,4 +1,4 @@ -{ - "preview-theme": "androidx.compose.material3.MaterialTheme", - "ambient-translations-path": "app/src/main/ui-package-resources/style-mappings/m3_design_kit.json" +{ + "preview-theme": "androidx.compose.material3.MaterialTheme", + "ambient-translations-path": "app/src/main/ui-package-resources/style-mappings/m3_design_kit.json" } \ No newline at end of file diff --git a/app/src/main/ui-packages/add_event/icon.svg b/app/src/main/ui-packages/add_event/icon.svg index af47706..536970b 100644 --- a/app/src/main/ui-packages/add_event/icon.svg +++ b/app/src/main/ui-packages/add_event/icon.svg @@ -1,3 +1,3 @@ - - - + + + diff --git a/app/src/main/ui-packages/navigation_bar/navigation_bar.json b/app/src/main/ui-packages/navigation_bar/navigation_bar.json index 0adb41b..e0cf4f7 100644 --- a/app/src/main/ui-packages/navigation_bar/navigation_bar.json +++ b/app/src/main/ui-packages/navigation_bar/navigation_bar.json @@ -1,332 +1,332 @@ -{ - "name": "navigation_bar", - "version": 33, - "source-key": { - "type": "figma", - "file": "7RzB5mC9Qj82hGEbAM11GM", - "node": "38:3", - "version": "2205685389783780702", - "component-id": "915162a5cdf4f7f91ace42d239b4d1faf0d5c6e7" - }, - "default": "Navigation bar", - "documentation": "bottom nav bar", - "design": { - "atoms": [ - { - "type": "group", - "id": "top_level", - "root": "true" - }, - { - "type": "group", - "id": "world view" - }, - { - "type": "group", - "id": "list view" - }, - { - "type": "group", - "id": "icon-container" - }, - { - "type": "group", - "id": "state-layer" - }, - { - "type": "group", - "id": "Frame" - }, - { - "type": "vector", - "id": "Vector" - }, - { - "type": "group", - "id": "icon-container1" - }, - { - "type": "group", - "id": "state-layer1" - }, - { - "type": "group", - "id": "Frame1" - }, - { - "type": "vector", - "id": "Vector1" - } - ], - "modes": { - "Navigation bar": { - "rules": [ - { - "id": "top_level", - "padding": { - "left": 8.0, - "right": 8.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "cross-axis-align": "end", - "children": [ - "world view", - "list view" - ], - "background-color": { - "alpha": 1.0, - "hue": 0.0, - "saturation": 0.0, - "value": 0.9215686274509803 - }, - "clip-content": false - }, - { - "id": "world view", - "padding": { - "top": 12.0, - "bottom": 16.0 - }, - "tap-handler": "$on world view tapped", - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "children": [ - "icon-container" - ], - "item-spacing": 4.0, - "clip-content": false - }, - { - "id": "list view", - "padding": { - "top": 12.0, - "bottom": 16.0 - }, - "tap-handler": "$on list view tapped", - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "children": [ - "icon-container1" - ], - "item-spacing": 4.0, - "clip-content": false - }, - { - "id": "icon-container", - "border-radius": 16.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "children": [ - "state-layer" - ] - }, - { - "id": "state-layer", - "padding": { - "left": 20.0, - "top": 4.0, - "right": 20.0, - "bottom": 4.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 48.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 48.0 - } - }, - "arrangement": "row", - "children": [ - "Frame" - ], - "background-color": "$world view background color", - "clip-content": false - }, - { - "id": "Frame", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - } - }, - "is-structured": false, - "children": [ - "Vector" - ] - }, - { - "id": "Vector", - "margin": 2.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - } - }, - "vector-content": "vector.svg" - }, - { - "id": "icon-container1", - "border-radius": 16.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "children": [ - "state-layer1" - ] - }, - { - "id": "state-layer1", - "padding": { - "left": 20.0, - "top": 4.0, - "right": 20.0, - "bottom": 4.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 48.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 48.0 - } - }, - "arrangement": "row", - "children": [ - "Frame1" - ], - "background-color": "$list view background color", - "clip-content": false - }, - { - "id": "Frame1", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - } - }, - "is-structured": false, - "children": [ - "Vector1" - ] - }, - { - "id": "Vector1", - "margin": { - "left": 2.5, - "top": 4.5, - "right": 3.0, - "bottom": 4.5 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - } - }, - "vector-content": "vector1.svg" - } - ] - } - } - }, - "parameters": { - "on world view tapped": { - "data-type": "void-callback", - "required": false, - "description": "" - }, - "on list view tapped": { - "data-type": "void-callback", - "required": false, - "description": "" - }, - "world view background color": { - "data-type": "color", - "required": false, - "description": "" - }, - "list view background color": { - "data-type": "color", - "required": false, - "description": "" - } - }, - "previews": [ - { - "design": "Navigation bar", - "size": { - "width": 375.0, - "height": 76.0 - }, - "parameters": { - "world view background color": { - "alpha": 1.0, - "hue": 0.0, - "saturation": 0.0, - "value": 0.8666666666666667 - } - } - } - ], - "adin-component-search-paths": [], - "image-search-paths": [], - "vector-search-paths": [] +{ + "name": "navigation_bar", + "version": 33, + "source-key": { + "type": "figma", + "file": "7RzB5mC9Qj82hGEbAM11GM", + "node": "38:3", + "version": "2205685389783780702", + "component-id": "915162a5cdf4f7f91ace42d239b4d1faf0d5c6e7" + }, + "default": "Navigation bar", + "documentation": "bottom nav bar", + "design": { + "atoms": [ + { + "type": "group", + "id": "top_level", + "root": "true" + }, + { + "type": "group", + "id": "world view" + }, + { + "type": "group", + "id": "list view" + }, + { + "type": "group", + "id": "icon-container" + }, + { + "type": "group", + "id": "state-layer" + }, + { + "type": "group", + "id": "Frame" + }, + { + "type": "vector", + "id": "Vector" + }, + { + "type": "group", + "id": "icon-container1" + }, + { + "type": "group", + "id": "state-layer1" + }, + { + "type": "group", + "id": "Frame1" + }, + { + "type": "vector", + "id": "Vector1" + } + ], + "modes": { + "Navigation bar": { + "rules": [ + { + "id": "top_level", + "padding": { + "left": 8.0, + "right": 8.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "cross-axis-align": "end", + "children": [ + "world view", + "list view" + ], + "background-color": { + "alpha": 1.0, + "hue": 0.0, + "saturation": 0.0, + "value": 0.9215686274509803 + }, + "clip-content": false + }, + { + "id": "world view", + "padding": { + "top": 12.0, + "bottom": 16.0 + }, + "tap-handler": "$on world view tapped", + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "children": [ + "icon-container" + ], + "item-spacing": 4.0, + "clip-content": false + }, + { + "id": "list view", + "padding": { + "top": 12.0, + "bottom": 16.0 + }, + "tap-handler": "$on list view tapped", + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "children": [ + "icon-container1" + ], + "item-spacing": 4.0, + "clip-content": false + }, + { + "id": "icon-container", + "border-radius": 16.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "children": [ + "state-layer" + ] + }, + { + "id": "state-layer", + "padding": { + "left": 20.0, + "top": 4.0, + "right": 20.0, + "bottom": 4.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 48.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 48.0 + } + }, + "arrangement": "row", + "children": [ + "Frame" + ], + "background-color": "$world view background color", + "clip-content": false + }, + { + "id": "Frame", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + } + }, + "is-structured": false, + "children": [ + "Vector" + ] + }, + { + "id": "Vector", + "margin": 2.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + } + }, + "vector-content": "vector.svg" + }, + { + "id": "icon-container1", + "border-radius": 16.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "children": [ + "state-layer1" + ] + }, + { + "id": "state-layer1", + "padding": { + "left": 20.0, + "top": 4.0, + "right": 20.0, + "bottom": 4.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 48.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 48.0 + } + }, + "arrangement": "row", + "children": [ + "Frame1" + ], + "background-color": "$list view background color", + "clip-content": false + }, + { + "id": "Frame1", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + } + }, + "is-structured": false, + "children": [ + "Vector1" + ] + }, + { + "id": "Vector1", + "margin": { + "left": 2.5, + "top": 4.5, + "right": 3.0, + "bottom": 4.5 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + } + }, + "vector-content": "vector1.svg" + } + ] + } + } + }, + "parameters": { + "on world view tapped": { + "data-type": "void-callback", + "required": false, + "description": "" + }, + "on list view tapped": { + "data-type": "void-callback", + "required": false, + "description": "" + }, + "world view background color": { + "data-type": "color", + "required": false, + "description": "" + }, + "list view background color": { + "data-type": "color", + "required": false, + "description": "" + } + }, + "previews": [ + { + "design": "Navigation bar", + "size": { + "width": 375.0, + "height": 76.0 + }, + "parameters": { + "world view background color": { + "alpha": 1.0, + "hue": 0.0, + "saturation": 0.0, + "value": 0.8666666666666667 + } + } + } + ], + "adin-component-search-paths": [], + "image-search-paths": [], + "vector-search-paths": [] } \ No newline at end of file diff --git a/app/src/main/ui-packages/navigation_bar/vector.svg b/app/src/main/ui-packages/navigation_bar/vector.svg index cc73ebd..5a13095 100644 --- a/app/src/main/ui-packages/navigation_bar/vector.svg +++ b/app/src/main/ui-packages/navigation_bar/vector.svg @@ -1,3 +1,3 @@ - - - + + + diff --git a/app/src/main/ui-packages/navigation_bar/vector1.svg b/app/src/main/ui-packages/navigation_bar/vector1.svg index 4c4782e..0dfaa88 100644 --- a/app/src/main/ui-packages/navigation_bar/vector1.svg +++ b/app/src/main/ui-packages/navigation_bar/vector1.svg @@ -1,3 +1,3 @@ - - - + + + diff --git a/app/src/main/ui-packages/top_app_bar/config.json b/app/src/main/ui-packages/top_app_bar/config.json index dfafd61..a03840d 100644 --- a/app/src/main/ui-packages/top_app_bar/config.json +++ b/app/src/main/ui-packages/top_app_bar/config.json @@ -1,4 +1,4 @@ -{ - "preview-theme": "androidx.compose.material3.MaterialTheme", - "ambient-translations-path": "app/src/main/ui-package-resources/style-mappings/m3_design_kit.json" +{ + "preview-theme": "androidx.compose.material3.MaterialTheme", + "ambient-translations-path": "app/src/main/ui-package-resources/style-mappings/m3_design_kit.json" } \ No newline at end of file diff --git a/app/src/main/ui-packages/top_app_bar/icon.svg b/app/src/main/ui-packages/top_app_bar/icon.svg index fc358a8..e25d11a 100644 --- a/app/src/main/ui-packages/top_app_bar/icon.svg +++ b/app/src/main/ui-packages/top_app_bar/icon.svg @@ -1,3 +1,3 @@ - - - + + + diff --git a/app/src/main/ui-packages/top_app_bar/icon1.svg b/app/src/main/ui-packages/top_app_bar/icon1.svg index 176fd23..1f73e59 100644 --- a/app/src/main/ui-packages/top_app_bar/icon1.svg +++ b/app/src/main/ui-packages/top_app_bar/icon1.svg @@ -1,3 +1,3 @@ - - - + + + diff --git a/app/src/main/ui-packages/top_app_bar/top_app_bar.json b/app/src/main/ui-packages/top_app_bar/top_app_bar.json index 72094ef..afb9390 100644 --- a/app/src/main/ui-packages/top_app_bar/top_app_bar.json +++ b/app/src/main/ui-packages/top_app_bar/top_app_bar.json @@ -1,457 +1,457 @@ -{ - "name": "top_app_bar", - "version": 33, - "source-key": { - "type": "figma", - "file": "7RzB5mC9Qj82hGEbAM11GM", - "node": "71:3", - "version": "2205685389783780702", - "component-id": "be1e47a9eb28efdd3c5b0590ec33e84c60626aa5" - }, - "default": "Top app bar", - "design": { - "atoms": [ - { - "type": "group", - "id": "top_level", - "root": "true" - }, - { - "type": "group", - "id": "Title" - }, - { - "type": "group", - "id": "Buttons" - }, - { - "type": "text", - "id": "LifeMap title" - }, - { - "type": "text", - "id": "subtitle" - }, - { - "type": "group", - "id": "Notifications icon" - }, - { - "type": "group", - "id": "Settings icon" - }, - { - "type": "group", - "id": "container" - }, - { - "type": "group", - "id": "state-layer" - }, - { - "type": "group", - "id": "Icon" - }, - { - "type": "vector", - "id": "icon" - }, - { - "type": "group", - "id": "container1" - }, - { - "type": "group", - "id": "state-layer1" - }, - { - "type": "group", - "id": "Icon1" - }, - { - "type": "vector", - "id": "icon1" - } - ], - "modes": { - "Top app bar": { - "rules": [ - { - "id": "top_level", - "padding": { - "left": 20.0, - "top": 55.0, - "right": 20.0, - "bottom": 20.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "stroke-alignment": "center", - "arrangement": "row", - "main-axis-align": "space-between", - "children": [ - "Title", - "Buttons" - ], - "background-color": { - "alpha": 1.0, - "hue": 0.0, - "saturation": 0.0, - "value": 0.9215686274509803 - }, - "clip-content": false - }, - { - "id": "Title", - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "cross-axis-align": "start", - "children": [ - "LifeMap title", - "subtitle" - ], - "item-spacing": -1.0, - "clip-content": false - }, - { - "id": "Buttons", - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "main-axis-align": "start", - "children": [ - "Notifications icon", - "Settings icon" - ], - "clip-content": false - }, - { - "id": "LifeMap title", - "font-weight": "^md.sys.typescale.title-large.weight", - "color": "^md.sys.color.on-surface", - "annotated-text-content": { - "text": "LifeMap", - "annotated-text-span-list": [ - { - "span-start": 0, - "span-length": 7, - "annotated-text-style": { - "font-weight": 700.0, - "text-size": 22.0, - "letter-spacing": 0.0, - "line-height": 1.272727279663086, - "typeface": "Roboto" - } - } - ] - }, - "overflow": "visible", - "text-align": "left", - "text-size": "^md.sys.typescale.title-large.size", - "letter-spacing": "^md.sys.typescale.title-large.tracking", - "line-height": "^md.sys.typescale.title-large.line-height", - "typeface": "^md.sys.typescale.title-large.font" - }, - { - "id": "subtitle", - "font-weight": "^md.sys.typescale.label-medium.weight", - "color": "^md.sys.color.on-surface", - "text-content": "Personal life events", - "overflow": "visible", - "text-align": "left", - "text-size": "^md.sys.typescale.label-medium.size", - "letter-spacing": "^md.sys.typescale.label-medium.tracking", - "line-height": "^md.sys.typescale.label-medium.line-height", - "typeface": "^md.sys.typescale.label-medium.font" - }, - { - "id": "Notifications icon", - "tap-handler": "$on notifications icon tapped", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 32.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 32.0 - } - }, - "children": [ - "container" - ], - "item-spacing": 10.0, - "clip-content": false - }, - { - "id": "Settings icon", - "tap-handler": "$on settings icon tapped", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 32.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 32.0 - } - }, - "children": [ - "container1" - ], - "item-spacing": 10.0, - "clip-content": false - }, - { - "id": "container", - "border-radius": 100.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "children": [ - "state-layer" - ], - "item-spacing": 10.0 - }, - { - "id": "state-layer", - "padding": 8.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "children": [ - "Icon" - ], - "item-spacing": 10.0, - "clip-content": false - }, - { - "id": "Icon", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - } - }, - "is-structured": false, - "children": [ - "icon" - ] - }, - { - "id": "icon", - "margin": { - "left": 4.0, - "top": 2.0, - "right": 4.0, - "bottom": 2.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - } - }, - "vector-content": "icon.svg" - }, - { - "id": "container1", - "border-radius": 100.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "children": [ - "state-layer1" - ], - "item-spacing": 10.0 - }, - { - "id": "state-layer1", - "padding": 8.0, - "size-constraints": { - "width-constraints": { - "sizing-mode": "shrink" - }, - "height-constraints": { - "sizing-mode": "shrink" - } - }, - "arrangement": "row", - "children": [ - "Icon1" - ], - "item-spacing": 10.0, - "clip-content": false - }, - { - "id": "Icon1", - "size-constraints": { - "width-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - }, - "height-constraints": { - "sizing-mode": "fixed", - "value": 24.0 - } - }, - "is-structured": false, - "children": [ - "icon1" - ] - }, - { - "id": "icon1", - "margin": { - "left": 2.270660400390625, - "top": 2.0, - "right": 2.2706756591796875, - "bottom": 2.0 - }, - "size-constraints": { - "width-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - }, - "height-constraints": { - "sizing-mode": "proportional", - "value": 1.0 - } - }, - "vector-content": "icon1.svg" - } - ] - } - } - }, - "parameters": { - "on notifications icon tapped": { - "data-type": "void-callback", - "required": false, - "description": "" - }, - "on settings icon tapped": { - "data-type": "void-callback", - "required": false, - "description": "" - } - }, - "ambients": { - "md.sys.color.on-surface": { - "data-type": "color", - "description": null - }, - "md.sys.typescale.title-large.font": { - "data-type": "typeface", - "description": null - }, - "md.sys.typescale.title-large.weight": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.title-large.size": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.title-large.tracking": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.title-large.line-height": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.font": { - "data-type": "typeface", - "description": null - }, - "md.sys.typescale.label-medium.weight": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.size": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.tracking": { - "data-type": "double", - "description": null - }, - "md.sys.typescale.label-medium.line-height": { - "data-type": "double", - "description": null - } - }, - "previews": [ - { - "design": "Top app bar", - "size": { - "width": 375.0, - "height": 118.0 - }, - "ambients": { - "md.sys.color.on-surface": { - "alpha": 1.0, - "hue": 264.0, - "saturation": 0.15625, - "value": 0.12549019607843137 - }, - "md.sys.typescale.title-large.weight": 400.0, - "md.sys.typescale.title-large.size": 22.0, - "md.sys.typescale.title-large.line-height": 1.272727279663086, - "md.sys.typescale.label-medium.weight": 500.0, - "md.sys.typescale.label-medium.size": 12.0, - "md.sys.typescale.label-medium.tracking": 0.5, - "md.sys.typescale.label-medium.line-height": 1.3333332824707032 - } - } - ], - "adin-component-search-paths": [], - "image-search-paths": [], - "vector-search-paths": [] +{ + "name": "top_app_bar", + "version": 33, + "source-key": { + "type": "figma", + "file": "7RzB5mC9Qj82hGEbAM11GM", + "node": "71:3", + "version": "2205685389783780702", + "component-id": "be1e47a9eb28efdd3c5b0590ec33e84c60626aa5" + }, + "default": "Top app bar", + "design": { + "atoms": [ + { + "type": "group", + "id": "top_level", + "root": "true" + }, + { + "type": "group", + "id": "Title" + }, + { + "type": "group", + "id": "Buttons" + }, + { + "type": "text", + "id": "LifeMap title" + }, + { + "type": "text", + "id": "subtitle" + }, + { + "type": "group", + "id": "Notifications icon" + }, + { + "type": "group", + "id": "Settings icon" + }, + { + "type": "group", + "id": "container" + }, + { + "type": "group", + "id": "state-layer" + }, + { + "type": "group", + "id": "Icon" + }, + { + "type": "vector", + "id": "icon" + }, + { + "type": "group", + "id": "container1" + }, + { + "type": "group", + "id": "state-layer1" + }, + { + "type": "group", + "id": "Icon1" + }, + { + "type": "vector", + "id": "icon1" + } + ], + "modes": { + "Top app bar": { + "rules": [ + { + "id": "top_level", + "padding": { + "left": 20.0, + "top": 55.0, + "right": 20.0, + "bottom": 20.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "stroke-alignment": "center", + "arrangement": "row", + "main-axis-align": "space-between", + "children": [ + "Title", + "Buttons" + ], + "background-color": { + "alpha": 1.0, + "hue": 0.0, + "saturation": 0.0, + "value": 0.9215686274509803 + }, + "clip-content": false + }, + { + "id": "Title", + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "cross-axis-align": "start", + "children": [ + "LifeMap title", + "subtitle" + ], + "item-spacing": -1.0, + "clip-content": false + }, + { + "id": "Buttons", + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "main-axis-align": "start", + "children": [ + "Notifications icon", + "Settings icon" + ], + "clip-content": false + }, + { + "id": "LifeMap title", + "font-weight": "^md.sys.typescale.title-large.weight", + "color": "^md.sys.color.on-surface", + "annotated-text-content": { + "text": "LifeMap", + "annotated-text-span-list": [ + { + "span-start": 0, + "span-length": 7, + "annotated-text-style": { + "font-weight": 700.0, + "text-size": 22.0, + "letter-spacing": 0.0, + "line-height": 1.272727279663086, + "typeface": "Roboto" + } + } + ] + }, + "overflow": "visible", + "text-align": "left", + "text-size": "^md.sys.typescale.title-large.size", + "letter-spacing": "^md.sys.typescale.title-large.tracking", + "line-height": "^md.sys.typescale.title-large.line-height", + "typeface": "^md.sys.typescale.title-large.font" + }, + { + "id": "subtitle", + "font-weight": "^md.sys.typescale.label-medium.weight", + "color": "^md.sys.color.on-surface", + "text-content": "Personal life events", + "overflow": "visible", + "text-align": "left", + "text-size": "^md.sys.typescale.label-medium.size", + "letter-spacing": "^md.sys.typescale.label-medium.tracking", + "line-height": "^md.sys.typescale.label-medium.line-height", + "typeface": "^md.sys.typescale.label-medium.font" + }, + { + "id": "Notifications icon", + "tap-handler": "$on notifications icon tapped", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 32.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 32.0 + } + }, + "children": [ + "container" + ], + "item-spacing": 10.0, + "clip-content": false + }, + { + "id": "Settings icon", + "tap-handler": "$on settings icon tapped", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 32.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 32.0 + } + }, + "children": [ + "container1" + ], + "item-spacing": 10.0, + "clip-content": false + }, + { + "id": "container", + "border-radius": 100.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "children": [ + "state-layer" + ], + "item-spacing": 10.0 + }, + { + "id": "state-layer", + "padding": 8.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "children": [ + "Icon" + ], + "item-spacing": 10.0, + "clip-content": false + }, + { + "id": "Icon", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + } + }, + "is-structured": false, + "children": [ + "icon" + ] + }, + { + "id": "icon", + "margin": { + "left": 4.0, + "top": 2.0, + "right": 4.0, + "bottom": 2.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + } + }, + "vector-content": "icon.svg" + }, + { + "id": "container1", + "border-radius": 100.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "children": [ + "state-layer1" + ], + "item-spacing": 10.0 + }, + { + "id": "state-layer1", + "padding": 8.0, + "size-constraints": { + "width-constraints": { + "sizing-mode": "shrink" + }, + "height-constraints": { + "sizing-mode": "shrink" + } + }, + "arrangement": "row", + "children": [ + "Icon1" + ], + "item-spacing": 10.0, + "clip-content": false + }, + { + "id": "Icon1", + "size-constraints": { + "width-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + }, + "height-constraints": { + "sizing-mode": "fixed", + "value": 24.0 + } + }, + "is-structured": false, + "children": [ + "icon1" + ] + }, + { + "id": "icon1", + "margin": { + "left": 2.270660400390625, + "top": 2.0, + "right": 2.2706756591796875, + "bottom": 2.0 + }, + "size-constraints": { + "width-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + }, + "height-constraints": { + "sizing-mode": "proportional", + "value": 1.0 + } + }, + "vector-content": "icon1.svg" + } + ] + } + } + }, + "parameters": { + "on notifications icon tapped": { + "data-type": "void-callback", + "required": false, + "description": "" + }, + "on settings icon tapped": { + "data-type": "void-callback", + "required": false, + "description": "" + } + }, + "ambients": { + "md.sys.color.on-surface": { + "data-type": "color", + "description": null + }, + "md.sys.typescale.title-large.font": { + "data-type": "typeface", + "description": null + }, + "md.sys.typescale.title-large.weight": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.title-large.size": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.title-large.tracking": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.title-large.line-height": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.font": { + "data-type": "typeface", + "description": null + }, + "md.sys.typescale.label-medium.weight": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.size": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.tracking": { + "data-type": "double", + "description": null + }, + "md.sys.typescale.label-medium.line-height": { + "data-type": "double", + "description": null + } + }, + "previews": [ + { + "design": "Top app bar", + "size": { + "width": 375.0, + "height": 118.0 + }, + "ambients": { + "md.sys.color.on-surface": { + "alpha": 1.0, + "hue": 264.0, + "saturation": 0.15625, + "value": 0.12549019607843137 + }, + "md.sys.typescale.title-large.weight": 400.0, + "md.sys.typescale.title-large.size": 22.0, + "md.sys.typescale.title-large.line-height": 1.272727279663086, + "md.sys.typescale.label-medium.weight": 500.0, + "md.sys.typescale.label-medium.size": 12.0, + "md.sys.typescale.label-medium.tracking": 0.5, + "md.sys.typescale.label-medium.line-height": 1.3333332824707032 + } + } + ], + "adin-component-search-paths": [], + "image-search-paths": [], + "vector-search-paths": [] } \ No newline at end of file diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 7b7b95a..8922a00 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,34 +1,34 @@ -[versions] -agp = "8.9.1" -kotlin = "2.0.21" -coreKtx = "1.10.1" -junit = "4.13.2" -junitVersion = "1.1.5" -espressoCore = "3.5.1" -lifecycleRuntimeKtx = "2.6.1" -activityCompose = "1.8.0" -composeBom = "2024.09.00" -navigationCompose = "2.8.9" - -[libraries] -androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "coreKtx" } -junit = { group = "junit", name = "junit", version.ref = "junit" } -androidx-junit = { group = "androidx.test.ext", name = "junit", version.ref = "junitVersion" } -androidx-espresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "espressoCore" } -androidx-lifecycle-runtime-ktx = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycleRuntimeKtx" } -androidx-activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activityCompose" } -androidx-compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" } -androidx-ui = { group = "androidx.compose.ui", name = "ui" } -androidx-ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics" } -androidx-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" } -androidx-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" } -androidx-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest" } -androidx-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4" } -androidx-material3 = { group = "androidx.compose.material3", name = "material3" } -androidx-navigation-compose = { group = "androidx.navigation", name = "navigation-compose", version.ref = "navigationCompose" } - -[plugins] -android-application = { id = "com.android.application", version.ref = "agp" } -kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" } -kotlin-compose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" } - +[versions] +agp = "8.9.1" +kotlin = "2.0.21" +coreKtx = "1.10.1" +junit = "4.13.2" +junitVersion = "1.1.5" +espressoCore = "3.5.1" +lifecycleRuntimeKtx = "2.6.1" +activityCompose = "1.8.0" +composeBom = "2024.09.00" +navigationCompose = "2.8.9" + +[libraries] +androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "coreKtx" } +junit = { group = "junit", name = "junit", version.ref = "junit" } +androidx-junit = { group = "androidx.test.ext", name = "junit", version.ref = "junitVersion" } +androidx-espresso-core = { group = "androidx.test.espresso", name = "espresso-core", version.ref = "espressoCore" } +androidx-lifecycle-runtime-ktx = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycleRuntimeKtx" } +androidx-activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activityCompose" } +androidx-compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" } +androidx-ui = { group = "androidx.compose.ui", name = "ui" } +androidx-ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics" } +androidx-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" } +androidx-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" } +androidx-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest" } +androidx-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4" } +androidx-material3 = { group = "androidx.compose.material3", name = "material3" } +androidx-navigation-compose = { group = "androidx.navigation", name = "navigation-compose", version.ref = "navigationCompose" } + +[plugins] +android-application = { id = "com.android.application", version.ref = "agp" } +kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" } +kotlin-compose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" } + diff --git a/gradlew b/gradlew index 4f906e0..02640cb 100755 --- a/gradlew +++ b/gradlew @@ -1,185 +1,185 @@ -#!/usr/bin/env sh - -# -# Copyright 2015 the original author or authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -############################################################################## -## -## Gradle start up script for UN*X -## -############################################################################## - -# Attempt to set APP_HOME -# Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi -done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >/dev/null -APP_HOME="`pwd -P`" -cd "$SAVED" >/dev/null - -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` - -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" - -warn () { - echo "$*" -} - -die () { - echo - echo "$*" - echo - exit 1 -} - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -nonstop=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; - NONSTOP* ) - nonstop=true - ;; -esac - -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar - - -# Determine the Java command to use to start the JVM. -if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then - # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" - else - JAVACMD="$JAVA_HOME/bin/java" - fi - if [ ! -x "$JAVACMD" ] ; then - die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -else - JAVACMD="java" - which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." -fi - -# Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi -fi - -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi - -# For Cygwin or MSYS, switch paths to Windows format before running java -if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - - JAVACMD=`cygpath --unix "$JAVACMD"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi - # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" - fi - i=`expr $i + 1` - done - case $i in - 0) set -- ;; - 1) set -- "$args0" ;; - 2) set -- "$args0" "$args1" ;; - 3) set -- "$args0" "$args1" "$args2" ;; - 4) set -- "$args0" "$args1" "$args2" "$args3" ;; - 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac -fi - -# Escape application args -save () { - for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done - echo " " -} -APP_ARGS=`save "$@"` - -# Collect all arguments for the java command, following the shell quoting and substitution rules -eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" - -exec "$JAVACMD" "$@" +#!/usr/bin/env sh + +# +# Copyright 2015 the original author or authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +############################################################################## +## +## Gradle start up script for UN*X +## +############################################################################## + +# Attempt to set APP_HOME +# Resolve links: $0 may be a link +PRG="$0" +# Need this for relative symlinks. +while [ -h "$PRG" ] ; do + ls=`ls -ld "$PRG"` + link=`expr "$ls" : '.*-> \(.*\)$'` + if expr "$link" : '/.*' > /dev/null; then + PRG="$link" + else + PRG=`dirname "$PRG"`"/$link" + fi +done +SAVED="`pwd`" +cd "`dirname \"$PRG\"`/" >/dev/null +APP_HOME="`pwd -P`" +cd "$SAVED" >/dev/null + +APP_NAME="Gradle" +APP_BASE_NAME=`basename "$0"` + +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' + +# Use the maximum available, or set MAX_FD != -1 to use that value. +MAX_FD="maximum" + +warn () { + echo "$*" +} + +die () { + echo + echo "$*" + echo + exit 1 +} + +# OS specific support (must be 'true' or 'false'). +cygwin=false +msys=false +darwin=false +nonstop=false +case "`uname`" in + CYGWIN* ) + cygwin=true + ;; + Darwin* ) + darwin=true + ;; + MINGW* ) + msys=true + ;; + NONSTOP* ) + nonstop=true + ;; +esac + +CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + + +# Determine the Java command to use to start the JVM. +if [ -n "$JAVA_HOME" ] ; then + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then + # IBM's JDK on AIX uses strange locations for the executables + JAVACMD="$JAVA_HOME/jre/sh/java" + else + JAVACMD="$JAVA_HOME/bin/java" + fi + if [ ! -x "$JAVACMD" ] ; then + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." + fi +else + JAVACMD="java" + which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. + +Please set the JAVA_HOME variable in your environment to match the +location of your Java installation." +fi + +# Increase the maximum file descriptors if we can. +if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then + MAX_FD_LIMIT=`ulimit -H -n` + if [ $? -eq 0 ] ; then + if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then + MAX_FD="$MAX_FD_LIMIT" + fi + ulimit -n $MAX_FD + if [ $? -ne 0 ] ; then + warn "Could not set maximum file descriptor limit: $MAX_FD" + fi + else + warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" + fi +fi + +# For Darwin, add options to specify how the application appears in the dock +if $darwin; then + GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" +fi + +# For Cygwin or MSYS, switch paths to Windows format before running java +if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then + APP_HOME=`cygpath --path --mixed "$APP_HOME"` + CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` + + JAVACMD=`cygpath --unix "$JAVACMD"` + + # We build the pattern for arguments to be converted via cygpath + ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` + SEP="" + for dir in $ROOTDIRSRAW ; do + ROOTDIRS="$ROOTDIRS$SEP$dir" + SEP="|" + done + OURCYGPATTERN="(^($ROOTDIRS))" + # Add a user-defined pattern to the cygpath arguments + if [ "$GRADLE_CYGPATTERN" != "" ] ; then + OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" + fi + # Now convert the arguments - kludge to limit ourselves to /bin/sh + i=0 + for arg in "$@" ; do + CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` + CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option + + if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition + eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` + else + eval `echo args$i`="\"$arg\"" + fi + i=`expr $i + 1` + done + case $i in + 0) set -- ;; + 1) set -- "$args0" ;; + 2) set -- "$args0" "$args1" ;; + 3) set -- "$args0" "$args1" "$args2" ;; + 4) set -- "$args0" "$args1" "$args2" "$args3" ;; + 5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; + 6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; + 7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; + 8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; + 9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; + esac +fi + +# Escape application args +save () { + for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done + echo " " +} +APP_ARGS=`save "$@"` + +# Collect all arguments for the java command, following the shell quoting and substitution rules +eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" + +exec "$JAVACMD" "$@"