Add basic compose demo app

This commit is contained in:
Wolf Montwé 2023-02-15 18:52:35 +01:00
parent 2bc5f3f04a
commit a098aaee9f
No known key found for this signature in database
GPG key ID: 6D45B21512ACBF72
25 changed files with 791 additions and 2 deletions

View file

@ -48,6 +48,6 @@ dependencies {
debugImplementation("androidx.compose.ui:ui-test-manifest")
androidTestImplementation("androidx.compose.ui:ui-test-junit4")
implementation("androidx.activity:activity-compose:1.6.1")
implementation("androidx.lifecycle:lifecycle-viewmodel-compose:2.5.1")
implementation(libs.androidx.compose.activity)
implementation(libs.androidx.compose.lifecycle.viewmodel)
}

View file

@ -0,0 +1,18 @@
plugins {
id(ThunderbirdPlugins.App.androidCompose)
}
android {
namespace = "app.k9mail.core.ui.compose.demo"
defaultConfig {
applicationId = "app.k9mail.core.ui.compose.demo"
versionCode = 1
versionName = "1.0"
}
}
dependencies {
androidTestImplementation(libs.androidx.test.ext.junit.ktx)
androidTestImplementation(libs.androidx.test.espresso.core)
}

21
core/ui/compose/demo/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,23 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:roundIcon="@mipmap/ic_launcher_round"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/Theme.K9"
>
<activity
android:name=".MainActivity"
android:exported="true">
<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,30 @@
package app.k9mail.core.ui.compose.demo
import android.os.Bundle
import androidx.activity.ComponentActivity
import androidx.activity.compose.setContent
import androidx.compose.material.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.tooling.preview.Preview
class MainActivity : ComponentActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContent {
Greeting(name = stringResource(id = R.string.app_name))
}
}
}
@Composable
fun Greeting(name: String) {
Text(text = "Hello $name!")
}
@Preview(showBackground = true)
@Composable
fun Preview() {
Greeting("Android")
}

View file

