Skip to content

Commit

Permalink
Merge pull request #123 from icerockdev/develop
Browse files Browse the repository at this point in the history
Release 0.1.0-dev-12
  • Loading branch information
Alex009 authored Feb 19, 2020
2 parents 5ad5080 + 9d14b9d commit dca618f
Show file tree
Hide file tree
Showing 71 changed files with 1,229 additions and 149 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/compilation-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@ jobs:
- name: Cocoapods install
run: (cd sample/ios-app && pod install)
- name: Build pods-dependent and publish local
run: ./gradlew -PlibraryPublish :widgets-flat:publishToMavenLocal
run: ./gradlew -PlibraryPublish :widgets-flat:publishToMavenLocal :widgets-bottomsheet:publishToMavenLocal :widgets-sms:publishToMavenLocal
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ jobs:
- name: Cocoapods install
run: (cd sample/ios-app && pod install)
- name: Build pods-dependent and publish local
run: ./gradlew -PlibraryPublish :widgets-flat:publishAllPublicationsToBintrayRepository -DBINTRAY_USER=${{ secrets.BINTRAY_USER }} -DBINTRAY_KEY=${{ secrets.BINTRAY_KEY }}
run: ./gradlew -PlibraryPublish :widgets-flat:publishAllPublicationsToBintrayRepository :widgets-bottomsheet:publishAllPublicationsToBintrayRepository :widgets-sms:publishAllPublicationsToBintrayRepository -DBINTRAY_USER=${{ secrets.BINTRAY_USER }} -DBINTRAY_KEY=${{ secrets.BINTRAY_KEY }}
18 changes: 13 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This is a Kotlin MultiPlatform library that provides declarative UI and applicat
in common code. You can implement full application for Android and iOS only from common code with it.

