App Build

This commit is contained in:
2024-06-22 04:25:20 +08:00
commit 5ba5803ba2
105 changed files with 2789 additions and 0 deletions

1
app/.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
/build

73
app/build.gradle.kts Normal file
View File

@@ -0,0 +1,73 @@
plugins {
alias(libs.plugins.android.application)
alias(libs.plugins.jetbrains.kotlin.android)
}
android {
namespace = "com.aiosman.riderpro"
compileSdk = 34
defaultConfig {
applicationId = "com.aiosman.riderpro"
minSdk = 24
targetSdk = 34
versionCode = 1
versionName = "1.0"
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
useSupportLibrary = true
}
}
buildTypes {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
}
buildFeatures {
compose = true
}
composeOptions {
kotlinCompilerExtensionVersion = "1.5.1"
}
packaging {
resources {
excludes += "/META-INF/{AL2.0,LGPL2.1}"
}
}
}
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.android)
implementation(libs.androidx.navigation.compose)
implementation (libs.androidx.paging.compose)
implementation(libs.androidx.paging.runtime)
implementation("com.google.maps.android:maps-compose:4.3.3")
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)
}

21
app/proguard-rules.pro vendored Normal file
View File

@@ -0,0 +1,21 @@
# Add project specific ProGuard rules here.
# You can control the set of applied configuration files using the
# proguardFiles setting in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}
# Uncomment this to preserve the line number information for
# debugging stack traces.
#-keepattributes SourceFile,LineNumberTable
# If you keep the line number information, uncomment this to
# hide the original source file name.
#-renamesourcefileattribute SourceFile

View File

@@ -0,0 +1,24 @@
package com.aiosman.riderpro
import androidx.test.platform.app.InstrumentationRegistry
import androidx.test.ext.junit.runners.AndroidJUnit4
import org.junit.Test
import org.junit.runner.RunWith
import org.junit.Assert.*
/**
* Instrumented test, which will execute on an Android device.
*
* See [testing documentation](http://d.android.com/tools/testing).
*/
@RunWith(AndroidJUnit4::class)
class ExampleInstrumentedTest {
@Test
fun useAppContext() {
// Context of the app under test.
val appContext = InstrumentationRegistry.getInstrumentation().targetContext
assertEquals("com.aiosman.riderpro", appContext.packageName)
}
}

View File

@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
<uses-permission android:name="android.permission.INTERNET" />
<application
android:allowBackup="true"
android:dataExtractionRules="@xml/data_extraction_rules"
android:fullBackupContent="@xml/backup_rules"
android:icon="@mipmap/rider_pro_log"
android:label="@string/app_name"
android:roundIcon="@mipmap/rider_pro_log_round"
android:supportsRtl="true"
android:theme="@style/Theme.RiderPro"
tools:targetApi="31">
<meta-data android:name="com.google.android.geo.API_KEY"
android:value="AIzaSyBM9xMcybq9IbFSFVneZ4nAqQ0ZmTnHGO4"/>
<activity
android:name=".MainActivity"
android:exported="true"
android:label="@string/app_name"
android:theme="@style/Theme.RiderPro">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>

View File

@@ -0,0 +1,11 @@
package com.aiosman.riderpro
import androidx.annotation.DrawableRes
data class ChatNotificationData(
@DrawableRes val avatar: Int,
val name: String,
val message: String,
val time: String,
val unread: Int
)

View File

@@ -0,0 +1,50 @@
package com.aiosman.riderpro
import androidx.paging.PagingSource
import androidx.paging.PagingState
import kotlin.math.ceil
import kotlinx.coroutines.delay
internal class TestChatBackend(
private val backendDataList: List<ChatNotificationData>,
private val loadDelay: Long = 500,
) {
val DataBatchSize = 1
class DesiredLoadResultPageResponse(val data: List<ChatNotificationData>)
/** Returns [DataBatchSize] items for a key */
fun searchItemsByKey(key: Int): DesiredLoadResultPageResponse {
val maxKey = ceil(backendDataList.size.toFloat() / DataBatchSize).toInt()
if (key >= maxKey) {
return DesiredLoadResultPageResponse(emptyList())
}
val from = key * DataBatchSize
val to = minOf((key + 1) * DataBatchSize, backendDataList.size)
val currentSublist = backendDataList.subList(from, to)
return DesiredLoadResultPageResponse(currentSublist)
}
fun getAllData() = TestChatPagingSource(this, loadDelay)
}
internal class TestChatPagingSource(
private val backend: TestChatBackend,
private val loadDelay: Long,
) : PagingSource<Int, ChatNotificationData>() {
override suspend fun load(params: LoadParams<Int>): LoadResult<Int, ChatNotificationData> {
// Simulate latency
delay(loadDelay)
val pageNumber = params.key ?: 0
val response = backend.searchItemsByKey(pageNumber)
// Since 0 is the lowest page number, return null to signify no more pages should
// be loaded before it.
val prevKey = if (pageNumber > 0) pageNumber - 1 else null
// This API defines that it's out of data when a page returns empty. When out of
// data, we return `null` to signify no more pages should be loaded
val nextKey = if (response.data.isNotEmpty()) pageNumber + 1 else null
return LoadResult.Page(data = response.data, prevKey = prevKey, nextKey = nextKey)
}
override fun getRefreshKey(state: PagingState<Int, ChatNotificationData>): Int? {
return state.anchorPosition?.let {
state.closestPageToPosition(it)?.prevKey?.plus(1)
?: state.closestPageToPosition(it)?.nextKey?.minus(1)
}
}
}

View File

