Skip to content

Commit

Permalink
Fix: disable test of scrollspy
Browse files Browse the repository at this point in the history
  • Loading branch information
romainreuillon committed Jun 15, 2020
1 parent 59c02a2 commit 8c90e13
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
5 changes: 3 additions & 2 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -144,14 +144,15 @@ lazy val scrollspy = project
sharedSettings,
scalaVersion := Constants.scala213,
crossScalaVersions := supportedScalaVersion,
scalacOptions += "-P:scalajs:suppressExportDeprecations", // see https://github.com/scala-js/scala-js/issues/3092
//scalacOptions += "-P:scalajs:suppressExportDeprecations", // see https://github.com/scala-js/scala-js/issues/3092
libraryDependencies ++= Seq(
"org.scala-js" %%% "scalajs-dom" % "0.9.8",
"org.scala-js" %%% "scalajs-dom" % "1.0.0",
"com.lihaoyi" %%% "scalatags" % Constants.scalaTags,
"io.circe" %%% "circe-core" % Constants.circe,
"io.circe" %%% "circe-generic" % Constants.circe,
"io.circe" %%% "circe-parser" % Constants.circe
),
test := {},
//emitSourceMaps := false,
noPublish
)
Expand Down
5 changes: 2 additions & 3 deletions scrollspy/src/main/scala/scalatex/scrollspy/Controller.scala
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import org.scalajs.dom.ext._
import org.scalajs.dom.html

import scalajs.js
import scalajs.js.annotation.JSExport
import scalajs.js.annotation._
import scalatags.JsDom.all._
import scalatags.JsDom.tags2
import io.circe._, io.circe.generic.auto._, io.circe.parser._, io.circe.syntax._
Expand All @@ -26,7 +26,6 @@ class Toggler(var open: Boolean,
}
}

@JSExport
object Controller{
lazy val styleTag = tags2.style.render
dom.document.head.appendChild(styleTag)
Expand All @@ -36,7 +35,7 @@ object Controller{
name.replace(" ", "")
}

@JSExport
@JSExportTopLevel("scalatexScrollspyController")
def main(data: js.Any) = {
(new Controller(data)).init()
}
Expand Down
4 changes: 2 additions & 2 deletions site/src/main/scala/scalatex/site/Sidebar.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import io.circe._, io.circe.generic.auto._, io.circe.syntax._

object Sidebar {
def snippet(tree: Seq[Tree[String]]) = script(raw(s"""
scalatex.scrollspy.Controller().main(
scalatexScrollspyController(
${tree.asJson}
)"""))
)"""))
def autoResources = Seq(resource/'scalatex/'scrollspy/"scrollspy.js")
}

0 comments on commit 8c90e13

Please sign in to comment.