@ -0,0 +1,149 @@
<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="192"
android:viewportHeight="192">
<group android:scaleX="0.52411765"
android:scaleY="0.52411765"
android:translateX="45.684708"
android:translateY="44.75294">
<path
android:pathData="M50,12C46.68,12 44,14.68 44,18V26C44,29.32 46.68,32 50,32H64V48H72V32H74C77.32,32 80,29.32 80,26V18C80,14.68 77.32,12 74,12H50ZM118,12C114.68,12 112,14.68 112,18V26C112,29.32 114.68,32 118,32H120V48H128V32H142C145.32,32 148,29.32 148,26V18C148,14.68 145.32,12 142,12H118ZM32,120V132L57.61,170C59.68,173.59 63.54,176 68,176H124C128.46,176 132.32,173.59 134.39,170H134.4L160,132V120H32Z"
android:strokeAlpha="0.2"
android:fillColor="#000000"
android:fillAlpha="0.2"/>
<path
android:pathData="M50,8C46.68,8 44,10.68 44,14V22C44,25.32 46.68,28 50,28H64V44H72V28H74C77.32,28 80,25.32 80,22V14C80,10.68 77.32,8 74,8H50ZM118,8C114.68,8 112,10.68 112,14V22C112,25.32 114.68,28 118,28H120V44H128V28H142C145.32,28 148,25.32 148,22V14C148,10.68 145.32,8 142,8H118ZM32,116V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128V116H32Z"
android:strokeAlpha="0.2"
android:fillColor="#000000"
android:fillAlpha="0.2"/>
<path
android:pathData="M24,116L32,128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128L168,116H24Z"
android:strokeAlpha="0.2"
android:fillColor="#000000"
android:fillAlpha="0.2"/>
<path
android:pathData="M32,116V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160.01,128V116H32Z"
android:fillColor="#607D8B"
android:fillType="evenOdd"/>
<path
android:pathData="M72,16H64V44H72V16Z"
android:fillColor="#263238"/>
<path
android:pathData="M128,16H120V44H128V16Z"
android:fillColor="#263238"/>
<path
android:pathData="M32,127V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128V127L134.4,165H134.39C132.32,168.59 128.46,171 124,171H68C63.54,171 59.68,168.59 57.61,165L32,127Z"
android:fillColor="#4D6570"/>
<path
android:pathData="M80,22V14C80,10.69 77.31,8 74,8L50,8C46.69,8 44,10.69 44,14V22C44,25.31 46.69,28 50,28L74,28C77.31,28 80,25.31 80,22Z"
android:fillColor="#607D8B"/>
<path
android:pathData="M148,22V14C148,10.69 145.31,8 142,8L118,8C114.69,8 112,10.69 112,14V22C112,25.31 114.69,28 118,28L142,28C145.31,28 148,25.31 148,22Z"
android:fillColor="#607D8B"/>
<path
android:pathData="M44,21V22C44,25.32 46.68,28 50,28H74C77.32,28 80,25.32 80,22V21C80,24.32 77.32,27 74,27H50C46.68,27 44,24.32 44,21Z"
android:fillColor="#4D6570"/>
<path
android:pathData="M112,21V22C112,25.32 114.68,28 118,28H142C145.32,28 148,25.32 148,22V21C148,24.32 145.32,27 142,27H118C114.68,27 112,24.32 112,21Z"
android:fillColor="#4D6570"/>
<path
android:pathData="M50,8C46.68,8 44,10.68 44,14V15C44,11.68 46.68,9 50,9H74C77.32,9 80,11.68 80,15V14C80,10.68 77.32,8 74,8H50Z"
android:fillColor="#8097A2"/>
<path
android:pathData="M118,8C114.68,8 112,10.68 112,14V15C112,11.68 114.68,9 118,9H142C145.32,9 148,11.68 148,15V14C148,10.68 145.32,8 142,8H118Z"
android:fillColor="#8097A2"/>
<path
android:pathData="M32,116V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128V116H32Z"
android:fillType="evenOdd">
<aapt:attr name="android:fillColor">
<gradient
android:startX="80"
android:startY="112"
android:endX="80"
android:endY="140"
android:type="linear">
<item android:offset="0" android:color="#FF4D6570"/>
<item android:offset="1" android:color="#0F4D6570"/>
</gradient>
</aapt:attr>
</path>
<path
android:pathData="M171.99,120V52C171.99,45.37 166.62,40 159.99,40L31.99,40C25.37,40 19.99,45.37 19.99,52V120C19.99,126.62 25.37,132 31.99,132H159.99C166.62,132 171.99,126.62 171.99,120Z"
android:strokeAlpha="0.2"
android:fillColor="#37abc8"
android:fillAlpha="0.2"/>
<path
android:pathData="M171.99,116V48C171.99,41.37 166.62,36 159.99,36L31.99,36C25.37,36 19.99,41.37 19.99,48V116C19.99,122.62 25.37,128 31.99,128L159.99,128C166.62,128 171.99,122.62 171.99,116Z"
android:strokeAlpha="0.2"
android:fillColor="#5fbcd3"
android:fillAlpha="0.2"/>
<path
android:pathData="M172,116V48C172,41.37 166.63,36 160,36L32,36C25.37,36 20,41.37 20,48V116C20,122.63 25.37,128 32,128H160C166.63,128 172,122.63 172,116Z"
android:fillColor="#ff9955"/>
<path
android:pathData="M36,52L96,84L156,52"
android:strokeWidth="6"
android:fillColor="#00000000"
android:strokeColor="#FBE9E7"
android:strokeLineCap="round"/>
<path
android:pathData="M32,36C25.35,36 20,41.35 20,48V49C20,42.35 25.35,37 32,37H160C166.65,37 172,42.35 172,49V48C172,41.35 166.65,36 160,36H32Z"
android:fillColor="#ff9955"/>
<path
android:pathData="M20,115V116C20,122.65 25.35,128 32,128H160C166.65,128 172,122.65 172,116V115C172,121.65 166.65,127 160,127H32C25.35,127 20,121.65 20,115Z"
android:fillColor="#ff7f2a"/>
<path
android:pathData="M90,156C86.68,156 84,158.68 84,162V174C84,174.27 84.03,174.54 84.06,174.8C84.06,174.8 84.06,174.81 84.06,174.81C84.02,175.2 84,175.6 84,176C84,179.18 85.26,182.23 87.51,184.48C89.77,186.73 92.82,188 96,188C99.18,188 102.24,186.73 104.49,184.48C106.74,182.23 108,179.18 108,176C108,175.61 107.97,175.23 107.93,174.85C107.97,174.57 108,174.29 108,174V162C108,158.67 105.33,156 102,156L90,156Z"
android:strokeAlpha="0.2"
android:fillColor="#000000"
android:fillAlpha="0.2"/>
<path
android:pathData="M90,152C86.68,152 84,154.68 84,158V170C84,170.27 84.03,170.54 84.06,170.8C84.06,170.8 84.06,170.81 84.06,170.81C84.02,171.2 84,171.6 84,172C84,175.18 85.26,178.23 87.51,180.48C89.77,182.73 92.82,184 96,184C99.18,184 102.24,182.73 104.49,180.48C106.74,178.23 108,175.18 108,172C108,171.61 107.97,171.23 107.93,170.85C107.97,170.57 108,170.29 108,170V158C108,154.67 105.33,152 102,152L90,152Z"
android:strokeAlpha="0.2"
android:fillColor="#000000"
android:fillAlpha="0.2"/>
<path
android:pathData="M108,170V158C108,154.69 105.31,152 102,152H90C86.69,152 84,154.69 84,158V170C84,173.31 86.69,176 90,176H102C105.31,176 108,173.31 108,170Z"
android:fillColor="#263238"/>
<path
android:pathData="M96,184C102.63,184 108,178.63 108,172C108,165.37 102.63,160 96,160C89.37,160 84,165.37 84,172C84,178.63 89.37,184 96,184Z"
android:fillColor="#263238"/>
<path
android:pathData="M90,152C86.68,152 84,154.68 84,158V159C84,155.68 86.68,153 90,153H102C105.32,153 108,155.68 108,159V158C108,154.68 105.32,152 102,152H90Z"
android:fillColor="#37474F"/>
<path
android:pathData="M84.02,171.43C84.01,171.62 84,171.81 84,172C84,175.18 85.26,178.24 87.51,180.49C89.77,182.74 92.82,184 96,184C99.18,184 102.24,182.74 104.49,180.49C106.74,178.24 108,175.18 108,172C108,171.86 107.99,171.73 107.98,171.59C107.83,174.67 106.5,177.57 104.27,179.69C102.04,181.81 99.08,183 96,183C92.89,183 89.91,181.79 87.68,179.63C85.44,177.47 84.13,174.53 84.02,171.43Z"
android:fillColor="#1A252A"/>
<path
android:pathData="M50,8C46.68,8 44,10.68 44,14V22C44,25.32 46.68,28 50,28H64V36H32C25.35,36 20,41.35 20,48V116C20,122.65 25.35,128 32,128L57.61,166C59.68,169.59 63.54,172 68,172H84C84,175.18 85.26,178.24 87.51,180.49C89.77,182.74 92.82,184 96,184C99.18,184 102.23,182.74 104.48,180.49C106.73,178.23 108,175.18 108,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128C166.65,128 172,122.65 172,116V48C172,41.35 166.65,36 160,36H128V28H142C145.32,28 148,25.32 148,22V14C148,10.68 145.32,8 142,8H118C114.68,8 112,10.68 112,14V22C112,25.32 114.68,28 118,28H120V36H72V28H74C77.32,28 80,25.32 80,22V14C80,10.68 77.32,8 74,8H50Z"
android:fillType="evenOdd">
<aapt:attr name="android:fillColor">
<gradient
android:centerX="-0"
android:centerY="0"
android:gradientRadius="271.53"
android:type="radial">
<item android:offset="0" android:color="#19FBFCFC"/>
<item android:offset="1" android:color="#00FBFCFC"/>
</gradient>
</aapt:attr>
</path>
<path
android:pathData="m50,8.72c-3.32,0 -6,2.68 -6,6v8c0,3.32 2.68,6 6,6h14v8H32c-3.34,0 -6.35,1.35 -8.53,3.54C21.32,42.43 20,45.41 20,48.72v68c0,6.65 5.35,12 12,12l25.61,38c2.07,3.59 5.94,6 10.39,6h16c0,3.18 1.26,6.24 3.51,8.48 2.25,2.25 5.3,3.52 8.49,3.52 3.18,-0 6.23,-1.26 8.48,-3.52 2.25,-2.25 3.51,-5.3 3.51,-8.48H124c4.46,0 8.32,-2.41 10.39,-6h0.01l25.6,-38c6.65,-0 12,-5.35 12,-12v-68c0,-6.65 -5.35,-12 -12,-12h-32v-8h14c3.32,0 6,-2.68 6,-6v-8c0,-3.32 -2.68,-6 -6,-6h-24c-3.32,0 -6,2.68 -6,6v8c0,3.32 2.68,6 6,6h2v8H72v-8h2c3.32,0 6,-2.68 6,-6v-8c0,-3.32 -2.68,-6 -6,-6z"
android:fillType="evenOdd">
<aapt:attr name="android:fillColor">
<gradient
android:startX="192"
android:startY="0.72"
android:endX="192"
android:endY="192.72"
android:type="linear">
<item android:offset="0" android:color="#19FBFCFC"/>
<item android:offset="1" android:color="#00FBFCFC"/>
</gradient>
</aapt:attr>
</path>
</group>
</vector>