@@ -0,0 +1,227 @@
package com.aiosman.riderpro
import android.app.StatusBarManager
import android.os.Bundle
import android.widget.HorizontalScrollView
import android.widget.ScrollView
import androidx.activity.ComponentActivity
import androidx.activity.SystemBarStyle
import androidx.activity.compose.setContent
import androidx.activity.enableEdgeToEdge
import androidx.compose.foundation.BorderStroke
import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.border
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.WindowInsets
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.navigationBars
import androidx.compose.foundation.layout.navigationBarsPadding
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.layout.statusBarsPadding
import androidx.compose.foundation.layout.windowInsetsPadding
import androidx.compose.foundation.layout.windowInsetsStartWidth
import androidx.compose.foundation.layout.wrapContentWidth
import androidx.compose.foundation.text.BasicText
import androidx.compose.material3.CircularProgressIndicator
import androidx.compose.material3.Icon
import androidx.compose.material3.NavigationBar
import androidx.compose.material3.NavigationBarItem
import androidx.compose.material3.NavigationBarItemColors
import androidx.compose.material3.Scaffold
import androidx.compose.material3.Surface
import androidx.compose.material3.Text
import androidx.compose.material3.TopAppBar
import androidx.compose.runtime.Composable
import androidx.compose.runtime.getValue
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.graphics.ColorProducer
import androidx.compose.ui.graphics.vector.ImageVector
import androidx.compose.ui.platform.LocalDensity
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.res.vectorResource
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.core.view.WindowCompat
import androidx.navigation.NavController
import androidx.navigation.NavHostController
import androidx.navigation.compose.NavHost
import androidx.navigation.compose.composable
import androidx.navigation.compose.currentBackStackEntryAsState
import androidx.navigation.compose.rememberNavController
import com.aiosman.riderpro.ui.theme.RiderProTheme
import com.google.android.gms.maps.model.CameraPosition
import com.google.android.gms.maps.model.LatLng
import com.google.maps.android.compose.GoogleMap
import com.google.maps.android.compose.Marker
import com.google.maps.android.compose.MarkerComposable
import com.google.maps.android.compose.MarkerState
import com.google.maps.android.compose.rememberCameraPositionState
class MainActivity : ComponentActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
enableEdgeToEdge()
setContent {
Navigation()
}
}
}
@Composable
fun NavigationController(navController: NavHostController){
NavHost(
navController = navController, startDestination = NavigationItem.Home.route){
composable(route = NavigationItem.Home.route){
Home()
}
composable(route = NavigationItem.Street.route){
Street()
}
composable(route = NavigationItem.Add.route){
Add()
}
composable(route = NavigationItem.Message.route){
Message()
}
composable(route = NavigationItem.Profile.route){
Profile()
}
}
}
@Composable
fun Navigation(){
val navigationBarHeight = with(LocalDensity.current) {
WindowInsets.navigationBars.getBottom(this).toDp()
}
val navController = rememberNavController()
val item = listOf(
NavigationItem.Home,
NavigationItem.Street,
NavigationItem.Add,
NavigationItem.Message,
NavigationItem.Profile
)
Scaffold (
modifier = Modifier.statusBarsPadding(),
topBar = {},
bottomBar = {
NavigationBar (
modifier = Modifier.height(56.dp + navigationBarHeight),
containerColor = Color.Black
){
val navBackStackEntry by navController.currentBackStackEntryAsState()
val currentRoute = navBackStackEntry?.destination?.route
item.forEach{ it ->
NavigationBarItem(
selected = currentRoute == it.route ,
onClick = {
if(currentRoute != it.route){
navController.navigate(it.route)
}
},
colors = NavigationBarItemColors(
selectedIconColor = Color.Red,
selectedTextColor = Color.Red,
selectedIndicatorColor = Color.Black,
unselectedIconColor = Color.Red,
unselectedTextColor = Color.Red,
disabledIconColor = Color.Red,
disabledTextColor = Color.Red,
),
icon = {
Icon(modifier = Modifier.size(24.dp),
imageVector = it.icon(), contentDescription = null,
tint = if(currentRoute == it.route) Color.Red else Color.White
)
}
)
}
}
}
){
NavigationController(navController = navController)
}
}
@Composable
fun Home(){
Column (
modifier = Modifier.fillMaxSize(),
verticalArrangement = Arrangement.Center,
horizontalAlignment = Alignment.CenterHorizontally
){
PagingBackendSample()
}
}
@Composable
fun Street(){
Column (
modifier = Modifier.fillMaxSize(),
verticalArrangement = Arrangement.Center,
horizontalAlignment = Alignment.CenterHorizontally
) {
StreetPage()
}
}
@Composable
fun Add(){
Column (
modifier = Modifier.fillMaxSize().background(Color.Black),
verticalArrangement = Arrangement.Center,
horizontalAlignment = Alignment.CenterHorizontally
){
}
}
@Composable
fun Message(){
Column (
modifier = Modifier.fillMaxSize(),
verticalArrangement = Arrangement.Top,
horizontalAlignment = Alignment.CenterHorizontally,
){
MessagePage()
}
}
@Composable
fun Profile(){
Column (
modifier = Modifier.fillMaxSize(),
verticalArrangement = Arrangement.Center,
horizontalAlignment = Alignment.CenterHorizontally
){
ProfilePage()
}
}
@Preview(showBackground = true)
@Composable
fun GreetingPreview() {
RiderProTheme {
Surface (modifier = Modifier.fillMaxSize(), color = Color.White){
Navigation()
}
}
}

View File

@@ -0,0 +1,231 @@
package com.aiosman.riderpro
import android.view.RoundedCorner
import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.border
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.defaultMinSize
import androidx.compose.foundation.layout.fillMaxHeight
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.Person
import androidx.compose.material3.Icon
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.draw.shadow
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.graphics.vector.ImageVector
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.res.vectorResource
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.paging.LoadState
import androidx.paging.Pager
import androidx.paging.PagingConfig
import androidx.paging.compose.collectAsLazyPagingItems
val chatNotificationData = ChatNotificationData(
R.drawable.default_avatar,
"Tokunaga Yae",
"Memphis",
"3 minutes ago",
6
)
private val ChatData = (0..10).toList().map { chatNotificationData}
@Composable
fun MessagePage(){
val myBackend = remember { TestChatBackend(ChatData) }
val pager = remember {
Pager(
PagingConfig(
pageSize = myBackend.DataBatchSize,
enablePlaceholders = true,
maxSize = 200
)
) {
myBackend.getAllData()
}
}
val lazyPagingItems = pager.flow.collectAsLazyPagingItems()
MessageTopSwitchBtnGroup()
MessageBarrierLine()
MessageNotification()
LazyColumn (
modifier = Modifier.padding(bottom = 20.dp)
){
if (lazyPagingItems.loadState.refresh == LoadState.Loading) {
item {
MomentListLoading()
}
}
items(count = lazyPagingItems.itemCount) { index ->
val item = lazyPagingItems[index]
if (item != null) {
ChatItem(item)
}
}
if (lazyPagingItems.loadState.append == LoadState.Loading) {
item {
MomentListLoading()
}
}
}
}
@Composable
fun MessageTopSwitchBtnGroup(){
Column (
modifier = Modifier
.fillMaxWidth()
.height(113.dp)
) {
Row(modifier = Modifier.fillMaxSize()){
val notificationBtnModifier = Modifier
.fillMaxHeight()
.weight(1f)
NotificationBtn(notificationBtnModifier,drawableId = R.drawable.rider_pro_like,
displayText = "LIKE")
NotificationBtn(notificationBtnModifier,drawableId = R.drawable.rider_pro_followers,
displayText = "FOLLOWERS")
NotificationBtn(notificationBtnModifier,drawableId = R.drawable.rider_pro_comments,
displayText = "COMMENTS")
}
}
}
@Composable
fun MessageBarrierLine(){
Box(modifier = Modifier
.fillMaxWidth()
.height(1.dp)
.padding(start = 24.dp, end = 24.dp)
.border(width = 1.dp, Color(0f, 0f, 0f, 0.1f))
)
}
@Composable
fun NotificationBtn(modifier: Modifier, drawableId: Int, displayText: String){
Box(modifier = modifier,
contentAlignment = Alignment.Center){
Column(modifier = Modifier
.size(width = 79.dp, height = 88.dp),
verticalArrangement = Arrangement.Top,
horizontalAlignment = Alignment.CenterHorizontally){
Box(modifier = Modifier
.padding(top = 8.dp)
.size(width = 55.dp, height = 55.dp)
.shadow(
spotColor = Color.White,
ambientColor = Color(0f, 0f, 0f, 0.4f),
elevation = 12.dp,
),
contentAlignment = Alignment.Center,
){
Image(
modifier = Modifier
.size(width = 24.dp, height = 24.dp),
painter = painterResource(id = drawableId),
contentDescription = ""
)
}
Text(
modifier = Modifier.padding(top = 8.dp),
text = displayText,
fontSize = 12.sp, style = TextStyle(fontWeight = FontWeight.Bold)
)
}
}
}
@Composable
fun MessageNotification(){
Row(modifier = Modifier
.fillMaxWidth()
.height(88.dp)
.padding(start = 22.dp, top = 20.dp, bottom = 20.dp, end = 24.dp),
verticalAlignment = Alignment.CenterVertically){
Box(modifier = Modifier
.size(width = 48.dp, height = 48.dp)
.border(width = 1.dp, Color(0f, 0f, 0f, 0.1f), RoundedCornerShape(2.dp)),
contentAlignment = Alignment.Center){
Icon(
modifier = Modifier
.size(width = 24.dp, height = 24.dp),
painter = painterResource(R.drawable.rider_pro_notification),
contentDescription = ""
)
}
Text(text = "NOTIFICATIONS", fontSize = 18.sp, modifier = Modifier.padding(start = 12.dp), style = TextStyle(fontWeight = FontWeight.Bold))
Box(modifier = Modifier.fillMaxSize(),
contentAlignment = Alignment.CenterEnd){
Box(modifier = Modifier
.height(18.dp)
.clip(RoundedCornerShape(10.dp))
.background(Color.Red),
contentAlignment = Alignment.Center){
Text(text = "18", fontSize = 10.sp, color = Color.White, modifier = Modifier.padding(start = 6.dp, end = 6.dp, top = 2.dp, bottom = 2.dp))
}
}
}
}
@Composable
fun ChatItem(chatNotificationData: ChatNotificationData){
Row(modifier = Modifier
.fillMaxWidth()
.height(88.dp)
.padding(start = 22.dp, top = 20.dp, bottom = 20.dp, end = 24.dp),
verticalAlignment = Alignment.CenterVertically){
Image(modifier = Modifier
.size(width = 48.dp, height = 48.dp)
.clip(RoundedCornerShape(2.dp)),
painter = painterResource(chatNotificationData.avatar),
contentDescription = "")
Column (
modifier = Modifier.fillMaxHeight().padding(start = 12.dp),
verticalArrangement = Arrangement.SpaceAround
){
Text(text = chatNotificationData.name, fontSize = 18.sp, style = TextStyle(fontWeight = FontWeight.Bold))
Text(text = chatNotificationData.message, fontSize = 14.sp,
color = Color(0f, 0f, 0f, 0.6f))
}
Box(modifier = Modifier.fillMaxSize(),
contentAlignment = Alignment.CenterEnd){
Column (
modifier = Modifier.fillMaxHeight(),
verticalArrangement = Arrangement.SpaceAround,
horizontalAlignment = Alignment.End
){
Text(text = chatNotificationData.time, fontSize = 12.sp,color = Color(0f, 0f, 0f, 0.4f))
Box(modifier = Modifier
.height(18.dp)
.clip(RoundedCornerShape(10.dp))
.background(Color.Red),
contentAlignment = Alignment.Center){
Text(text = chatNotificationData.unread.toString(), fontSize = 10.sp, color = Color.White, modifier = Modifier.padding(start = 6.dp, end = 6.dp, top = 2.dp, bottom = 2.dp))
}
}
}
}
}

