karma4u101 / fobo Goto Github PK
View Code? Open in Web Editor NEWFoBo - A Modular Front-End Toolkit module for Lift
Home Page: http://www.media4u101.se/fobo-lift-template-demo/
License: Apache License 2.0
FoBo - A Modular Front-End Toolkit module for Lift
Home Page: http://www.media4u101.se/fobo-lift-template-demo/
License: Apache License 2.0
I have Lift 2.6-M2.
And I try to use lift_advanced_bs3 template.
In User.scala, I commented 'override def skipEmailValidation = true'.
I can get the mail and the link for example as follows,
http://localhost:8080/user_mgt/reset_password/ZEX4QR0AMJP1WNP5GBHXPCJZ0ULJFICT
But, I can't access this link.
"The Requested URL /user_mgt/reset_password/ZEX4QR0AMJP1WNP5GBHXPCJZ0ULJFICT was not found on this server" is displayed.
In case of lift_basic, I can use it . Then I can recover my password.
Peter Petersson showed me the solution,
In code.module.User.scala comment out (or remove) this line
override def validateUserMenuLoc: Box[net.liftweb.sitemap.Menu] = Box(Empty)It should fix the issue with ... user_mgt/validate_user/ ... not found
Then, I have changed my cord in User.scala,
I've changed my code.
//override def resetPasswordMenuLoc: Box[net.liftweb.sitemap.Menu] = Box(Empty)
//override def validateUserMenuLoc: Box[net.liftweb.sitemap.Menu] = Box(Empty)
The problem has fixed.
Thank you very much
A new version fo jquery is out. Add suport for it in FoBo.
A third alternative for providing a editor component
https://github.com/toopay/bootstrap-markdown
This one is simple and shows some promises as it is in line with Lift's security thinking by using markdown.
It would probably also be fairly easy to switch out the provided markdown parser js and use Lifts own markdown parsers.
Rellaterat:
https://github.com/codemwnci/markdown-editpreview-ng.js
http://angular-markdown-text.nullest.com/#!/
Fix the internal link errors.
There is one proposition to make an additional file named "sbt-publish.bat" that will run:
sbt clean update compile package publish-local
So afte git pull, we can simply call sbt-publish.bat.
Maybe it is very small, but can be useful until package published publicly.
makese sense?
Hi ...
How can I add user authentication menu to "fobo" menu.
I modified fobo template based on lift-basic example but there is no user menu on screen.
code:
ps. I just started adventure with scala and Lift (FoBo ...) and it is really fantastic. Great job.
In this line:
https://github.com/karma4u101/FoBo/blob/develop/JQuery/build.sbt#L24
we depend on the jquery module, but the 2.8-SNAPSHOT version is gone from sonatype, this causes the lift advance template to failed to compile. you can change to the release version 2.8 to fix the issue.
Thanks
Diego
Hi. I have placed my own variables.less into /src/mail/less/variables.less
Then sbt update clean compile, then container:start - and then nothing changed at localhost:8080.
I tried to change linkColor and baseFontSize.
FoBoJQ.InitParam.ToolKit=FoBoJQ.JQueryXYZ
FoBoGCP.init() <<======= FoBoJQ.init()
(usage with FoBo is FoBo.InitParam.ToolKit=FoBo.JQueryXYZ) <<========= FoBo.InitParam.JQuery
The logical continuation will be to make testrun.bat for windows ;)
Consider textAngular as a component in FoBo's Component sub module
http://textangular.com/
http://ngmodules.org/modules/textAngular
https://github.com/fraywing/textAngular
Make the build system more flexible for release builds with liftmodule script.
Formulate a text that consciously describes the purpose of the FoBo module something along the lines of
The main purpose of FoBo is to provide a Lift module that includes front end toolkits for developers and designers to aid them in developing and designing mobile scalable reactive web applications.
if use under code
FoBo.InitParam.JQuery = FoBo.JQuery182
FoBo.InitParam.ToolKit = FoBo.Bootstrap222
FoBo.init()
can't find font-awesome.css file at page.
if use under code
FoBo.InitParam.JQuery = FoBo.JQuery182
FoBo.InitParam.ToolKit=FoBo.FontAwesome200
FoBo.init()
can find,but FontAwesome200 is deprecated?
Hi,
Any chance to get a build for Lift 2.5-M1?
In the meantime, I using this in sbt
"net.liftmodules" %% "fobo" % ( "2.5-SNAPSHOT" + "-0.6.0-SNAPSHOT") intransitive()
but the rest of my app uses Lift 2.5-M1
Thanks
Consider adding som image cropp functionality as a component in FoBo's Component sub module
Candidates is
http://www.croppic.net
https://github.com/alexk111/ngImgCrop
I use this module in a few applications and noticed that the twitter bootstrap files don't serve minimized in production mode. Any chance this could be added?
Thanks,
-Austen
pulled the latest FoBo and getting the following issue when running sbt:
/Users/naor/Dev/Projects/lift/Templating-With-Twitter-Bootstrap-master
==> sbt
2013-06-30 16:25:38 JRebel: Contacting myJRebel server ..
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: #############################################################
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: JRebel 5.3.0 (201305281348)
2013-06-30 16:25:39 JRebel: (c) Copyright ZeroTurnaround OU, Estonia, Tartu.
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: Over the last 1 days JRebel prevented
2013-06-30 16:25:39 JRebel: at least 4 redeploys/restarts saving you about 0.2 hours.
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: This product is licensed to Naor Yuval
2013-06-30 16:25:39 JRebel: for use with Scala classes only
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: License acquired through myJRebel server.
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: You are subscribed for the plan "JRebel Scala Plan",
2013-06-30 16:25:39 JRebel: subscription ends on 2014-06-28,
2013-06-30 16:25:39 JRebel: next license check with the server is required by 2013-07-01.
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: The following plugins are disabled at the moment:
2013-06-30 16:25:39 JRebel: * ADF Core plugin (set -Drebel.adf_core_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * ADF Faces plugin (set -Drebel.adf_faces_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Camel plugin (set -Drebel.camel_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Click plugin (set -Drebel.click_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Eclipse Plugin (set -Drebel.eclipse_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * JRuby Plugin (set -Drebel.jruby_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Jersey plugin (set -Drebel.jersey_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Log4j2 plugin (set -Drebel.log4j2_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Mustache Plugin (set -Drebel.mustache_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * RESTlet plugin (set -Drebel.restlet_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Seam-Wicket plugin (set -Drebel.seam_wicket_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Spring Data Plugin (set -Drebel.spring_data_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Thymeleaf Plugin (set -Drebel.thymeleaf_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * VRaptor plugin (set -Drebel.vraptor_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * Vaadin CDI utils plugin (set -Drebel.vaadin_cdiutils_plugin=true to enable)
2013-06-30 16:25:39 JRebel: * WebObjects plugin (set -Drebel.webobjects_plugin=true to enable)
2013-06-30 16:25:39 JRebel:
2013-06-30 16:25:39 JRebel: #############################################################
2013-06-30 16:25:39 JRebel:
[info] Loading global plugins from /Users/naor/.sbt/plugins
[error] scala.MatchError: 0.12.3 (of class java.lang.String)
[error] Use 'last' for the full log.
Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? last
[info] Loading global plugins from /Users/naor/.sbt/plugins
[debug] Running task... Cancelable: false, check cycles: false
[debug]
[debug] Initial source changes:
[debug] removed:Set()
[debug] added: Set()
[debug] modified: Set()
[debug] Removed products: Set()
[debug] Modified external sources: Set()
[debug] Modified binary dependencies: Set()
[debug] Initial directly invalidated sources: Set()
[debug]
[debug] Sources indirectly invalidated by:
[debug] product: Set()
[debug] binary dep: Set()
[debug] external source: Set()
[debug] All initially invalidated sources: Set()
[debug] Copy resource mappings:
[debug]
[debug] Other repositories:
[debug] Default repositories:
[debug] Raw(ProjectResolver(inter-project, mapped: ))
[debug] URLRepository(typesafe-ivy-releases,Patterns(ivyPatterns=List(http://repo.typesafe.com/typesafe/ivy-releases/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]), artifactPatterns=List(http://repo.typesafe.com/typesafe/ivy-releases/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]), isMavenCompatible=false))
[debug] URLRepository(sbt-plugin-releases,Patterns(ivyPatterns=List(http://scalasbt.artifactoryonline.com/scalasbt/sbt-plugin-releases/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]), artifactPatterns=List(http://scalasbt.artifactoryonline.com/scalasbt/sbt-plugin-releases/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext]), isMavenCompatible=false))
[debug] FileRepository(local,FileConfiguration(true,None),Patterns(ivyPatterns=List(${ivy.home}/local/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/artifact.[ext]), artifactPatterns=List(${ivy.home}/local/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/artifact.[ext]), isMavenCompatible=false))
[debug] public: http://repo1.maven.org/maven2/
[debug] Using inline dependencies specified in Scala.
scala.MatchError: 0.12.3 (of class java.lang.String)
at
at
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:49)
at sbt.EvaluateSettings$$anonfun$sbt$EvaluateSettings$$single$1.apply(INode.scala:159)
at sbt.EvaluateSettings$$anonfun$sbt$EvaluateSettings$$single$1.apply(INode.scala:159)
at sbt.EvaluateSettings$MixedNode.evaluate0(INode.scala:177)
at sbt.EvaluateSettings$INode.evaluate(INode.scala:132)
at sbt.EvaluateSettings$$anonfun$sbt$EvaluateSettings$$submitEvaluate$1.apply$mcV$sp(INode.scala:64)
at sbt.EvaluateSettings.sbt$EvaluateSettings$$run0(INode.scala:73)
at sbt.EvaluateSettings$$anon$3.run(INode.scala:69)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:722)
Update the contributing text to point to forking the develop branch.
Consider this as a component in FoBo's Component sub module
#50 my be better candidate
http://waxolunist.github.io/bootstrap3-wysihtml5-bower/
or try find something over at http://ngmodules.org/
Try extend the list-group snippet with collapsible sub menus as shown in this fiddle http://jsfiddle.net/JpJqD/84/
Bootstrap v2 snippets may due to name clashes (for instance FoBo.TBNavbar) pick up the bootstrap v3 equivalent.
OBS! Note that as of Apr 2013 there is a new version schema for Lift modules and FoBo module version >= 0.9.3 See the Dependency settings section for more information.
Hi Peter, have you looked at adding HTML5 Boilerplate and Foundation 3 to FoBo? Any objections if I do and submit a pull request (more interested in the former, no promises on the latter)?
Investigate
http://arshaw.com/fullcalendar/
Unidoc is now a sbt plugin [1] re-factor the build to use this plugin instead of the Unidoc include file.
Hello!
I tried to build my project and for some reason the mentioned repos at the FoBo GitHub page i.e.
"Media4u101 Repository" at "http://www.media4u101.se:8081/nexus/content/repositories/releases/",
"Media4u101 Snapshot Repository" at "http://www.media4u101.se:8081/nexus/content/repositories/snapshots/"
became unreachable:
[error] Server access Error: Connection refused url=http://www.media4u101.se:8081/nexus/content/repositories/snapshots/net/liftmodules/fobo_2.9.1/2.5-M1-0.7.2-SNAPSHOT/fobo_2.9.1-2.5-M1-0.7.2-SNAPSHOT.pom
So next - even-though I am a sbt newbie - I tried to clone the project and publish locally as instructed. Again with no luck. After the clone I run the publish-local script and it successfully published it in my home directory. But when I try to use my local repo from a project that uses FoBo ( say Templating-With-Twitter-Bootstrap) I get some error regarding unknown tags: artifactId, groupId... etc. although the created and published file clearly has them!. So it looked like an encoding problem to me (I am using OSX) I did some googling and apparently some had experienced the same problem in building and publishing locally sclalatra.
See this this issue here:
https://groups.google.com/forum/?fromgroups=#!msg/scalatra-user/lo2n5yoPo1U/S1B5hvJXrrYJ
I was wondering if your repos will come back online and if you have seen this seen this publish-local problem?
Thanks,
Rouzbeh
[error] {file:my_path/lift_samples/Templating-With-Twitter-Bootstrap/}default-c7aa48/*:update: sbt.ResolveException: unresolved dependency: net.liftmodules#fobo_2.9.1;2.5-M1-0.7.2-SNAPSHOT:
java.text.ParseException: [unknown tag project in file:/file:my_path/.ivy2/cache/net.liftmodules/fobo_2.9.1/ivy-2.5-M1-0.7.2-SNAPSHOT.xml.original
[error] , unknown tag modelVersion in file: my_path/.ivy2/cache/net.liftmodules/fobo_2.9.1/ivy-2.5-M1-0.7.2-SNAPSHOT.xml.original
....
Work has started to split the FoBo module into logical sub modules.
FoBo's jquery and font-awesome is already sub modules
The goal of this work is to also be able to provide stand-alone modules that end users can use on its own. The second goal is to make FoBo better structured and by that make it easier to grow and maintain. This work should not affect the end user.
Align sub-module version with the meta module version to simplify build system automation and maintenance.
Try break out the less compilation into a sub project that potentially also can be used in a user project as a add-on fobo module feature for the more advanced users that needs the extra tweaking possibility offered by bootstrap:s less setup (and potentially other future additons).
Some images is still in toserve/fobo/images they should be moved to there respective toolkit paths.
Respective css files has to be modified to take the new locations of images into account.
In bootstrap I've read that when your site runs under both http and https, the best is to use // on the beginning of static content, eg for <script> and <style> - eg the // is protocol-agnostic.
Is it handled somehow by Lift?
If not, then maybe there is sense to recommend (or at least mention) about this in your tutorial, eg:
I just cloned FoBo and ran ./sbt clean update less compile package publish-local
, got the following error. Removed 'less' from the command and it works fine. I assume this is an artifact of moving less out of FoBo and into to the FoBo-Less project?
> ./sbt clean update less compile package publish-local master [74b0d51]
[info] Loading global plugins from /home/kurtosis/.sbt/plugins
[info] Loading project definition from /home/kurtosis/bin/projects/lift/liftstack-build/modules/FoBo/project
[info] Set current project to FoBo (in build file:/home/kurtosis/bin/projects/lift/liftstack-build/modules/FoBo/)
[success] Total time: 0 s, completed Aug 24, 2012 1:42:18 PM
[warn] Credentials file /home/kurtosis/.sbt/.credentials does not exist
[info] Updating {file:/home/kurtosis/bin/projects/lift/liftstack-build/modules/FoBo/}FoBo...
[info] Resolving org.scala-lang#scala-library;2.9.1 ...
[info] Resolving net.liftweb#lift-webkit_2.9.1;2.4 ...
[info] Resolving commons-fileupload#commons-fileupload;1.2.2 ...
[info] Resolving net.liftweb#lift-util_2.9.1;2.4 ...
[info] Resolving commons-codec#commons-codec;1.4 ...
[info] Resolving nu.validator.htmlparser#htmlparser;1.2.1 ...
[info] Resolving javax.mail#mail;1.4.4 ...
[info] Resolving javax.activation#activation;1.1 ...
[info] Resolving joda-time#joda-time;1.6.2 ...
[info] Resolving net.liftweb#lift-actor_2.9.1;2.4 ...
[info] Resolving net.liftweb#lift-common_2.9.1;2.4 ...
[info] Resolving org.slf4j#slf4j-api;1.6.4 ...
[info] Resolving net.liftweb#lift-json_2.9.1;2.4 ...
[info] Resolving com.thoughtworks.paranamer#paranamer;2.3 ...
[info] Resolving org.scala-lang#scalap;2.9.1 ...
[info] Resolving org.scala-lang#scala-compiler;2.9.1 ...
[info] Resolving net.liftweb#lift-testkit_2.9.1;2.4 ...
[info] Resolving commons-httpclient#commons-httpclient;3.1 ...
[info] Resolving commons-logging#commons-logging;1.0.4 ...
[info] Done updating.
[success] Total time: 3 s, completed Aug 24, 2012 1:42:21 PM
[error] Not a valid command: less (similar: last, session, alias)
[error] Not a valid project ID: less
[error] Not a valid configuration: less (similar: test)
[error] Not a valid key: less (similar: licenses, test, clean)
[error] less
[error] ^
>
Remove text duplication at
"Where X is major, Y minor and Z incremental version numbers as seen in the Toolkits list above (for example BootstrapXYZ will be Bootstrap230 for Twitter Bootstrap v2.3.0) For more information on how to set this up see below."
In bootstrap.liftweb.Boot.Boot do something like this
//Set initparams, defaults are provided so no need to set the param if you always will use the latest versions
FoBoInitParams.jquery = JQuery141 || JQuery171 || ...
FoBoInitParams.toolkit = FoBo010 || FoBo020 || Foundation214 || Foundation215 || Bootstrap140 || Bootstrap200 || Blueprint101
//The init has to be present
Fobo.init()
In templates have something like this
link rel="stylesheet" type='text/css' href='/classpath/fobo/fobo.css' ||
link rel="stylesheet" type='text/css' href='/classpath/fobo/foundation.css' ||
link rel="stylesheet" type='text/css' href='/classpath/fobo/bootstrap.css' ||
Find a way to path rewrite to the actual css paths like
.../fobo.css ==>> /classpath/fobo/css/fobo-[version].css
.../bootstrap.css =>> /classpath/fobo/orgin/css/bootstrap-[version].css
Scripts
script type="text/javascript" src="/classpath/fobo/jquery.js"
script type="text/javascript" src="/classpath/fobo/bootstrap-twipsy.js"
script type="text/javascript" src="/classpath/fobo/bootstrap-dropdown.js"
script type="text/javascript" src="/classpath/fobo/bootstrap-popover.js"
script type="text/javascript" src="/classpath/fobo/bootstrap-scrollspy.js"
rewrite
../jquery.js ==>> /classpath/fobo/js/jquery-[version].js
In the fobo lift module have something like this
trait/object ? FoBoInitParams {
// enumerate params here
}
case ojbect FoBoJQuery extends FoBoInitParams {
def pathRewriter: PartialFunction[List[String], List[String]] = {
case "fobo" :: "jquery.js" :: Nil if Props.devMode => List("fobo","js","jquery-1.7.1.js") //default version
}
}
case ojbect FoBoToolkit extends FoBoInitParams {
def pathRewriter: PartialFunction[List[String], List[String]] = {
case "fobo" :: "bootstrap.css" :: Nil if Props.devMode => List("fobo","orgin","css","bootstrap-2.0.0.css") //default version
}
}
case object JQuery171 extends FoBoJQuery {
override def pathRewriter: PartialFunction[List[String], List[String]] = {
case "fobo" :: "jquery.js" :: Nil if Props.devMode => List("fobo","js","jquery-1.7.1.js")
// case "fobo" :: "jquery.js" :: Nil => List(fobo","js","jquery-1.7.1-min.js")
}
}
case object Bootstrap140 extends FoBoToolkit {
override def pathRewriter: PartialFunction[List[String], List[String]] = {
case "fobo" :: "bootstrap.css" :: Nil if Props.devMode => List("fobo","orgin","css","bootstrap-1.4.0.css")
}
}
:
:
Unresolved dependency: liftmodules#fobo_2.9.1;2.4-0.3.3-SNAPSHOT
What resolver must I add to my build.sbt?
Thanks.
Has some interesting component additions
http://addyosmani.github.com/jquery-ui-bootstrap/
A good resource is in the akka project ( as pointed out by Daniel Roziecki in
https://groups.google.com/forum/?fromgroups=#!topic/liftweb/bskux9pNVFc )
See
https://github.com/akka/akka/blob/master/project/Unidoc.scala
This plugin is helpfull for projects that relay on api functions that has been removed in newer jquery versions (1.9+)
https://github.com/jquery/jquery-migrate/
Add less build option to build.sbt to make it possible to tweak bootstrap during build via the use of bootstrap.less => bootstrap.css generation.
[1] https://github.com/softprops/less-sbt
Questions/request/discussion is here
https://groups.google.com/forum/#!topic/liftweb/264v24dVpmw
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.