View file

@ -0,0 +1,104 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="192"
android:viewportHeight="192">
<group
android:scaleX="0.52411765"
android:scaleY="0.52411765"
android:translateX="45.684708"
android:translateY="44.75294">
<path
android:fillAlpha="0.2"
android:fillColor="#000000"
android:pathData="M50,12C46.68,12 44,14.68 44,18V26C44,29.32 46.68,32 50,32H64V48H72V32H74C77.32,32 80,29.32 80,26V18C80,14.68 77.32,12 74,12H50ZM118,12C114.68,12 112,14.68 112,18V26C112,29.32 114.68,32 118,32H120V48H128V32H142C145.32,32 148,29.32 148,26V18C148,14.68 145.32,12 142,12H118ZM32,120V132L57.61,170C59.68,173.59 63.54,176 68,176H124C128.46,176 132.32,173.59 134.39,170H134.4L160,132V120H32Z"
android:strokeAlpha="0.2" />
<path
android:fillAlpha="0.2"
android:fillColor="#000000"
android:pathData="M50,8C46.68,8 44,10.68 44,14V22C44,25.32 46.68,28 50,28H64V44H72V28H74C77.32,28 80,25.32 80,22V14C80,10.68 77.32,8 74,8H50ZM118,8C114.68,8 112,10.68 112,14V22C112,25.32 114.68,28 118,28H120V44H128V28H142C145.32,28 148,25.32 148,22V14C148,10.68 145.32,8 142,8H118ZM32,116V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128V116H32Z"
android:strokeAlpha="0.2" />
<path
android:fillAlpha="0.2"
android:fillColor="#000000"
android:pathData="M24,116L32,128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128L168,116H24Z"
android:strokeAlpha="0.2" />
<path
android:fillColor="#607D8B"
android:pathData="M32,116V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160.01,128V116H32Z" />
<path
android:fillColor="#263238"
android:pathData="M72,16H64V44H72V16Z" />
<path
android:fillColor="#263238"
android:pathData="M128,16H120V44H128V16Z" />
<path
android:fillColor="#4D6570"
android:pathData="M32,127V128L57.61,166C59.68,169.59 63.54,172 68,172H124C128.46,172 132.32,169.59 134.39,166H134.4L160,128V127L134.4,165H134.39C132.32,168.59 128.46,171 124,171H68C63.54,171 59.68,168.59 57.61,165L32,127Z" />
<path
android:fillColor="#607D8B"
android:pathData="M80,22V14C80,10.69 77.31,8 74,8L50,8C46.69,8 44,10.69 44,14V22C44,25.31 46.69,28 50,28L74,28C77.31,28 80,25.31 80,22Z" />
<path
android:fillColor="#607D8B"
android:pathData="M148,22V14C148,10.69 145.31,8 142,8L118,8C114.69,8 112,10.69 112,14V22C112,25.31 114.69,28 118,28L142,28C145.31,28 148,25.31 148,22Z" />
<path
android:fillColor="#4D6570"
android:pathData="M44,21V22C44,25.32 46.68,28 50,28H74C77.32,28 80,25.32 80,22V21C80,24.32 77.32,27 74,27H50C46.68,27 44,24.32 44,21Z" />
<path
android:fillColor="#4D6570"
android:pathData="M112,21V22C112,25.32 114.68,28 118,28H142C145.32,28 148,25.32 148,22V21C148,24.32 145.32,27 142,27H118C114.68,27 112,24.32 112,21Z" />
<path
android:fillColor="#8097A2"
android:pathData="M50,8C46.68,8 44,10.68 44,14V15C44,11.68 46.68,9 50,9H74C77.32,9 80,11.68 80,15V14C80,10.68 77.32,8 74,8H50Z" />
<path
android:fillColor="#8097A2"
android:pathData="M118,8C114.68,8 112,10.68 112,14V15C112,11.68 114.68,9 118,9H142C145.32,9 148,11.68 148,15V14C148,10.68 145.32,8 142,8H118Z" />
<path
android:fillAlpha="0.2"
android:fillColor="#37abc8"
android:pathData="M171.99,120V52C171.99,45.37 166.62,40 159.99,40L31.99,40C25.37,40 19.99,45.37 19.99,52V120C19.99,126.62 25.37,132 31.99,132H159.99C166.62,132 171.99,126.62 171.99,120Z"
android:strokeAlpha="0.2" />
<path
android:fillAlpha="0.2"
android:fillColor="#5fbcd3"
android:pathData="M171.99,116V48C171.99,41.37 166.62,36 159.99,36L31.99,36C25.37,36 19.99,41.37 19.99,48V116C19.99,122.62 25.37,128 31.99,128L159.99,128C166.62,128 171.99,122.62 171.99,116Z"
android:strokeAlpha="0.2" />
<path
android:fillColor="#ff9955"
android:pathData="M172,116V48C172,41.37 166.63,36 160,36L32,36C25.37,36 20,41.37 20,48V116C20,122.63 25.37,128 32,128H160C166.63,128 172,122.63 172,116Z" />
<path
android:fillColor="#00000000"
android:pathData="M36,52L96,84L156,52"
android:strokeWidth="6"
android:strokeColor="#FBE9E7"
android:strokeLineCap="round" />
<path
android:fillColor="#ff9955"
android:pathData="M32,36C25.35,36 20,41.35 20,48V49C20,42.35 25.35,37 32,37H160C166.65,37 172,42.35 172,49V48C172,41.35 166.65,36 160,36H32Z" />
<path
android:fillColor="#ff7f2a"
android:pathData="M20,115V116C20,122.65 25.35,128 32,128H160C166.65,128 172,122.65 172,116V115C172,121.65 166.65,127 160,127H32C25.35,127 20,121.65 20,115Z" />
<path
android:fillAlpha="0.2"
android:fillColor="#000000"
android:pathData="M90,156C86.68,156 84,158.68 84,162V174C84,174.27 84.03,174.54 84.06,174.8C84.06,174.8 84.06,174.81 84.06,174.81C84.02,175.2 84,175.6 84,176C84,179.18 85.26,182.23 87.51,184.48C89.77,186.73 92.82,188 96,188C99.18,188 102.24,186.73 104.49,184.48C106.74,182.23 108,179.18 108,176C108,175.61 107.97,175.23 107.93,174.85C107.97,174.57 108,174.29 108,174V162C108,158.67 105.33,156 102,156L90,156Z"
android:strokeAlpha="0.2" />
<path
android:fillAlpha="0.2"
android:fillColor="#000000"
android:pathData="M90,152C86.68,152 84,154.68 84,158V170C84,170.27 84.03,170.54 84.06,170.8C84.06,170.8 84.06,170.81 84.06,170.81C84.02,171.2 84,171.6 84,172C84,175.18 85.26,178.23 87.51,180.48C89.77,182.73 92.82,184 96,184C99.18,184 102.24,182.73 104.49,180.48C106.74,178.23 108,175.18 108,172C108,171.61 107.97,171.23 107.93,170.85C107.97,170.57 108,170.29 108,170V158C108,154.67 105.33,152 102,152L90,152Z"
android:strokeAlpha="0.2" />
<path
android:fillColor="#263238"
android:pathData="M108,170V158C108,154.69 105.31,152 102,152H90C86.69,152 84,154.69 84,158V170C84,173.31 86.69,176 90,176H102C105.31,176 108,173.31 108,170Z" />
<path
android:fillColor="#263238"
android:pathData="M96,184C102.63,184 108,178.63 108,172C108,165.37 102.63,160 96,160C89.37,160 84,165.37 84,172C84,178.63 89.37,184 96,184Z" />
<path
android:fillColor="#37474F"
android:pathData="M90,152C86.68,152 84,154.68 84,158V159C84,155.68 86.68,153 90,153H102C105.32,153 108,155.68 108,159V158C108,154.68 105.32,152 102,152H90Z" />
<path
android:fillColor="#1A252A"
android:pathData="M84.02,171.43C84.01,171.62 84,171.81 84,172C84,175.18 85.26,178.24 87.51,180.49C89.77,182.74 92.82,184 96,184C99.18,184 102.24,182.74 104.49,180.49C106.74,178.24 108,175.18 108,172C108,171.86 107.99,171.73 107.98,171.59C107.83,174.67 106.5,177.57 104.27,179.69C102.04,181.81 99.08,183 96,183C92.89,183 89.91,181.79 87.68,179.63C85.44,177.47 84.13,174.53 84.02,171.43Z" />
</group>
</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="@color/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="@color/ic_launcher_background"/>
<foreground android:drawable="@drawable/ic_launcher_foreground"/>
<monochrome android:drawable="@drawable/ic_launcher_foreground" />
</adaptive-icon>

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View file

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