## Current status
Current version - `0.1.0-dev-11`. Dev version is not tested in production tasks yet, API can be changed and
Current version - `0.1.0-dev-12`. Dev version is not tested in production tasks yet, API can be changed and
bugs may be found. But dev version is chance to test limits of API and concepts to feedback and improve lib.
We open for any feedback and ideas (go to issues or #moko at [kotlinlang.slack.com](https://kotlinlang.slack.com))!

Expand Down Expand Up @@ -218,6 +218,7 @@ val loginScreen = Theme(baseTheme) {
- 0.1.0-dev-9
- 0.1.0-dev-10
- 0.1.0-dev-11
- 0.1.0-dev-12

## Installation
root build.gradle
Expand All @@ -232,7 +233,7 @@ allprojects {
project build.gradle
```groovy
dependencies {
commonMainApi("dev.icerock.moko:widgets:0.1.0-dev-11")
commonMainApi("dev.icerock.moko:widgets:0.1.0-dev-12")
}
```

Expand All @@ -250,7 +251,7 @@ buildscript {
}
dependencies {
classpath "dev.icerock.moko.widgets:gradle-plugin:0.1.0-dev-11"
classpath "dev.icerock.moko.widgets:gradle-plugin:0.1.0-dev-12"
}
}
Expand Down Expand Up @@ -364,15 +365,22 @@ Please see more examples in the [sample directory](sample).

## Set Up Locally
- The [widgets directory](widgets) contains the `widgets` library;
- The [widgets-bottomsheet directory](widgets-bottomsheet) contains the `widgets-bottomsheet` library;
- The [widgets-sms directory](widgets-sms) contains the `widgets-sms` library;
- The [gradle-plugin directory](gradle-plugin) contains the gradle-plugin which apply compiler plugins for Native and JVM;
- The [kotlin-plugin directory](kotlin-plugin) contains the JVM compiler plugin with code-generation from @WidgetDef annotation;
- The [kotlin-native-plugin directory](kotlin-native-plugin) contains the Native compiler plugin with code-generation from @WidgetDef annotation;
- The [kotlin-common-plugin directory](kotlin-common-plugin) contains the common code of JVM and Native compiler plugins;
- The [sample directory](sample) contains sample apps for Android and iOS; plus the mpp-library connected to the apps;
- For local testing a library use:
- `./gradlew -PpluginPublish publishPluginPublicationToMavenLocal`
- `./gradlew -PlibraryPublish publishToMavenLocal`
- sample apps priority use the locally published version.
- `./gradlew -PlibraryPublish :widgets:publishToMavenLocal`
- `cd sample/ios-app && pod install`
- `./gradlew -PlibraryPublish :widgets-flat:publishToMavenLocal :widgets-bottomsheet:publishToMavenLocal :widgets-sms:publishToMavenLocal`
- sample apps priority use the locally published version
- `./gradlew :sample:mpp-library:syncMultiPlatformLibraryDebugFrameworkIosX64` - compile sample shared code for iOS
- `cd sample/ios-app && pod install` - install pods with compiled shared code
- run android from `Android Studio` - module `android-app`, run iOS from xcode workspace `sample/ios-app/ios-app.xcworkspace`

## Contributing
All development (both new features and bug fixes) is performed in the `develop` branch. This way `master` always contains the sources of the most recently released version. Please send PRs with bug fixes to the `develop` branch. Documentation fixes in the markdown files are an exception to this rule. They are updated directly in `master`.
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ repositories {
}

dependencies {
implementation("dev.icerock:mobile-multiplatform:0.5.0")
implementation("dev.icerock:mobile-multiplatform:0.5.2")
implementation("org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.61")
implementation("com.android.tools.build:gradle:3.5.2")
}
Expand Down
11 changes: 11 additions & 0 deletions buildSrc/src/main/kotlin/Deps.kt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@ object Deps {
val roundedImageView = AndroidLibrary(
name = "com.makeramen:roundedimageview:${Versions.Libs.Android.roundedImageView}"
)
val playServiceAuth = AndroidLibrary(
name = "com.google.android.gms:play-services-auth:${Versions.Libs.Android.playServiceAuth}"
)
val playServiceAuthSms = AndroidLibrary(
name = "com.google.android.gms:play-services-auth-api-phone:${Versions.Libs.Android.playServiceAuthSms}"
)
}

object MultiPlatform {
Expand All @@ -59,6 +65,11 @@ object Deps {
iosX64 = "dev.icerock.moko:widgets-flat-iosx64:${Versions.Libs.MultiPlatform.mokoWidgets}",
iosArm64 = "dev.icerock.moko:widgets-flat-iosarm64:${Versions.Libs.MultiPlatform.mokoWidgets}"
)
val mokoWidgetsBottomSheet = MultiPlatformLibrary(
common = "dev.icerock.moko:widgets-bottomsheet:${Versions.Libs.MultiPlatform.mokoWidgets}",
iosX64 = "dev.icerock.moko:widgets-bottomsheet-iosx64:${Versions.Libs.MultiPlatform.mokoWidgets}",
iosArm64 = "dev.icerock.moko:widgets-bottomsheet-iosarm64:${Versions.Libs.MultiPlatform.mokoWidgets}"
)
val mokoResources = MultiPlatformLibrary(
common = "dev.icerock.moko:resources:${Versions.Libs.MultiPlatform.mokoResources}",
iosX64 = "dev.icerock.moko:resources-iosx64:${Versions.Libs.MultiPlatform.mokoResources}",
Expand Down
4 changes: 3 additions & 1 deletion buildSrc/src/main/kotlin/Versions.kt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ object Versions {
}

const val kotlin = "1.3.61"
private const val mokoWidgets = "0.1.0-dev-11"
private const val mokoWidgets = "0.1.0-dev-12"
private const val mokoResources = "0.8.0"

object Plugins {
Expand All @@ -29,6 +29,8 @@ object Versions {
const val inputMask = "5.0.0"
const val glide = "4.10.0"
const val roundedImageView = "2.3.0"
const val playServiceAuth = "17.0.0"
const val playServiceAuthSms = "17.1.0"
}

object MultiPlatform {
Expand Down
22 changes: 22 additions & 0 deletions moko-widgets-bottomsheet.podspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
Pod::Spec.new do |spec|
spec.name = 'moko-widgets-bottomsheet'
spec.version = '0.1.0'
spec.homepage = 'https://github.com/icerockdev/moko-widgets'
spec.source = { :git => "https://github.com/icerockdev/moko-widgets.git", :tag => "release/#{spec.version}" }
spec.authors = 'IceRock Development'
spec.license = { :type => 'Apache 2', :file => 'LICENSE.md' }
spec.summary = 'Swift additions to moko-widgets Kotlin/Native library'
spec.module_name = "mokoWidgetsBottomSheet"

spec.source_files = "widgets-bottomSheet/src/iosMain/swift/**/*.{h,m,swift}"
spec.resources = "widgets-bottomSheet/src/iosMain/bundle/**/*"

spec.dependency 'FloatingPanel'

spec.ios.deployment_target = '11.0'
spec.swift_version = '5.0'

spec.pod_target_xcconfig = {
'VALID_ARCHS' => '$(ARCHS_STANDARD_64_BIT)'
}
end
1 change: 1 addition & 0 deletions sample/ios-app/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ target 'TestProj' do

pod 'mppLibraryIos', :path => '../mpp-library'
pod 'moko-widgets-flat', :path => '../../'
pod 'moko-widgets-bottomsheet', :path => '../../'

pod 'MultiPlatformLibraryMvvm', :git => 'https://github.com/icerockdev/moko-mvvm.git', :tag => 'release/0.4.0-dev-2'
end
12 changes: 11 additions & 1 deletion sample/ios-app/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ PODS:
- Alamofire (4.9.1)
- AlamofireImage (3.6.0):
- Alamofire (~> 4.9)
- FloatingPanel (1.7.2)
- InputMask (5.0.0)
- moko-widgets-bottomsheet (0.1.0):
- FloatingPanel
- moko-widgets-flat (0.1.0):
- InputMask (~> 5.0.0)
- mppLibraryIos (0.1.0)
Expand All @@ -23,6 +26,7 @@ PODS:
- SkyFloatingLabelTextField (3.7.0)

DEPENDENCIES:
- moko-widgets-bottomsheet (from `../../`)
- moko-widgets-flat (from `../../`)
- mppLibraryIos (from `../mpp-library`)
- MultiPlatformLibrary (from `../mpp-library`)
Expand All @@ -34,8 +38,12 @@ SPEC REPOS:
- AlamofireImage
- InputMask
- SkyFloatingLabelTextField
trunk:
- FloatingPanel

EXTERNAL SOURCES:
moko-widgets-bottomsheet:
:path: "../../"
moko-widgets-flat:
:path: "../../"
mppLibraryIos:
Expand All @@ -54,13 +62,15 @@ CHECKOUT OPTIONS:
SPEC CHECKSUMS:
Alamofire: 85e8a02c69d6020a0d734f6054870d7ecb75cf18
AlamofireImage: be9963c6582d68b39e89191f64c82a7d7bf40fdd
FloatingPanel: b275a35d0a09be4bd37025e710a6a1d063bfc161
InputMask: 8a10dbc8ac3f94f0a5b4c380424bbe6795c69b16
moko-widgets-bottomsheet: 68e942940b15bf0c6605675140d907fdb79db31d
moko-widgets-flat: 3d68acddc0469a1288ede5b5b63b6588de5aa5e1
mppLibraryIos: 72c3984fbaa53978d678e62096fd613e67839f0c
MultiPlatformLibrary: 176fb8ade516666cd47e93de1b71ba0441a541bb
MultiPlatformLibraryMvvm: 999ac3896d8214fd65e0e0a376a2e553bf4515b3
SkyFloatingLabelTextField: 4b46db0ab1ccde0919cded29c656e6b4805eda04

PODFILE CHECKSUM: b2d99b49a98817d6b9e5a4dd2b7596b74ced0389
PODFILE CHECKSUM: 4b3a5440fa9c919597e5ebac2ced886871ffb124

COCOAPODS: 1.8.4
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
5 changes: 3 additions & 2 deletions sample/ios-app/src/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@ class AppDelegate: NSObject, UIApplicationDelegate {

let app = App()
app.initialize()
ApplicationHolderKt.application = app

let screen = app.rootScreen.instantiate()
let rootViewController = screen.createViewController()
let rootViewController = screen.viewController

window = UIWindow(frame: UIScreen.main.bounds)
window?.rootViewController = rootViewController
window?.makeKeyAndVisible()
Expand Down
2 changes: 2 additions & 0 deletions sample/ios-app/src/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -56,5 +56,7 @@
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<true/>
</dict>
</plist>
4 changes: 3 additions & 1 deletion sample/mpp-library/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ val deps = listOf(
Deps.Libs.MultiPlatform.mokoUnits,
Deps.Libs.MultiPlatform.mokoGraphics,
Deps.Libs.MultiPlatform.mokoWidgets,
Deps.Libs.MultiPlatform.mokoWidgetsFlat
Deps.Libs.MultiPlatform.mokoWidgetsFlat,
Deps.Libs.MultiPlatform.mokoWidgetsBottomSheet
)

setupFramework(
Expand All @@ -56,5 +57,6 @@ cocoaPods {
podsProject = file("../ios-app/Pods/Pods.xcodeproj")

pod("moko-widgets-flat", "mokoWidgetsFlat", onlyLink = true)
pod("moko-widgets-bottomsheet", "mokoWidgetsBottomSheet", onlyLink = true)
pod("mppLibraryIos")
}
Loading

0 comments on commit dca618f

Please sign in to comment.