Permalink
Browse files

Don't show hints while preloading

  • Loading branch information...
koenbok committed Aug 3, 2016
1 parent daa910b commit d34658d324b604eb1bacc3eea16b2558cf0f1054
Showing with 18 additions and 13 deletions.
  1. +8 −11 extras/Studio.framer/app.coffee
  2. +5 −0 framer/Extras/Hints.coffee
  3. +5 −2 framer/Framer.coffee
@@ -1,14 +1,11 @@
Framer.Extras.Preloader.enable()
Framer.Extras.Hints.enable()
Framer.Extras.ShareInfo.enable()
# Activate Module
Framer.Info =
author: "Eelco Lempsink"
twitter: "@fverloop"
title: "Here's a long af title is long seri"
description: """
Our goal with Framer has always been to build a full service design tool. So while it’s been possible to view working prototypes on a mobile browser, the experience has been less than seamless.
Then, our community came to the rescue. Both Frameless by Jay Stakelon and Frames by Rafael Conde set a new standard for mobile viewing of prototypes. Inspired by their work and your feedback, we are now launching an iOS app that fully rounds out your design experience framerjs.com.
Framer for iOS features live preview, offline use and intuitive sharing features that are protected by secure links. Paired with Framer for Mac, you now have access to a full mobile prototyping toolkit.
"""
for i in [0..10]
layer = new Layer
y: i * 210
layer.image = Utils.randomImage() + "?cache=" + Date.now()
layer.onClick ->
@@ -14,9 +14,11 @@ class Hints
Events.wrap(document).addEventListener("mouseup", @_handleUp, capture=true)
_handleDown: (event) =>
return if @_isPreloading()
@_target = event.target
_handleUp: (event) =>
return if @_isPreloading()
# See what layer we actually tapped
layer = Framer.CurrentContext.layerForElement(@_target)
@@ -27,6 +29,9 @@ class Hints
@showHints()
_isPreloading: ->
return Framer.Preloader?.isLoading is true
showHints: ->
context = Framer.CurrentContext
@_context.run => _.invokeMap(context.rootLayers, "_showHint")
View
@@ -74,7 +74,10 @@ Framer.Extras.ErrorDisplay.enable() if not Utils.isFramerStudio()
Framer.Extras.Preloader.enable() if not Utils.isFramerStudio()
Framer.Extras.Hints.enable() if not Utils.isFramerStudio()
startAfterPreloader = ->
Utils.domComplete(Framer.Loop.start)
if Framer.Preloader?
Framer.Preloader.once("end", Framer.Loop.start)
Framer.Preloader.once("end", startAfterPreloader)
else
Utils.domComplete(Framer.Loop.start)
startAfterPreloader()

0 comments on commit d34658d

Please sign in to comment.