View file

@ -0,0 +1,3 @@
<resources>
<string name="app_name">K-9 Compose Demo</string>
</resources>

View file

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

View file

@ -70,7 +70,11 @@ androidx-core = { module = "androidx.core:core", version.ref = "androidxCore" }
androidx-core-ktx = { module = "androidx.core:core-ktx", version.ref = "androidxCore" }
androidx-preference = { module = "androidx.preference:preference", version.ref = "androidxPreference" }
androidx-swiperefreshlayout = "androidx.swiperefreshlayout:swiperefreshlayout:1.1.0"
androidx-compose-activity = "androidx.activity:activity-compose:1.6.1"
androidx-compose-lifecycle-viewmodel = "androidx.lifecycle:lifecycle-viewmodel-compose:2.5.1"
androidx-test-core = "androidx.test:core:1.5.0"
androidx-test-ext-junit-ktx = "androidx.test.ext:junit-ktx:1.1.5"
androidx-test-espresso-core = "androidx.test.espresso:espresso-core:3.5.1"
android-material = "com.google.android.material:material:1.7.0"
fastadapter = { module = "com.mikepenz:fastadapter", version.ref = "fastAdapter" }
fastadapter-extensions-drag = { module = "com.mikepenz:fastadapter-extensions-drag", version.ref = "fastAdapter" }

