Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Design @1x #324

Closed
wants to merge 3 commits into from
Closed

Design @1x #324

wants to merge 3 commits into from

Conversation

peteschaffner
Copy link
Contributor

I'm back :)

@koenbok I simplified my approach from #228, but now need a little help from you to get this in an acceptable state to merge.

Must-haves

  • when importing from Sketch/Photoshop, honor Framer.Device.contentScale by drawing all imported layers at the appropriate size (divided by the scale factor)

I'm a bit confused with the existing behavior because if I import a design drawn at 1x using the new importer scaling feature, all my layer dimensions are scaled by that factor, yet the layerFrame and image.frame values in the generated JSON are relative (at 1x) values.

Nice-to-haves

  • trigger a refresh of the device context when changing orientation so that it is not necessary to reload the preview (this would be great to trigger on device as well if it is possible)
  • make the viewport meta tag generator DRY (maybe create a build step for including a factored-out version of the function both in index.html and DeviceComponent.coffee)
  • consider making a less explicit API that requires direct knowledge of device scale factors and make something more implicit like DeviceComponent#relativeUnits and then do the extra legwork to add the appropriate contentScale properties to the built-in device configurations
  • test(s) for fullscreen and simulated device contexts

Pete Schaffner added 3 commits April 12, 2016 14:24
- don't mess with @Viewport
- don't mess with rotation
- update viewport scaling for mobile devices
@nvh
Copy link
Collaborator

nvh commented Aug 1, 2016

@peteschaffner I'm doing some cleanup, is this still relevant? If yes, could you explain the situation and provide some examples?

@nvh
Copy link
Collaborator

nvh commented Jun 15, 2017

As we added support for pixel ratio independent design in Framer Design, I'm closing this. Feel free to open up a new issue or pull request to discuss it further.

@nvh nvh closed this Jun 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants