项目
在 GitHub 查看
tregoning/photoTilt
关于
HTML5 clone of the photo tilt feature/gesture/ux found in Facebook's Paper app
设计与媒体实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- 0
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文Photo Tilt
HTML5 clone of the photo tilt feature/gesture/ux found in Facebook's Paper app.
Basic Usage
PhotoTilt (image url, container node)
var photoTilt = new PhotoTilt({
url: 'photo.jpg',
lowResUrl: 'lowRes.jpg', //optional it will load lowRes 1st if available
maxTilt: 18, //optional, defaults to 20
container: document.body //optional, defaults to body
reverseTilt: false //optional, defaults to false
});
Note: The speed of the tilt can be tweaked by updating the transform transtion speed in the CSS file.
Demo
You can find a working example here (make sure you test this on a device with a triaxial/accelerometer like a phone/tablet).
More
Blog post with extra information here.
TODO
- add option for full screen mode
- implement lockOrientation (only works in FF)
探索相关项目
加载中…