View File

@@ -0,0 +1,74 @@
package com.aiosman.riderpro
import androidx.annotation.DrawableRes
data class MomentItem(
val id: Int,
@DrawableRes val avatar: Int,
val nickname: String,
val location: String,
val time: String,
val followStatus: Boolean,
val momentTextContent: String,
@DrawableRes val momentPicture: Int,
val likeCount: Int,
val commentCount: Int,
val shareCount: Int,
val favoriteCount: Int
)
val momentTestItem = MomentItem(
id = 1,
avatar = R.drawable.default_avatar,
nickname = "Onyama Limba",
location = "Japan",
time = "2023.02.02 11:23",
followStatus = false,
momentTextContent = "By strongarming Ducati into giving him the factory seat.Marquez effectively …",
momentPicture = R.drawable.default_moment_img,
likeCount = 21,
commentCount = 43,
shareCount = 33,
favoriteCount = 211)
val profileMomentItems = listOf(
MomentItem(
id = 1,
avatar = R.drawable.default_avatar,
nickname = "Onyama Limba",
location = "Japan",
time = "2024.06.08 12:23",
followStatus = false,
momentTextContent = "Modifications that are made to make your motorbike more like you",
momentPicture = R.drawable.rider_pro_moment_demo_1,
likeCount = 2345,
commentCount = 12,
shareCount = 33,
favoriteCount = 211),
MomentItem(
id = 1,
avatar = R.drawable.default_avatar,
nickname = "Onyama Limba",
location = "Japan",
time = "2024.03.03 12:31",
followStatus = false,
momentTextContent = "At least 500 units will be made, to meet homologation requirements.",
momentPicture = R.drawable.rider_pro_moment_demo_2,
likeCount = 211,
commentCount = 33,
shareCount = 33,
favoriteCount = 211),
MomentItem(
id = 1,
avatar = R.drawable.default_avatar,
nickname = "Onyama Limba",
location = "Japan",
time = "2024.02.02 11:23",
followStatus = false,
momentTextContent = "The bike is already FIM legal (and soon-to-be MotoAmerica legal as well).",
momentPicture = R.drawable.rider_pro_moment_demo_3,
likeCount = 987,
commentCount = 21,
shareCount = 33,
favoriteCount = 211)
)

View File

@@ -0,0 +1,23 @@
package com.aiosman.riderpro
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.filled.AccountCircle
import androidx.compose.material.icons.filled.Email
import androidx.compose.material.icons.filled.Home
import androidx.compose.material.icons.filled.Place
import androidx.compose.runtime.Composable
import androidx.compose.ui.graphics.vector.ImageVector
import androidx.compose.ui.res.vectorResource
sealed class NavigationItem(val route:String, val icon: @Composable () -> ImageVector){
data object Home : NavigationItem("Home",
{ ImageVector.vectorResource(R.drawable.rider_pro_home) })
data object Street : NavigationItem("Street",
{ ImageVector.vectorResource(R.drawable.rider_pro_street) })
data object Add : NavigationItem("Add",
{ ImageVector.vectorResource(R.drawable.rider_pro_moment_add) })
data object Message : NavigationItem("Message",
{ ImageVector.vectorResource(R.drawable.rider_pro_message) })
data object Profile : NavigationItem("Profile",
{ ImageVector.vectorResource(R.drawable.rider_pro_profile) })
}

View File

@@ -0,0 +1,236 @@
package com.aiosman.riderpro
import androidx.annotation.DrawableRes
import androidx.compose.foundation.Image
import androidx.compose.foundation.border
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.defaultMinSize
import androidx.compose.foundation.layout.fillMaxHeight
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.offset
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.layout.wrapContentWidth
import androidx.compose.foundation.lazy.LazyColumn
import androidx.compose.material3.CircularProgressIndicator
import androidx.compose.material3.LocalTextStyle
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.runtime.remember
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.PlatformTextStyle
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.text.style.LineHeightStyle
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.em
import androidx.compose.ui.unit.sp
import androidx.paging.LoadState
import androidx.paging.Pager
import androidx.paging.PagingConfig
import androidx.paging.compose.collectAsLazyPagingItems
private val DATA = (0..60).toList().map { momentTestItem}
@Composable
fun PagingBackendSample() {
val myBackend = remember { TestBackend(DATA) }
val pager = remember {
Pager(
PagingConfig(
pageSize = myBackend.DataBatchSize,
enablePlaceholders = true,
maxSize = 200
)
) {
myBackend.getAllData()
}
}
val lazyPagingItems = pager.flow.collectAsLazyPagingItems()
LazyColumn {
if (lazyPagingItems.loadState.refresh == LoadState.Loading) {
item {
MomentListLoading()
}
}
items(count = lazyPagingItems.itemCount) { index ->
val item = lazyPagingItems[index]
if (item != null) {
MomentCard(item)
}
}
if (lazyPagingItems.loadState.append == LoadState.Loading) {
item {
MomentListLoading()
}
}
}
}
@Composable
fun MomentCard(momentItem: MomentItem){
Column(
modifier = Modifier.fillMaxWidth()
){
MomentTopRowGroup(momentItem = momentItem)
MomentContentGroup(momentItem = momentItem)
val momentOperateBtnBoxModifier = Modifier.fillMaxHeight().weight(1f)
MomentBottomOperateRowGroup(momentOperateBtnBoxModifier)
}
}
@Composable
fun MomentName(name: String){
Text(
modifier = Modifier,
textAlign = TextAlign.Start,
text = name,
color = Color(0f,0f,0f),
fontSize = 16.sp, style = TextStyle(fontWeight = FontWeight.Bold))
}
@Composable
fun MomentFollowBtn(){
Box(modifier = Modifier
.size(width = 53.dp, height = 18.dp)
.padding(start = 8.dp),
contentAlignment = Alignment.Center){
Image(
modifier = Modifier
.fillMaxSize(),
painter = painterResource(id = R.drawable.follow_bg),
contentDescription = ""
)
Text(text = "Follow",
color = Color.White,
fontSize = 12.sp)
}
}
@Composable
fun MomentPostLocation(location: String){
Text(text = location,
color = Color(0f,0f,0f,0.6f),
fontSize = 12.sp)
}
@Composable
fun MomentPostTime(time: String){
Text(modifier = Modifier.padding(start = 8.dp),
text = time, color = Color(0f,0f,0f,0.6f),
fontSize = 12.sp
)
}
@Composable
fun MomentTopRowGroup(momentItem: MomentItem){
Row (modifier = Modifier
.height(40.dp)
.padding(top = 0.dp, bottom = 0.dp, start = 24.dp, end = 24.dp)
){
Image(
painter = painterResource(id = momentItem.avatar),
contentDescription = ""
)
Column(
modifier = Modifier
.defaultMinSize()
.padding(start = 12.dp, end = 12.dp)
) {
Row (modifier = Modifier
.fillMaxWidth()
.height(22.dp),
verticalAlignment = Alignment.CenterVertically
){
MomentName(momentItem.nickname)
MomentFollowBtn()
}
Row (modifier = Modifier
.fillMaxWidth()
.height(21.dp),
verticalAlignment = Alignment.CenterVertically
){
MomentPostLocation(momentItem.location)
MomentPostTime(momentItem.time)
}
}
}
}
@Composable
fun MomentContentGroup(momentItem: MomentItem){
Text(text = momentItem.momentTextContent,
modifier = Modifier
.fillMaxWidth()
.padding(top = 22.dp, bottom = 16.dp, start = 24.dp, end = 24.dp),
fontSize = 16.sp
)
Image(
modifier = Modifier
.fillMaxWidth(),
painter = painterResource(id = momentItem.momentPicture),
contentDescription = ""
)
}
@Composable
fun MomentOperateBtn(@DrawableRes icon: Int, count: String){
Row (verticalAlignment = Alignment.CenterVertically){
Image(
modifier = Modifier
.size(width = 24.dp, height = 24.dp),
painter = painterResource(id = icon),
contentDescription = "")
Text(text = count,
modifier = Modifier.padding(start = 7.dp),
fontSize = 12.sp,)
}
}
@Composable
fun MomentBottomOperateRowGroup(modifier: Modifier){
Row (modifier = Modifier
.fillMaxWidth()
.height(56.dp)){
Box(modifier = modifier,
contentAlignment = Alignment.Center
){
MomentOperateBtn(icon = R.drawable.rider_pro_like, count = "21")
}
Box(modifier = modifier,
contentAlignment = Alignment.Center
){
MomentOperateBtn(icon = R.drawable.rider_pro_moment_comment, count = "43")
}
Box(modifier = modifier,
contentAlignment = Alignment.Center
){
MomentOperateBtn(icon = R.drawable.rider_pro_share, count = "33")
}
Box(modifier = modifier,
contentAlignment = Alignment.Center
){
MomentOperateBtn(icon = R.drawable.rider_pro_favoriate, count = "211")
}
}
}
@Composable
fun MomentListLoading(){
CircularProgressIndicator(
modifier =
Modifier
.fillMaxWidth()
.wrapContentWidth(Alignment.CenterHorizontally),
color = Color.Red
)
}

