-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from HuixingWong/main
support multi-platform
- Loading branch information
Showing
21 changed files
with
344 additions
and
238 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
|
||
plugins { | ||
id("org.jetbrains.compose") version "1.0.0-beta5" | ||
id("com.android.application") | ||
kotlin("android") | ||
} | ||
|
||
group = "com.godaddy" | ||
version = "1.0" | ||
|
||
|
||
dependencies { | ||
implementation(project(":color-picker")) | ||
implementation ("androidx.activity:activity-compose:1.4.0") | ||
implementation("com.google.android.material:material:1.4.0") | ||
} | ||
|
||
android { | ||
compileSdkVersion(31) | ||
defaultConfig { | ||
applicationId = "com.godaddy.android.colorpicker" | ||
minSdkVersion(21) | ||
targetSdkVersion(31) | ||
versionCode = 1 | ||
versionName = "1.0" | ||
} | ||
compileOptions { | ||
sourceCompatibility = JavaVersion.VERSION_1_8 | ||
targetCompatibility = JavaVersion.VERSION_1_8 | ||
} | ||
packagingOptions { | ||
excludes += "/META-INF/{AL2.0,LGPL2.1}" | ||
} | ||
buildTypes { | ||
getByName("release") { | ||
isMinifyEnabled = false | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// Top-level build file where you can add configuration options common to all sub-projects/modules. | ||
|
||
buildscript { | ||
repositories { | ||
gradlePluginPortal() | ||
google() | ||
mavenCentral() | ||
} | ||
dependencies { | ||
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:1.5.31") | ||
classpath("com.android.tools.build:gradle:4.1.3") | ||
classpath("com.vanniktech:gradle-maven-publish-plugin:0.18.0") | ||
} | ||
} | ||
|
||
group = "com.godaddy" | ||
version = "1.0" | ||
|
||
allprojects { | ||
repositories { | ||
google() | ||
mavenCentral() | ||
maven("https://maven.pkg.jetbrains.space/public/p/compose/dev") | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
import org.jetbrains.compose.compose | ||
|
||
plugins { | ||
kotlin("multiplatform") | ||
id("org.jetbrains.compose") version "1.0.0-beta5" | ||
id("com.android.library") | ||
id("kotlin-android-extensions") | ||
id("com.vanniktech.maven.publish") | ||
} | ||
|
||
group = "com.godaddy" | ||
version = "1.0" | ||
|
||
kotlin { | ||
android() | ||
jvm("desktop") { | ||
compilations.all { | ||
kotlinOptions.jvmTarget = "11" | ||
} | ||
} | ||
sourceSets { | ||
val commonMain by getting { | ||
dependencies { | ||
api(compose.runtime) | ||
api(compose.foundation) | ||
api(compose.material) | ||
implementation("com.github.ajalt.colormath:colormath:3.1.1") | ||
} | ||
} | ||
val commonTest by getting { | ||
dependencies { | ||
implementation(kotlin("test")) | ||
} | ||
} | ||
val androidMain by getting { | ||
dependencies { | ||
api("androidx.appcompat:appcompat:1.3.1") | ||
api("androidx.core:core-ktx:1.6.0") | ||
} | ||
} | ||
val androidTest by getting { | ||
dependencies { | ||
implementation("junit:junit:4.13.2") | ||
} | ||
} | ||
val desktopMain by getting { | ||
dependencies { | ||
api(compose.preview) | ||
} | ||
} | ||
val desktopTest by getting | ||
} | ||
} | ||
|
||
android { | ||
compileSdkVersion(31) | ||
sourceSets["main"].manifest.srcFile("src/androidMain/AndroidManifest.xml") | ||
defaultConfig { | ||
minSdkVersion(21) | ||
targetSdkVersion(31) | ||
} | ||
compileOptions { | ||
sourceCompatibility = JavaVersion.VERSION_11 | ||
targetCompatibility = JavaVersion.VERSION_11 | ||
} | ||
} |
2 changes: 1 addition & 1 deletion
2
color-picker/src/main/AndroidManifest.xml → ...icker/src/androidMain/AndroidManifest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
package="com.godaddy.android.colorpicker"> | ||
package="com.godaddy.common.colorpicker"> | ||
|
||
</manifest> |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.