Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
chandu0101 committed Dec 28, 2017
1 parent 32b4a5b commit 21cf971
Show file tree
Hide file tree
Showing 17 changed files with 86 additions and 132 deletions.
3 changes: 1 addition & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
language: scala

scala:
- 2.12.2
- 2.11.11
- 2.12.4

jdk:
- oraclejdk8
Expand Down
22 changes: 11 additions & 11 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
name := "mobile"

//version := "2017.7.0-SNAPSHOT"
//version := "2017.12.0-SNAPSHOT"

enablePlugins(ScalaJSPlugin)

val scala211 = "2.11.11"

val scala212 = "2.12.2"
val scala212 = "2.12.4"

scalaVersion := scala211
scalaVersion := scala212

crossScalaVersions := Seq(scala211, scala212)
crossScalaVersions := Seq(scala212)

scalacOptions ++= Seq(
"-feature",
Expand All @@ -22,8 +21,8 @@ scalacOptions ++= Seq(
//Dependencies

libraryDependencies ++= Seq(
"scalajs-react-interface" %%% "universal" % "2017.7.9-RC" % Provided,
"scalajs-react-interface" %%% "core" % "2017.7.9-RC" % Provided)
"scalajs-react-interface" %%% "universal" % "2017.12.28-RC" % Provided,
"scalajs-react-interface" %%% "core" % "2017.12.28-RC" % Provided)

//bintray
resolvers += Resolver.jcenterRepo
Expand Down Expand Up @@ -71,12 +70,13 @@ def runJest() = {
if (jestResult != 0) throw new IllegalStateException("Jest Suite failed")
}

resolvers += Resolver.bintrayRepo("scalajs-react-interface", "maven")
resolvers += Resolver.bintrayRepo("scalajs-jest", "maven")
resolvers ++=Seq(Resolver.bintrayRepo("scalajs-react-interface", "maven"),
Resolver.bintrayRepo("scalajs-jest", "maven"),
Resolver.bintrayRepo("scalajs-plus", "maven"))

libraryDependencies ++= Seq(
"org.scala-js" %%% "scalajs-dom" % "0.9.3" % Test,
"scalajs-jest" %%% "core" % "2017.7.9-beta" % Test
"org.scala-js" %%% "scalajs-dom" % "0.9.4" % Test,
"scalajs-jest" %%% "core" % "2017.12.27-RC" % Test
)
//scalaJSStage in Global := FastOptStage
scalaJSStage in Global := FullOptStage
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@
},
"devDependencies": {},
"dependencies": {
"jest": "^20.0.4"
"jest": "^22.0.4"
}
}
2 changes: 1 addition & 1 deletion project/build.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
sbt.version=0.13.15
sbt.version=1.0.4

8 changes: 4 additions & 4 deletions project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.0.0-M1")
addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.0.0")
addSbtPlugin("com.dwijnand" % "sbt-dynver" % "1.3.0")
addSbtPlugin("me.lessis" % "bintray-sbt" % "0.3.0")
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.0.0-M2")
addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.1.0")
addSbtPlugin("com.dwijnand" % "sbt-dynver" % "2.0.0")
addSbtPlugin("org.foundweekends" % "sbt-bintray" % "0.5.2")
19 changes: 8 additions & 11 deletions src/main/scala/sri/mobile/components/StatusBar.scala
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects

import scala.scalajs.js
Expand Down Expand Up @@ -37,11 +33,12 @@ trait StatusBarProps extends js.Object {
object StatusBar {

@inline
def StatusBar(style: OP[js.Any] = NoValue,
@exclude extraProps: OP[StatusBarProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[StatusBarComponent.type, Unit] =
null)(children: ReactNode*)
def StatusBar(
style: OP[js.Any] = NoValue,
@exclude extraProps: OP[StatusBarProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[StatusBarComponent.type, Unit] = null)(
children: ReactNode*)
: ReactElement { type Instance = StatusBarComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
12 changes: 4 additions & 8 deletions src/main/scala/sri/mobile/components/WebView.scala
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.mobile.WebViewEvent
import sri.universal.components._
import sri.universal.{MergeJSObjects, ReactEvent}
Expand Down Expand Up @@ -43,8 +39,8 @@ trait WebViewProps extends ViewProps {
val injectedJavaScript: js.UndefOr[String] = js.undefined
val scalesPageToFit: js.UndefOr[Boolean] = js.undefined
val scrollEnabled: js.UndefOr[Boolean] = js.undefined
val onNavigationStateChange
: js.UndefOr[js.Function1[NavigationState, Unit]] = js.undefined
val onNavigationStateChange: js.UndefOr[js.Function1[NavigationState, Unit]] =
js.undefined
val bounces: js.UndefOr[Boolean] = js.undefined
val allowUniversalAccessFromFileURLs: js.UndefOr[Boolean] = js.undefined
val domStorageEnabled: js.UndefOr[Boolean] = js.undefined
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.android

import sri.core._
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.mobile.DrawerLayoutAndroidEvent
import sri.universal.{MergeJSObjects, ReactEvent}

Expand Down Expand Up @@ -71,8 +67,8 @@ object DrawerLayoutAndroid {
style: OP[js.Any] = NoValue,
@exclude extraProps: OP[DrawerLayoutAndroidProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[DrawerLayoutAndroidComponent.type, Unit] =
null)(children: ReactNode*)
@exclude ref: js.Function1[DrawerLayoutAndroidComponent.type, Unit] = null)(
children: ReactNode*)
: ReactElement { type Instance = DrawerLayoutAndroidComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.android

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects

import scala.scalajs.js
Expand Down Expand Up @@ -42,12 +38,11 @@ object ProgressBarAndroidStyle {
object ProgressBarAndroid {

@inline
def apply(
style: OP[js.Any] = NoValue,
@exclude extraProps: OP[ProgressBarAndroidProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[ProgressBarAndroidComponent.type, Unit] = null)(
children: ReactNode*)
def apply(style: OP[js.Any] = NoValue,
@exclude extraProps: OP[ProgressBarAndroidProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[ProgressBarAndroidComponent.type, Unit] =
null)(children: ReactNode*)
: ReactElement { type Instance = ProgressBarAndroidComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
package sri.mobile.components.android

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
rename,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects
import sri.universal.components._

Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.android

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects
import sri.universal.components._

Expand All @@ -24,8 +20,8 @@ object TouchableNativeFeedbackComponent
def SelectableBackgroundBorderless(): NativeFeedbackBackgroundType =
js.native

def Ripple(color: String,
borderless: Boolean): NativeFeedbackBackgroundType = js.native
def Ripple(color: String, borderless: Boolean): NativeFeedbackBackgroundType =
js.native

}

Expand Down
28 changes: 12 additions & 16 deletions src/main/scala/sri/mobile/components/android/ViewPagerAndroid.scala
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.android

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.mobile.ViewPagerAndroidEvent
import sri.universal.components._
import sri.universal.{MergeJSObjects, ReactEvent}
Expand Down Expand Up @@ -54,16 +50,16 @@ object KeyboardDismissModeViewPager {
object ViewPagerAndroid {

@inline
def apply(style: OP[js.Any] = NoValue,
initialPage: OP[Int] = NoValue,
onPageScrollStateChanged: OP[String => _] = NoValue,
onPageScroll: OP[ReactEvent[ViewPagerAndroidEvent] => _] = NoValue,
onPageSelected: OP[ReactEvent[ViewPagerAndroidEvent] => _] =
NoValue,
@exclude extraProps: OP[ViewPagerAndroidProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[ViewPagerAndroidComponent.type, Unit] =
null)(children: ReactNode*)
def apply(
style: OP[js.Any] = NoValue,
initialPage: OP[Int] = NoValue,
onPageScrollStateChanged: OP[String => _] = NoValue,
onPageScroll: OP[ReactEvent[ViewPagerAndroidEvent] => _] = NoValue,
onPageSelected: OP[ReactEvent[ViewPagerAndroidEvent] => _] = NoValue,
@exclude extraProps: OP[ViewPagerAndroidProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[ViewPagerAndroidComponent.type, Unit] = null)(
children: ReactNode*)
: ReactElement { type Instance = ViewPagerAndroidComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
28 changes: 12 additions & 16 deletions src/main/scala/sri/mobile/components/ios/DatePickerIOS.scala
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.ios

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects

import scala.scalajs.js
Expand Down Expand Up @@ -56,16 +52,16 @@ object MinuteInterval {

object DatePickerIOS {
@inline
def apply(style: OP[js.Any] = NoValue,
mode: OP[DatePickerIOSMode] = NoValue,
minuteInterval: OP[MinuteInterval] = NoValue,
timeZoneOffsetInMinutes: OP[Int] = NoValue,
onDateChange: OP[js.Date => _] = NoValue,
date: js.Date,
@exclude extraProps: OP[DatePickerIOSProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[DatePickerIOSComponent.type, Unit] =
null)
def apply(
style: OP[js.Any] = NoValue,
mode: OP[DatePickerIOSMode] = NoValue,
minuteInterval: OP[MinuteInterval] = NoValue,
timeZoneOffsetInMinutes: OP[Int] = NoValue,
onDateChange: OP[js.Date => _] = NoValue,
date: js.Date,
@exclude extraProps: OP[DatePickerIOSProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[DatePickerIOSComponent.type, Unit] = null)
: ReactElement { type Instance = DatePickerIOSComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.ios

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects
import sri.universal.components._

Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.ios

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects
import sri.universal.components._

Expand Down Expand Up @@ -43,8 +39,7 @@ object SegmentedControlIOS {
values: js.Array[String],
@exclude extraProps: OP[SegmentedControlIOSProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[SegmentedControlIOSComponent.type, Unit] =
null)
@exclude ref: js.Function1[SegmentedControlIOSComponent.type, Unit] = null)
: ReactElement { type Instance = SegmentedControlIOSComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
19 changes: 8 additions & 11 deletions src/main/scala/sri/mobile/components/ios/TabBarIOS.scala
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package sri.mobile.components.ios

import sri.core.{JSComponent, _}
import sri.macros.{
FunctionObjectMacro,
exclude,
OptDefault => NoValue,
OptionalParam => OP
}
import scalajsplus.macros.{FunctionObjectMacro, exclude, rename}
import scalajsplus.{OptDefault => NoValue, OptionalParam => OP}
import sri.universal.MergeJSObjects
import sri.universal.components._

Expand Down Expand Up @@ -94,11 +90,12 @@ object TabBarIOSC {
object TabBarIOSItem {

@inline
def apply(style: OP[js.Any] = NoValue,
@exclude extraProps: OP[TabBarIOSItemProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[TabBarIOSItemComponent.type, Unit] =
null)(children: ReactNode)
def apply(
style: OP[js.Any] = NoValue,
@exclude extraProps: OP[TabBarIOSItemProps] = NoValue,
@exclude key: String | Int = null,
@exclude ref: js.Function1[TabBarIOSItemComponent.type, Unit] = null)(
children: ReactNode)
: ReactElement { type Instance = TabBarIOSItemComponent.type } = {
val props = FunctionObjectMacro()
extraProps.foreach(v => {
Expand Down
Loading

0 comments on commit 21cf971

Please sign in to comment.