View File

@@ -0,0 +1,305 @@
package com.aiosman.riderpro
import android.widget.ScrollView
import androidx.annotation.DrawableRes
import androidx.compose.foundation.Image
import androidx.compose.foundation.border
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.ExperimentalLayoutApi
import androidx.compose.foundation.layout.FlowRow
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.defaultMinSize
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.rememberScrollState
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.foundation.verticalScroll
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.draw.shadow
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
@Composable
fun ProfilePage(){
Column (
modifier = Modifier
.fillMaxSize()
.verticalScroll(rememberScrollState())
.padding(bottom = 150.dp),
horizontalAlignment = Alignment.CenterHorizontally,
verticalArrangement = Arrangement.Top,
){
CarGroup()
UserInformation()
RidingStyle()
UserMoment()
}
}
@Composable
fun CarGroup(){
Column(
modifier = Modifier
.fillMaxWidth()
.padding(top = 54.dp),
horizontalAlignment = Alignment.CenterHorizontally,
) {
CarTopInformation()
CarTopPicture()
}
}
@Composable
fun CarTopInformation(){
Row{
Text(text = "BMW", color = Color.Black, fontSize = 12.sp, style = TextStyle(fontWeight = FontWeight.Bold))
Text(modifier = Modifier.padding(start = 4.dp), text = "/", color = Color.Gray, fontSize = 12.sp)
Text(modifier = Modifier.padding(start = 4.dp), text = "M1000RR", color = Color.Gray, fontSize = 12.sp)
}
}
@Composable
fun CarTopPicture(){
Image(
modifier = Modifier
.size(width = 336.dp, height = 224.dp)
.padding(top = 42.dp),
painter = painterResource(id = R.drawable.default_profile_moto), contentDescription = "")
}
@Composable
fun UserInformation(){
Column(
modifier = Modifier
.fillMaxWidth()
.padding(top = 8.dp, start = 33.dp, end = 33.dp),
horizontalAlignment = Alignment.CenterHorizontally){
Row (modifier = Modifier.fillMaxWidth()){
val userInfoModifier = Modifier.weight(1f)
UserInformationFollowers(userInfoModifier)
UserInformationBasic(userInfoModifier)
UserInformationFollowing(userInfoModifier)
}
UserInformationSlogan()
CommunicationOperatorGroup()
}
}
@Composable
fun UserInformationFollowers(modifier: Modifier){
Column(modifier = modifier.padding(top = 31.dp)) {
Text(modifier = Modifier.padding(bottom = 5.dp),text = "183", fontSize = 24.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
Spacer(
modifier = Modifier
.size(width = 88.83.dp, height = 1.dp)
.border(width = 1.dp, color = Color.Gray)
.padding(top = 5.dp, bottom = 5.dp)
)
Text(modifier = Modifier.padding(top = 5.dp),text = "FOLLOWERS", fontSize = 12.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
}
}
@Composable
fun UserInformationBasic(modifier: Modifier){
Column(
horizontalAlignment = Alignment.CenterHorizontally) {
Box(modifier = Modifier.size(width = 112.dp, height = 112.dp),
contentAlignment = Alignment.Center
){
Image(
modifier = Modifier.fillMaxSize(),
painter = painterResource(id = R.drawable.avatar_bold), contentDescription = "")
Image(
modifier = Modifier
.size(width = 88.dp, height = 88.dp)
.clip(
RoundedCornerShape(88.dp)
),
painter = painterResource(id = R.drawable.default_avatar), contentDescription = "")
}
Text(modifier = Modifier.padding(top = 8.dp), text = "Atom", fontSize = 32.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
Text(modifier = Modifier.padding(top = 4.dp), text = "America", fontSize = 12.sp, color = Color.Gray)
Text(modifier = Modifier.padding(top = 4.dp), text = "Member since Jun 4.2019", fontSize = 12.sp, color = Color.Gray)
}
}
@Composable
fun UserInformationFollowing(modifier: Modifier){
Column(modifier = modifier.padding(top = 6.dp),
horizontalAlignment = Alignment.End) {
Text(modifier = Modifier.padding(bottom = 5.dp), text = "306", fontSize = 24.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
Box(
modifier = Modifier
.size(width = 88.83.dp, height = 1.dp)
.border(width = 1.dp, color = Color.Gray)
)
Text(modifier = Modifier.padding(top = 5.dp),text = "FOLLOWING", fontSize = 12.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
}
}
@Composable
fun UserInformationSlogan(){
Text(modifier = Modifier.padding(top = 23.dp),text = "Ridering shooting fishing not much more", fontSize = 13.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
}
@Composable
fun CommunicationOperatorGroup(){
Row (modifier = Modifier
.fillMaxWidth()
.padding(top = 16.dp), horizontalArrangement = Arrangement.Center){
Box(modifier = Modifier.size(width = 142.dp, height = 40.dp),
contentAlignment = Alignment.Center){
Image(modifier = Modifier.fillMaxSize(), painter = painterResource(id = R.drawable.rider_pro_profile_follow), contentDescription = "")
Text(text = "FOLLOW", fontSize = 16.sp, color = Color.White, style = TextStyle(fontWeight = FontWeight.Bold))
}
Box(modifier = Modifier
.size(width = 142.dp, height = 40.dp)
.padding(start = 6.dp),
contentAlignment = Alignment.Center){
Image(modifier = Modifier.fillMaxSize(),painter = painterResource(id = R.drawable.rider_pro_profile_message), contentDescription = "")
Text(text = "MESSAGE", fontSize = 16.sp, color = Color.White, style = TextStyle(fontWeight = FontWeight.Bold))
}
}
}
@OptIn(ExperimentalLayoutApi::class)
@Composable
fun RidingStyle(){
Column(modifier = Modifier
.fillMaxWidth()
.padding(start = 24.dp, top = 40.dp, end = 24.dp),
horizontalAlignment = Alignment.Start) {
Text(text = "RIDING STYLES", fontSize = 18.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
Image(modifier = Modifier
.padding(top = 4.dp)
.height(8.dp),painter = painterResource(id = R.drawable.rider_pro_profile_line), contentDescription = "")
FlowRow (modifier = Modifier
.fillMaxWidth()
.padding(top = 24.dp)){
RidingStyleItem(styleContent = "Cruiser")
RidingStyleItem(styleContent = "Bobber")
RidingStyleItem(styleContent = "Cafe")
RidingStyleItem(styleContent = "Chopper")
RidingStyleItem(styleContent = "Sport")
RidingStyleItem(styleContent = "Vintage")
RidingStyleItem(styleContent = "Trike")
RidingStyleItem(styleContent = "Touring")
}
}
}
@Composable
fun RidingStyleItem(styleContent: String){
Box(modifier = Modifier.padding(bottom = 8.dp, end = 8.dp),
contentAlignment = Alignment.Center) {
Image(modifier = Modifier.shadow(
ambientColor = Color.Gray,
spotColor = Color(0f,0f,0f,0.2f),
elevation = 20.dp,
), painter = painterResource(id = R.drawable.rider_pro_style_wrapper), contentDescription = "")
Text(modifier = Modifier.padding(start = 5.dp, end = 5.dp), text = styleContent, fontSize = 12.sp, color = Color.Gray, style = TextStyle(fontWeight = FontWeight.Bold))
}
}
@Composable
fun UserMoment(){
profileMomentItems.forEach(
action = { MomentPostUnit(it) }
)
}
@Composable
fun MomentPostUnit(momentItem: MomentItem){
TimeGroup(momentItem.time)
MomentCard(momentItem.momentTextContent,
momentItem.momentPicture,
momentItem.likeCount.toString(),
momentItem.commentCount.toString())
}
@Composable
fun TimeGroup(time: String = "2024.06.08 12:23"){
Row(modifier = Modifier
.fillMaxWidth()
.padding(start = 24.dp, top = 40.dp, end = 24.dp),
horizontalArrangement = Arrangement.Start,
verticalAlignment = Alignment.CenterVertically){
Image(
modifier = Modifier.padding(end = 12.dp),
painter = painterResource(id = R.drawable.rider_pro_moment_time_flag), contentDescription = "")
Text(text = time,fontSize = 22.sp, color = Color.Black, style = TextStyle(fontWeight = FontWeight.Bold))
}
}
@Composable
fun MomentCard(content: String,@DrawableRes picture: Int, like: String, comment: String){
Column(modifier = Modifier
.fillMaxWidth()
.padding(start = 48.dp, top = 18.dp, end = 24.dp)
.border(width = 1.dp, color = Color(0f,0f,0f,0.1f), shape = RoundedCornerShape(6.dp))
){
MomentCardTopContent(content)
MomentCardPicture(picture)
MomentCardOperation(like,comment)
}
}
@Composable
fun MomentCardTopContent(content: String){
Row(modifier = Modifier
.fillMaxWidth(),
horizontalArrangement = Arrangement.Start,
verticalAlignment = Alignment.CenterVertically){
Text(
modifier = Modifier.padding(16.dp),
text = content,fontSize = 16.sp, color = Color.Black)
}
}
@Composable
fun MomentCardPicture(@DrawableRes drawable: Int){
Image(modifier = Modifier
.fillMaxSize()
.padding(16.dp), painter = painterResource(id = drawable), contentDescription = "")
}
@Composable
fun MomentCardOperation(like: String, comment: String){
Row(modifier = Modifier
.fillMaxWidth()
.height(56.dp),
horizontalArrangement = Arrangement.Start,
verticalAlignment = Alignment.CenterVertically){
Spacer(modifier = Modifier.weight(1f))
MomentCardOperationItem(drawable = R.drawable.rider_pro_like, number = like, modifier = Modifier.weight(1f))
MomentCardOperationItem(drawable = R.drawable.rider_pro_moment_comment, number = comment, modifier = Modifier.weight(1f))
}
}
@Composable
fun MomentCardOperationItem(@DrawableRes drawable: Int, number: String, modifier: Modifier){
Row(modifier = modifier,
verticalAlignment = Alignment.CenterVertically){
Image(modifier = Modifier.padding(start = 16.dp, end = 8.dp),
painter = painterResource(id = drawable), contentDescription = "")
Text(text = number)
}
}

View File

@@ -0,0 +1,50 @@
package com.aiosman.riderpro
import androidx.paging.PagingSource
import androidx.paging.PagingState
import kotlin.math.ceil
import kotlinx.coroutines.delay
internal class TestBackend(
private val backendDataList: List<MomentItem>,
private val loadDelay: Long = 500,
) {
val DataBatchSize = 5
class DesiredLoadResultPageResponse(val data: List<MomentItem>)
/** Returns [DataBatchSize] items for a key */
fun searchItemsByKey(key: Int): DesiredLoadResultPageResponse {
val maxKey = ceil(backendDataList.size.toFloat() / DataBatchSize).toInt()
if (key >= maxKey) {
return DesiredLoadResultPageResponse(emptyList())
}
val from = key * DataBatchSize
val to = minOf((key + 1) * DataBatchSize, backendDataList.size)
val currentSublist = backendDataList.subList(from, to)
return DesiredLoadResultPageResponse(currentSublist)
}
fun getAllData() = TestPagingSource(this, loadDelay)
}
internal class TestPagingSource(
private val backend: TestBackend,
private val loadDelay: Long,
) : PagingSource<Int, MomentItem>() {
override suspend fun load(params: LoadParams<Int>): LoadResult<Int, MomentItem> {
// Simulate latency
delay(loadDelay)
val pageNumber = params.key ?: 0
val response = backend.searchItemsByKey(pageNumber)
// Since 0 is the lowest page number, return null to signify no more pages should
// be loaded before it.
val prevKey = if (pageNumber > 0) pageNumber - 1 else null
// This API defines that it's out of data when a page returns empty. When out of
// data, we return `null` to signify no more pages should be loaded
val nextKey = if (response.data.isNotEmpty()) pageNumber + 1 else null
return LoadResult.Page(data = response.data, prevKey = prevKey, nextKey = nextKey)
}
override fun getRefreshKey(state: PagingState<Int, MomentItem>): Int? {
return state.anchorPosition?.let {
state.closestPageToPosition(it)?.prevKey?.plus(1)
?: state.closestPageToPosition(it)?.nextKey?.minus(1)
}
}
}

View File

@@ -0,0 +1,38 @@
package com.aiosman.riderpro
import androidx.compose.foundation.Image
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.painterResource
import com.google.android.gms.maps.model.CameraPosition
import com.google.android.gms.maps.model.LatLng
import com.google.maps.android.compose.GoogleMap
import com.google.maps.android.compose.MarkerComposable
import com.google.maps.android.compose.MarkerState
import com.google.maps.android.compose.rememberCameraPositionState
@Composable
fun StreetPage(){
val cameraPositionState = rememberCameraPositionState {
position = CameraPosition.fromLatLngZoom(
LatLng(countries[1].lat, countries[1].lng),
4f)
}
GoogleMap(
modifier = Modifier.fillMaxSize(),
cameraPositionState = cameraPositionState
) {
countries.forEach { position ->
MarkerComposable(
state = MarkerState(position = LatLng(position.lat, position.lng)),
) {
Image(
painter = painterResource(id = R.drawable.rider_pro_map_mark),
contentDescription = "",
)
}
}
}
}

View File

@@ -0,0 +1,28 @@
package com.aiosman.riderpro
data class StreetPosition(
val name:String,
val lat:Double,
val lng:Double
)
val countries = listOf(
StreetPosition("哈龙湾, 越南",16.5000, 107.1000),
StreetPosition("芽庄, 越南",12.2500, 109.0833),
StreetPosition("岘港, 越南",16.0667, 108.2167),
StreetPosition("美奈, 越南",11.9333, 108.9833),
StreetPosition("富国岛, 越南",10.0000, 104.0000),
StreetPosition("金三角, 泰国, 缅甸, 老挝",20.2500, 99.7500),
StreetPosition("普吉岛, 泰国",7.9444, 98.3000),
StreetPosition("苏梅岛, 泰国",9.5333, 99.9333),
StreetPosition("曼谷, 泰国",13.7500, 100.5000),
StreetPosition("马六甲, 马来西亚",2.2000, 102.2500),
StreetPosition("兰卡威群岛, 马来西亚",6.3000, 99.9000),
StreetPosition("沙巴, 马来西亚",6.0833, 116.0833),
StreetPosition("巴厘岛, 印度尼西亚",8.3333, 115.1000),
StreetPosition("龙目岛, 印度尼西亚",8.3333, 116.4000),
StreetPosition("婆罗洲, 印度尼西亚",3.0000, 114.0000),
StreetPosition("宿务, 菲律宾",10.3167, 123.8833),
StreetPosition("长滩岛, 菲律宾",11.5833, 121.9167),
StreetPosition("保和岛, 菲律宾",10.3000, 123.3333),
StreetPosition("科隆岛, 菲律宾",5.1167, 119.3333)
)

View File

@@ -0,0 +1,11 @@
package com.aiosman.riderpro.ui.theme
import androidx.compose.ui.graphics.Color
val Purple80 = Color(0xFFD0BCFF)
val PurpleGrey80 = Color(0xFFCCC2DC)
val Pink80 = Color(0xFFEFB8C8)
val Purple40 = Color(0xFF6650a4)
val PurpleGrey40 = Color(0xFF625b71)
val Pink40 = Color(0xFF7D5260)

View File

@@ -0,0 +1,58 @@
package com.aiosman.riderpro.ui.theme
import android.app.Activity
import android.os.Build
import androidx.compose.foundation.isSystemInDarkTheme
import androidx.compose.material3.MaterialTheme
import androidx.compose.material3.darkColorScheme
import androidx.compose.material3.dynamicDarkColorScheme
import androidx.compose.material3.dynamicLightColorScheme
import androidx.compose.material3.lightColorScheme
import androidx.compose.runtime.Composable
import androidx.compose.ui.platform.LocalContext
private val DarkColorScheme = darkColorScheme(
primary = Purple80,
secondary = PurpleGrey80,
tertiary = Pink80
)
private val LightColorScheme = lightColorScheme(
primary = Purple40,
secondary = PurpleGrey40,
tertiary = Pink40
/* Other default colors to override
background = Color(0xFFFFFBFE),
surface = Color(0xFFFFFBFE),
onPrimary = Color.White,
onSecondary = Color.White,
onTertiary = Color.White,
onBackground = Color(0xFF1C1B1F),
onSurface = Color(0xFF1C1B1F),
*/
)
@Composable
fun RiderProTheme(
darkTheme: Boolean = isSystemInDarkTheme(),
// Dynamic color is available on Android 12+
dynamicColor: Boolean = true,
content: @Composable () -> Unit
) {
val colorScheme = when {
dynamicColor && Build.VERSION.SDK_INT >= Build.VERSION_CODES.S -> {
val context = LocalContext.current
if (darkTheme) dynamicDarkColorScheme(context) else dynamicLightColorScheme(context)
}
darkTheme -> DarkColorScheme
else -> LightColorScheme
}
MaterialTheme(
colorScheme = colorScheme,
typography = Typography,
content = content
)
}

View File

@@ -0,0 +1,34 @@
package com.aiosman.riderpro.ui.theme
import androidx.compose.material3.Typography
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.text.font.FontFamily
import androidx.compose.ui.text.font.FontWeight
import androidx.compose.ui.unit.sp
// Set of Material typography styles to start with
val Typography = Typography(
bodyLarge = TextStyle(
fontFamily = FontFamily.Default,
fontWeight = FontWeight.Normal,
fontSize = 16.sp,
lineHeight = 24.sp,
letterSpacing = 0.5.sp
)
/* Other default text styles to override
titleLarge = TextStyle(
fontFamily = FontFamily.Default,
fontWeight = FontWeight.Normal,
fontSize = 22.sp,
lineHeight = 28.sp,
letterSpacing = 0.sp
),
labelSmall = TextStyle(
fontFamily = FontFamily.Default,
fontWeight = FontWeight.Medium,
fontSize = 11.sp,
lineHeight = 16.sp,
letterSpacing = 0.5.sp
)
*/
)

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

View File

@@ -0,0 +1,170 @@
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path
android:fillColor="#3DDC84"
android:pathData="M0,0h108v108h-108z" />
<path
android:fillColor="#00000000"
android:pathData="M9,0L9,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,0L19,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M29,0L29,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M39,0L39,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M49,0L49,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M59,0L59,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M69,0L69,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M79,0L79,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M89,0L89,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M99,0L99,108"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,9L108,9"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,19L108,19"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,29L108,29"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,39L108,39"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,49L108,49"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,59L108,59"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,69L108,69"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,79L108,79"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,89L108,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M0,99L108,99"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,29L89,29"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,39L89,39"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,49L89,49"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,59L89,59"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,69L89,69"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M19,79L89,79"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M29,19L29,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M39,19L39,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M49,19L49,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M59,19L59,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M69,19L69,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
<path
android:fillColor="#00000000"
android:pathData="M79,19L79,89"
android:strokeWidth="0.8"
android:strokeColor="#33FFFFFF" />
</vector>

View File

@@ -0,0 +1,30 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:width="108dp"
android:height="108dp"
android:viewportWidth="108"
android:viewportHeight="108">
<path android:pathData="M31,63.928c0,0 6.4,-11 12.1,-13.1c7.2,-2.6 26,-1.4 26,-1.4l38.1,38.1L107,108.928l-32,-1L31,63.928z">
<aapt:attr name="android:fillColor">
<gradient
android:endX="85.84757"
android:endY="92.4963"
android:startX="42.9492"
android:startY="49.59793"
android:type="linear">
<item
android:color="#44000000"
android:offset="0.0" />
<item
android:color="#00000000"
android:offset="1.0" />
</gradient>
</aapt:attr>
</path>
<path
android:fillColor="#FFFFFF"
android:fillType="nonZero"
android:pathData="M65.3,45.828l3.8,-6.6c0.2,-0.4 0.1,-0.9 -0.3,-1.1c-0.4,-0.2 -0.9,-0.1 -1.1,0.3l-3.9,6.7c-6.3,-2.8 -13.4,-2.8 -19.7,0l-3.9,-6.7c-0.2,-0.4 -0.7,-0.5 -1.1,-0.3C38.8,38.328 38.7,38.828 38.9,39.228l3.8,6.6C36.2,49.428 31.7,56.028 31,63.928h46C76.3,56.028 71.8,49.428 65.3,45.828zM43.4,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2c-0.3,-0.7 -0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C45.3,56.528 44.5,57.328 43.4,57.328L43.4,57.328zM64.6,57.328c-0.8,0 -1.5,-0.5 -1.8,-1.2s-0.1,-1.5 0.4,-2.1c0.5,-0.5 1.4,-0.7 2.1,-0.4c0.7,0.3 1.2,1 1.2,1.8C66.5,56.528 65.6,57.328 64.6,57.328L64.6,57.328z"
android:strokeWidth="1"
android:strokeColor="#00000000" />
</vector>

View File

@@ -0,0 +1,26 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M21,15C21,16.105 20.105,17 19,17L7,17L3,21L3,5C3,3.895 3.895,3 5,3L19,3C20.105,3 21,3.895 21,5L21,15Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M9.5,10.5m-1.5,0a1.5,1.5 0,1 1,3 0a1.5,1.5 0,1 1,-3 0"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M14.5,10.5m-1.5,0a1.5,1.5 0,1 1,3 0a1.5,1.5 0,1 1,-3 0"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>

View File

@@ -0,0 +1,22 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="25dp"
android:height="24dp"
android:viewportWidth="25"
android:viewportHeight="24">
<path
android:pathData="M5.657,14.7C5.657,14.7 6.558,13.8 9.26,13.8C11.962,13.8 13.763,15.6 16.464,15.6C19.166,15.6 20.067,14.7 20.067,14.7L20.067,3.9C20.067,3.9 19.166,4.8 16.464,4.8C13.763,4.8 11.962,3 9.26,3C6.558,3 5.657,3.9 5.657,3.9L5.657,14.7Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M5.657,21L5.657,14.7"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,38 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M17,21L17,19C17,16.791 15.209,15 13,15L5,15C2.791,15 1,16.791 1,19L1,21"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M9,7m-4,0a4,4 0,1 1,8 0a4,4 0,1 1,-8 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M23,21L23,19C22.999,17.177 21.765,15.586 20,15.13"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M16,3.13C17.77,3.583 19.008,5.178 19.008,7.005C19.008,8.832 17.77,10.427 16,10.88"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,22 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M3,9L12,2L21,9L21,20C21,21.105 20.105,22 19,22L5,22C3.895,22 3,21.105 3,20L3,9Z"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M9,22l0,-10l6,0l0,10"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,12 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="25dp"
android:height="24dp"
android:viewportWidth="25"
android:viewportHeight="24">
<path
android:pathData="M5.676,8.261C6.001,8.261 6.313,8.32 6.601,8.428C7.118,7.94 7.751,7.635 8.49,7.635C8.945,7.635 9.367,7.761 9.742,7.964L9.307,5.266C9.283,5.115 9.271,4.964 9.271,4.815C9.271,3.403 10.401,2 12.089,2C13.445,2 14.642,2.984 14.865,4.369L15.002,5.217L15.178,4.848C15.663,3.84 16.666,3.252 17.714,3.252C19.309,3.252 20.529,4.554 20.529,6.072C20.529,6.482 20.439,6.898 20.25,7.292L18.299,11.348C19.253,11.798 19.904,12.788 19.904,13.86L19.904,16.99C19.904,17.853 19.497,18.685 18.816,19.215L17.02,20.613C15.873,21.506 14.441,21.998 12.986,21.998L9.905,22C6.11,22.033 3.018,18.907 3.018,15.139L3.018,10.933C3.018,9.419 4.273,8.261 5.676,8.261ZM9.272,10.307C9.272,9.869 8.955,9.513 8.49,9.513C8.059,9.513 7.708,9.868 7.708,10.305L7.708,12.477C7.708,12.913 8.06,13.269 8.49,13.269C8.955,13.269 9.272,12.913 9.272,12.479L9.272,10.307ZM12.09,3.878C11.619,3.878 11.147,4.25 11.147,4.816C11.147,4.866 11.151,4.917 11.159,4.967L12.07,10.628C12.371,10.514 12.696,10.417 13.028,10.417C13.028,10.417 13.028,10.417 13.028,10.417C13.203,10.417 13.379,10.433 13.551,10.466L13.963,10.529L13.013,4.633C12.938,4.208 12.54,3.878 12.09,3.878ZM18.688,6.07C18.688,5.55 18.266,5.129 17.749,5.129C17.4,5.129 17.065,5.326 16.904,5.662L14.509,10.642L16.413,10.941L18.56,6.477C18.623,6.347 18.688,6.207 18.688,6.07ZM9.905,20.155L12.986,20.154C14.024,20.154 15.046,19.802 15.866,19.164L17.663,17.765C17.892,17.588 18.027,17.311 18.027,16.99L18.027,13.86C18.027,13.42 17.716,13.034 17.34,12.951L13.224,12.316C13.157,12.338 13.091,12.295 13.028,12.295C12.563,12.295 12.086,12.667 12.086,13.236C12.086,13.668 12.38,14.056 12.758,14.139L15.025,14.482C15.496,14.546 15.838,14.948 15.838,15.411C15.838,16.202 15.102,16.353 14.911,16.353C14.808,16.353 12.386,16.016 12.35,16.008C11.429,15.803 10.727,15.138 10.406,14.3C9.925,14.814 9.248,15.147 8.49,15.147C8.165,15.147 7.853,15.088 7.564,14.98C7.083,15.468 6.415,15.773 5.676,15.773C5.668,15.773 5.282,15.756 4.947,15.659C5.211,18.179 7.321,20.155 9.905,20.155ZM4.894,13.105C4.894,13.539 5.246,13.895 5.676,13.895C6.107,13.895 6.458,13.54 6.458,13.103L6.458,10.931C6.458,10.495 6.141,10.139 5.676,10.139C5.245,10.139 4.894,10.494 4.894,10.931L4.894,13.105Z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="nonZero"
android:strokeColor="#00000000"/>
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@@ -0,0 +1,14 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M21,15C21,16.105 20.105,17 19,17L7,17L3,21L3,5C3,3.895 3.895,3 5,3L19,3C20.105,3 21,3.895 21,5L21,15Z"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,38 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="79dp"
android:height="79dp"
android:viewportWidth="79"
android:viewportHeight="79">
<path
android:pathData="M12,8h55v55h-55z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M12,8h55v55h-55z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M49,39C49,40.105 48.105,41 47,41L35,41L31,45L31,29C31,27.895 31.895,27 33,27L47,27C48.105,27 49,27.895 49,29L49,39Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M37.5,34.5m-1.5,0a1.5,1.5 0,1 1,3 0a1.5,1.5 0,1 1,-3 0"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M42.5,34.5m-1.5,0a1.5,1.5 0,1 1,3 0a1.5,1.5 0,1 1,-3 0"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>

View File

@@ -0,0 +1,50 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="79dp"
android:height="79dp"
android:viewportWidth="79"
android:viewportHeight="79">
<path
android:pathData="M12,8h55v55h-55z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M12,8h55v55h-55z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M45,45L45,43C45,40.791 43.209,39 41,39L33,39C30.791,39 29,40.791 29,43L29,45"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M37,31m-4,0a4,4 0,1 1,8 0a4,4 0,1 1,-8 0"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M51,45L51,43C50.999,41.177 49.765,39.586 48,39.13"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M44,27.13C45.77,27.583 47.008,29.178 47.008,31.005C47.008,32.832 45.77,34.427 44,34.88"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,24 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="79dp"
android:height="79dp"
android:viewportWidth="79"
android:viewportHeight="79">
<path
android:pathData="M12,8h55v55h-55z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M12,8h55v55h-55z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M33.656,32.261C33.981,32.261 34.293,32.32 34.581,32.428C35.098,31.94 35.73,31.635 36.469,31.635C36.923,31.635 37.345,31.761 37.72,31.964L37.286,29.266C37.261,29.115 37.249,28.964 37.249,28.815C37.249,27.403 38.379,26 40.065,26C41.42,26 42.617,26.984 42.84,28.369L42.977,29.217L43.152,28.848C43.637,27.84 44.639,27.252 45.687,27.252C47.281,27.252 48.5,28.554 48.5,30.072C48.5,30.482 48.41,30.898 48.221,31.292L46.271,35.348C47.225,35.798 47.875,36.788 47.875,37.86L47.875,40.99C47.875,41.853 47.469,42.685 46.788,43.215L44.993,44.613C43.846,45.506 42.416,45.998 40.962,45.998L37.883,46C34.09,46.033 31,42.907 31,39.139L31,34.933C31,33.419 32.254,32.261 33.656,32.261ZM37.25,34.307C37.25,33.869 36.934,33.513 36.469,33.513C36.038,33.513 35.688,33.868 35.688,34.305L35.688,36.477C35.688,36.913 36.039,37.269 36.469,37.269C36.934,37.269 37.25,36.913 37.25,36.479L37.25,34.307ZM40.066,27.878C39.596,27.878 39.124,28.25 39.124,28.816C39.124,28.866 39.128,28.917 39.136,28.967L40.047,34.628C40.348,34.514 40.672,34.417 41.004,34.417C41.004,34.417 41.004,34.417 41.004,34.417C41.179,34.417 41.354,34.433 41.527,34.466L41.939,34.529L40.989,28.633C40.914,28.208 40.516,27.878 40.066,27.878ZM46.66,30.07C46.66,29.55 46.239,29.129 45.722,29.129C45.373,29.129 45.038,29.326 44.878,29.662L42.484,34.642L44.387,34.941L46.532,30.477C46.595,30.347 46.66,30.207 46.66,30.07ZM37.883,44.155L40.961,44.154C41.999,44.154 43.021,43.802 43.84,43.164L45.636,41.765C45.864,41.588 46,41.311 46,40.99L46,37.86C46,37.42 45.689,37.034 45.313,36.951L41.2,36.316C41.133,36.338 41.066,36.295 41.004,36.295C40.539,36.295 40.063,36.667 40.063,37.236C40.063,37.668 40.356,38.056 40.734,38.139L43,38.482C43.47,38.546 43.812,38.948 43.812,39.411C43.812,40.202 43.077,40.353 42.886,40.353C42.783,40.353 40.362,40.016 40.326,40.008C39.406,39.803 38.704,39.138 38.383,38.3C37.902,38.814 37.227,39.147 36.469,39.147C36.144,39.147 35.832,39.088 35.543,38.98C35.063,39.468 34.395,39.773 33.656,39.773C33.648,39.773 33.263,39.756 32.928,39.659C33.191,42.179 35.301,44.155 37.883,44.155ZM32.875,37.105C32.875,37.539 33.227,37.895 33.656,37.895C34.087,37.895 34.438,37.54 34.438,37.103L34.438,34.931C34.438,34.495 34.121,34.139 33.656,34.139C33.226,34.139 32.875,34.494 32.875,34.931L32.875,37.105Z"
android:strokeWidth="1"
android:fillColor="#1F1F1F"
android:fillType="nonZero"
android:strokeColor="#00000000"/>
</vector>

View File

@@ -0,0 +1,25 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M3,4h18v16h-18z"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"/>
<path
android:pathData="M8,11h8v2h-8z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M11,8h2v8h-2z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>

View File

@@ -0,0 +1,14 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M21,11.5C21.003,12.82 20.695,14.122 20.1,15.3C18.661,18.179 15.719,19.999 12.5,20C11.18,20.003 9.878,19.695 8.7,19.1L3,21L4.9,15.3C4.305,14.122 3.997,12.82 4,11.5C4.001,8.281 5.821,5.339 8.7,3.9C9.878,3.305 11.18,2.997 12.5,3L13,3C17.316,3.238 20.762,6.684 21,11L21,11.5Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 386 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 326 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 491 KiB

View File

@@ -0,0 +1,18 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="14dp"
android:height="16dp"
android:viewportWidth="14"
android:viewportHeight="16">
<path
android:pathData="M0,0l14,0l-2,5l2,5l-14,0z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M0,0h2v16h-2z"
android:strokeWidth="1"
android:fillColor="#899DA9"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>

View File

@@ -0,0 +1,14 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M21,16.5L3,16.5C4.491,16.5 5.7,15.291 5.7,13.8L5.7,9.3C5.7,5.821 8.52,3 12,3C15.479,3 18.3,5.821 18.3,9.3L18.3,13.8C18.3,15.291 19.509,16.5 21,16.5L21,16.5ZM13.557,20.1C13.235,20.655 12.642,20.996 12,20.996C11.358,20.996 10.765,20.655 10.443,20.1"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,22 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M20,21L20,19C20,16.791 18.209,15 16,15L8,15C5.791,15 4,16.791 4,19L4,21"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M12,7m-4,0a4,4 0,1 1,8 0a4,4 0,1 1,-8 0"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@@ -0,0 +1,36 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="347dp"
android:height="8dp"
android:viewportWidth="347"
android:viewportHeight="8">
<path
android:pathData="M2,0l345,0l-2,8l-345,0z"
android:strokeWidth="1"
android:fillColor="#ED1C24"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M2,0l123,0l-2,8l-123,0z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M130,0l7,0l-2,8l-7,0z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M143,0l7,0l-2,8l-7,0z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
<path
android:pathData="M156,0l7,0l-2,8l-7,0z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -0,0 +1,46 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="25dp"
android:height="24dp"
android:viewportWidth="25"
android:viewportHeight="24">
<path
android:pathData="M14.818,5.7a2.668,2.7 0,1 0,5.337 0a2.668,2.7 0,1 0,-5.337 0z"
android:strokeLineJoin="round"
android:strokeWidth="1.77777778"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M4.144,12a2.668,2.7 0,1 0,5.337 0a2.668,2.7 0,1 0,-5.337 0z"
android:strokeLineJoin="round"
android:strokeWidth="1.77777778"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M14.818,18.3a2.668,2.7 0,1 0,5.337 0a2.668,2.7 0,1 0,-5.337 0z"
android:strokeLineJoin="round"
android:strokeWidth="1.77777778"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M9.116,13.359L15.191,16.941"
android:strokeLineJoin="round"
android:strokeWidth="1.77777778"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M15.182,7.059L9.116,10.641"
android:strokeLineJoin="round"
android:strokeWidth="1.77777778"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

View File

@@ -0,0 +1,30 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M12,12m-10,0a10,10 0,1 1,20 0a10,10 0,1 1,-20 0"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M2,12L22,12"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M12,2C14.501,4.738 15.923,8.292 16,12C15.923,15.708 14.501,19.262 12,22C9.499,19.262 8.077,15.708 8,12C8.077,8.292 9.499,4.738 12,2L12,2Z"
android:strokeLineJoin="round"
android:strokeWidth="1.93476923"
android:fillColor="#00000000"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</vector>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

View File

@@ -0,0 +1,12 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="72dp"
android:height="24dp"
android:viewportWidth="72"
android:viewportHeight="24">
<path
android:pathData="M0,0l68,0l4,12l-4,12l-68,0l4,-12z"
android:strokeWidth="1"
android:fillColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background" />
<foreground android:drawable="@drawable/ic_launcher_foreground" />
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>

View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@drawable/ic_launcher_background" />
<foreground android:drawable="@drawable/ic_launcher_foreground" />
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/rider_pro_log_background"/>
<foreground android:drawable="@mipmap/rider_pro_log_foreground"/>
</adaptive-icon>

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/rider_pro_log_background"/>
<foreground android:drawable="@mipmap/rider_pro_log_foreground"/>
</adaptive-icon>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 956 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 982 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 900 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 682 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

View File

@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="purple_200">#FFBB86FC</color>
<color name="purple_500">#FF6200EE</color>
<color name="purple_700">#FF3700B3</color>
<color name="teal_200">#FF03DAC5</color>
<color name="teal_700">#FF018786</color>
<color name="black">#FF000000</color>
<color name="white">#FFFFFFFF</color>
</resources>

View File

@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="rider_pro_log_background">#FFFFFF</color>
</resources>

View File

@@ -0,0 +1,3 @@
<resources>
<string name="app_name">RiderPro</string>
</resources>

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<style name="Theme.RiderPro" parent="android:Theme.Material.Light.NoActionBar" />
</resources>

View File

@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?><!--
Sample backup rules file; uncomment and customize as necessary.
See https://developer.android.com/guide/topics/data/autobackup
for details.
Note: This file is ignored for devices older that API 31
See https://developer.android.com/about/versions/12/backup-restore
-->
<full-backup-content>
<!--
<include domain="sharedpref" path="."/>
<exclude domain="sharedpref" path="device.xml"/>
-->
</full-backup-content>

View File

@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="utf-8"?><!--
Sample data extraction rules file; uncomment and customize as necessary.
See https://developer.android.com/about/versions/12/backup-restore#xml-changes
for details.
-->
<data-extraction-rules>
<cloud-backup>
<!-- TODO: Use <include> and <exclude> to control what is backed up.
<include .../>
<exclude .../>
-->
</cloud-backup>
<!--
<device-transfer>
<include .../>
<exclude .../>
</device-transfer>
-->
</data-extraction-rules>

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@@ -0,0 +1,17 @@
package com.aiosman.riderpro
import org.junit.Test
import org.junit.Assert.*
/**
* Example local unit test, which will execute on the development machine (host).
*
* See [testing documentation](http://d.android.com/tools/testing).
*/
class ExampleUnitTest {
@Test
fun addition_isCorrect() {
assertEquals(4, 2 + 2)
}
}