View file

@ -0,0 +1,413 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
width="192"
height="192"
viewBox="0 0 192 192"
fill="none"
version="1.1"
id="svg326"
sodipodi:docname="K-9_Mail-debug 2.svg"
inkscape:version="1.2.2 (b0a84865, 2022-12-01)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview328"
pagecolor="#ffffff"
bordercolor="#000000"
borderopacity="0.25"
inkscape:showpageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:deskcolor="#d1d1d1"
showgrid="false"
inkscape:zoom="4.6003373"
inkscape:cx="80.863636"
inkscape:cy="76.516129"
inkscape:window-width="2483"
inkscape:window-height="1548"
inkscape:window-x="0"
inkscape:window-y="25"
inkscape:window-maximized="0"
inkscape:current-layer="svg326" />
<g
opacity="0.2"
filter="url(#filter0_f_235_6064)"
id="g192">
<path
d="M50 12C46.676 12 44 14.676 44 18V26C44 29.324 46.676 32 50 32H64V48H72V32H74C77.324 32 80 29.324 80 26V18C80 14.676 77.324 12 74 12H50ZM118 12C114.676 12 112 14.676 112 18V26C112 29.324 114.676 32 118 32H120V48H128V32H142C145.324 32 148 29.324 148 26V18C148 14.676 145.324 12 142 12H118ZM32 120V132L57.607 170C59.6768 173.589 63.5428 176 68 176H124C128.457 176 132.323 173.589 134.393 170H134.405L160.001 132V120H32Z"
fill="black"
id="path190" />
</g>
<g
opacity="0.2"
filter="url(#filter1_f_235_6064)"
id="g196">
<path
d="M50 8C46.676 8 44 10.676 44 14V22C44 25.324 46.676 28 50 28H64V44H72V28H74C77.324 28 80 25.324 80 22V14C80 10.676 77.324 8 74 8H50ZM118 8C114.676 8 112 10.676 112 14V22C112 25.324 114.676 28 118 28H120V44H128V28H142C145.324 28 148 25.324 148 22V14C148 10.676 145.324 8 142 8H118ZM32 116V128L57.607 166C59.6768 169.589 63.5428 172 68 172H124C128.457 172 132.323 169.589 134.393 166H134.405L160.001 128V116H32Z"
fill="black"
id="path194" />
</g>
<g
opacity="0.2"
filter="url(#filter2_f_235_6064)"
id="g200">
<path
d="M24 116L32 128L57.607 166C59.6768 169.589 63.5428 172 68 172H124C128.457 172 132.323 169.589 134.393 166H134.405L160.001 128L168.001 116H24Z"
fill="black"
id="path198" />
</g>
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M32 116V128L57.607 166C59.6768 169.589 63.5428 172 68 172H124C128.457 172 132.323 169.589 134.393 166H134.405L160.005 128V116H32Z"
fill="#607D8B"
id="path202" />
<path
d="M72 16H64V44H72V16Z"
fill="#263238"
id="path204" />
<path
d="M128 16H120V44H128V16Z"
fill="#263238"
id="path206" />
<path
d="M32 127V128L57.607 166C59.6768 169.589 63.5428 172 68 172H124C128.457 172 132.323 169.589 134.393 166H134.405L160.001 128V127L134.405 165H134.393C132.323 168.589 128.457 171 124 171H68C63.5433 171 59.6772 168.589 57.607 165L32 127Z"
fill="#4D6570"
id="path208" />
<path
d="M80 22V14C80 10.6863 77.3137 8 74 8L50 8C46.6863 8 44 10.6863 44 14V22C44 25.3137 46.6863 28 50 28L74 28C77.3137 28 80 25.3137 80 22Z"
fill="#607D8B"
id="path210" />
<path
d="M148 22V14C148 10.6863 145.314 8 142 8L118 8C114.686 8 112 10.6863 112 14V22C112 25.3137 114.686 28 118 28L142 28C145.314 28 148 25.3137 148 22Z"
fill="#607D8B"
id="path212" />
<path
d="M44 21V22C44 25.324 46.676 28 50 28H74C77.324 28 80 25.324 80 22V21C80 24.324 77.324 27 74 27H50C46.676 27 44 24.324 44 21Z"
fill="#4D6570"
id="path214" />
<path
d="M112 21V22C112 25.324 114.676 28 118 28H142C145.324 28 148 25.324 148 22V21C148 24.324 145.324 27 142 27H118C114.676 27 112 24.324 112 21Z"
fill="#4D6570"
id="path216" />
<path
d="M50 8C46.676 8 44 10.676 44 14V15C44 11.676 46.676 9 50 9H74C77.324 9 80 11.676 80 15V14C80 10.676 77.324 8 74 8H50Z"
fill="#8097A2"
id="path218" />
<path
d="M118 8C114.676 8 112 10.676 112 14V15C112 11.676 114.676 9 118 9H142C145.324 9 148 11.676 148 15V14C148 10.676 145.324 8 142 8H118Z"
fill="#8097A2"
id="path220" />
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M32 116V128L57.607 166C59.6768 169.589 63.5428 172 68 172H124C128.457 172 132.323 169.589 134.393 166H134.405L160.001 128V116H32Z"
fill="url(#paint0_linear_235_6064)"
id="path222" />
<g
opacity="0.2"
filter="url(#filter3_f_235_6064)"
id="g226"
style="fill:#37abc8">
<path
d="M171.994 119.996V51.996C171.994 45.3686 166.622 39.996 159.994 39.996L31.9941 39.996C25.3667 39.996 19.9941 45.3686 19.9941 51.996V119.996C19.9941 126.623 25.3667 131.996 31.9941 131.996H159.994C166.622 131.996 171.994 126.623 171.994 119.996Z"
fill="black"
id="path224"
style="fill:#37abc8" />
</g>
<g
opacity="0.2"
filter="url(#filter4_f_235_6064)"
id="g230"
style="fill:#80e5ff">
<path
d="M171.994 115.996V47.996C171.994 41.3686 166.622 35.996 159.994 35.996L31.9941 35.996C25.3667 35.996 19.9941 41.3686 19.9941 47.996V115.996C19.9941 122.623 25.3667 127.996 31.9941 127.996L159.994 127.996C166.622 127.996 171.994 122.623 171.994 115.996Z"
fill="black"
id="path228"
style="fill:#5fbcd3" />
</g>
<path
d="M172 116V48C172 41.3726 166.627 36 160 36L32 36C25.3726 36 20 41.3726 20 48V116C20 122.627 25.3726 128 32 128H160C166.627 128 172 122.627 172 116Z"
fill="#5917FF"
id="path232"
style="fill:#ff9955;fill-opacity:1" />
<path
d="M36 52L96 84L156 52"
stroke="#FBE9E7"
stroke-width="6"
stroke-linecap="round"
id="path234" />
<path
d="M32 36C25.352 36 20 41.352 20 48V49C20 42.352 25.352 37 32 37H160C166.648 37 172 42.352 172 49V48C172 41.352 166.648 36 160 36H32Z"
fill="#3034EB"
id="path236"
style="fill:#ff9955" />
<path
d="M20 115V116C20 122.648 25.352 128 32 128H160C166.648 128 172 122.648 172 116V115C172 121.648 166.648 127 160 127H32C25.352 127 20 121.648 20 115Z"
fill="#3034EB"
id="path238"
style="fill:#ff7f2a" />
<g
opacity="0.2"
filter="url(#filter5_f_235_6064)"
id="g242">
<path
d="M90.0005 156C86.6765 156 84.0005 158.676 84.0005 162V174C84.0005 174.273 84.026 174.54 84.061 174.803C84.0613 174.805 84.0607 174.807 84.061 174.809C84.021 175.204 84.0006 175.601 84 175.999C84 179.181 85.2643 182.234 87.5147 184.484C89.7652 186.734 92.8174 187.999 96 187.999C99.1826 187.999 102.235 186.734 104.485 184.484C106.736 182.234 108 179.181 108 175.999C107.996 175.614 107.974 175.229 107.934 174.846C107.974 174.566 108.004 174.286 108.004 173.996V161.996C108.004 158.672 105.328 155.996 102.004 155.996L90.0005 156Z"
fill="black"
id="path240" />
</g>
<g
opacity="0.2"
filter="url(#filter6_f_235_6064)"
id="g246">
<path
d="M90.0005 152C86.6765 152 84.0005 154.676 84.0005 158V170C84.0005 170.273 84.026 170.54 84.061 170.803C84.0613 170.805 84.0607 170.807 84.061 170.809C84.021 171.204 84.0006 171.601 84 171.999C84 175.181 85.2643 178.234 87.5147 180.484C89.7652 182.734 92.8174 183.999 96 183.999C99.1826 183.999 102.235 182.734 104.485 180.484C106.736 178.234 108 175.181 108 171.999C107.996 171.614 107.974 171.229 107.934 170.846C107.974 170.566 108.004 170.286 108.004 169.996V157.996C108.004 154.672 105.328 151.996 102.004 151.996L90.0005 152Z"
fill="black"
id="path244" />
</g>
<path
d="M108 170V158C108 154.686 105.314 152 102 152H90C86.6863 152 84 154.686 84 158V170C84 173.314 86.6863 176 90 176H102C105.314 176 108 173.314 108 170Z"
fill="#263238"
id="path248" />
<path
d="M96 184C102.627 184 108 178.627 108 172C108 165.373 102.627 160 96 160C89.3726 160 84 165.373 84 172C84 178.627 89.3726 184 96 184Z"
fill="#263238"
id="path250" />
<path
d="M90 152C86.676 152 84 154.676 84 158V159C84 155.676 86.676 153 90 153H102C105.324 153 108 155.676 108 159V158C108 154.676 105.324 152 102 152H90Z"
fill="#37474F"
id="path252" />
<path
d="M84.021 171.43C84.0095 171.62 84.0025 171.81 84 172C84 175.183 85.2643 178.235 87.5147 180.485C89.7652 182.736 92.8174 184 96 184C99.1826 184 102.235 182.736 104.485 180.485C106.736 178.235 108 175.183 108 172C107.996 171.863 107.989 171.726 107.98 171.59C107.829 174.666 106.5 177.566 104.271 179.689C102.041 181.813 99.0795 182.999 96 183C92.8942 182.996 89.9106 181.789 87.6766 179.631C85.4427 177.474 84.1323 174.534 84.021 171.43Z"
fill="#1A252A"
id="path254" />
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="M50 8C46.676 8 44 10.676 44 14V22C44 25.324 46.676 28 50 28H64V36H32C25.352 36 20 41.352 20 48V116C20 122.648 25.352 128 32 128L57.607 166C59.6768 169.589 63.5428 172 68 172H84C84 175.183 85.2643 178.235 87.5147 180.485C89.7652 182.736 92.8174 184 96 184C99.1823 183.999 102.234 182.735 104.484 180.485C106.734 178.234 107.998 175.182 107.998 172H124C128.457 172 132.323 169.589 134.393 166H134.403L160.001 128C166.648 127.999 172.001 122.647 172.001 116V48C172.001 41.352 166.647 36 159.999 36H128.001V28H141.999C145.323 28 148.001 25.324 148.001 22V14C148.001 10.676 145.323 8 141.999 8H118.001C114.677 8 112.001 10.676 112.001 14V22C112.001 25.324 114.677 28 118.001 28H120.001V36H72.001V28H73.999C77.323 28 80.001 25.324 80.001 22V14C80.001 10.676 77.323 8 73.999 8H50Z"
fill="url(#paint1_radial_235_6064)"
id="path256" />
<path
fill-rule="evenodd"
clip-rule="evenodd"
d="m 50,8.72 c -3.324,0 -6,2.676 -6,6 v 8 c 0,3.324 2.676,6 6,6 h 14 v 8 H 32 c -3.340866,0 -6.354436,1.351613 -8.525953,3.540081 C 21.324456,42.426453 20,45.412866 20,48.72 v 68 c 0,6.648 5.352,12 12,12 l 25.607,38 c 2.0698,3.589 5.9358,6 10.393,6 h 16 c 0,3.183 1.2643,6.235 3.5147,8.485 2.2505,2.251 5.3027,3.515 8.4853,3.515 3.1823,-0.001 6.234,-1.265 8.484,-3.515 2.25,-2.251 3.514,-5.303 3.514,-8.485 H 124 c 4.457,0 8.323,-2.411 10.393,-6 h 0.01 l 25.598,-38 c 6.647,-0.001 12,-5.353 12,-12 v -68 c 0,-6.648 -5.354,-12 -12.002,-12 h -31.998 v -8 h 13.998 c 3.324,0 6.002,-2.676 6.002,-6 v -8 c 0,-3.324 -2.678,-6 -6.002,-6 h -23.998 c -3.324,0 -6,2.676 -6,6 v 8 c 0,3.324 2.676,6 6,6 h 2 v 8 H 72.0011 v -8 h 1.998 c 3.324,0 6.002,-2.676 6.002,-6 v -8 c 0,-3.324 -2.678,-6 -6.002,-6 z"
fill="url(#paint2_linear_235_6064)"
id="path258"
sodipodi:nodetypes="ssssccssssccscccccscccsssccssssssssccccsssss" />
<defs
id="defs324">
<filter
id="filter0_f_235_6064"
x="26.16"
y="6.16"
width="139.681"
height="175.68"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood260" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend262" />
<feGaussianBlur
stdDeviation="2.92"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur264" />
</filter>
<filter
id="filter1_f_235_6064"
x="26.16"
y="2.16"
width="139.681"
height="175.68"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood267" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend269" />
<feGaussianBlur
stdDeviation="2.92"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur271" />
</filter>
<filter
id="filter2_f_235_6064"
x="20"
y="112"
width="152.001"
height="64"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood274" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend276" />
<feGaussianBlur
stdDeviation="2"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur278" />
</filter>
<filter
id="filter3_f_235_6064"
x="15.1141"
y="35.116"
width="161.76"
height="101.76"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood281" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend283" />
<feGaussianBlur
stdDeviation="2.44"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur285" />
</filter>
<filter
id="filter4_f_235_6064"
x="15.1141"
y="31.116"
width="161.76"
height="101.76"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood288" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend290" />
<feGaussianBlur
stdDeviation="2.44"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur292" />
</filter>
<filter
id="filter5_f_235_6064"
x="81.2"
y="153.196"
width="29.6039"
height="37.6023"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood295" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend297" />
<feGaussianBlur
stdDeviation="1.4"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur299" />
</filter>
<filter
id="filter6_f_235_6064"
x="82.88"
y="150.876"
width="26.2439"
height="34.2423"
filterUnits="userSpaceOnUse"
color-interpolation-filters="sRGB">
<feFlood
flood-opacity="0"
result="BackgroundImageFix"
id="feFlood302" />
<feBlend
mode="normal"
in="SourceGraphic"
in2="BackgroundImageFix"
result="shape"
id="feBlend304" />
<feGaussianBlur
stdDeviation="0.56"
result="effect1_foregroundBlur_235_6064"
id="feGaussianBlur306" />
</filter>
<linearGradient
id="paint0_linear_235_6064"
x1="80"
y1="112"
x2="80"
y2="140"
gradientUnits="userSpaceOnUse">
<stop
stop-color="#4D6570"
id="stop309" />
<stop
offset="1"
stop-color="#4D6570"
stop-opacity="0.06"
id="stop311" />
</linearGradient>
<radialGradient
id="paint1_radial_235_6064"
cx="0"
cy="0"
r="1"
gradientUnits="userSpaceOnUse"
gradientTransform="translate(-0.00142478 0.00143102) rotate(45) scale(271.527)">
<stop
stop-color="#FBFCFC"
stop-opacity="0.1"
id="stop314" />
<stop
offset="1"
stop-color="#FBFCFC"
stop-opacity="0"
id="stop316" />
</radialGradient>
<linearGradient
id="paint2_linear_235_6064"
x1="192"
y1="0.720003"
x2="192"
y2="192.72"
gradientUnits="userSpaceOnUse">
<stop
stop-color="#FBFCFC"
stop-opacity="0.1"
id="stop319" />
<stop
offset="1"
stop-color="#FBFCFC"
stop-opacity="0"
id="stop321" />
</linearGradient>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 16 KiB

View file

@ -38,6 +38,10 @@ include(
":app:html-cleaner"
)
include(
":core:ui:compose:demo"
)
include(
":ui-utils:LinearLayoutManager",
":ui-utils:ItemTouchHelper",