Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Viewport Trickery (v1.0)
Search
Jessica Stokes
August 05, 2015
Technology
0
55
Viewport Trickery (v1.0)
Putting responsive UIs atop desktop-only sites.
Presented at MelbMobile on 05/08/2015
Jessica Stokes
August 05, 2015
Tweet
Share
More Decks by Jessica Stokes
See All by Jessica Stokes
Viewport Trickery (v1.1)
ticky
0
330
Other Decks in Technology
See All in Technology
pmconf2025 - データを活用し「価値」へ繋げる
glorypulse
0
460
AI/MLのマルチテナント基盤を支えるコンテナ技術
pfn
PRO
5
730
翻訳・対話・越境で強いチームワークを作ろう! / Building Strong Teamwork through Interpretation, Dialogue, and Border-Crossing
ar_tama
4
1.6k
原理から解き明かす AIと人間の成長 - Progate BAR
teba_eleven
2
300
Microsoft Agent 365 を 30 分でなんとなく理解する
skmkzyk
1
310
私のRails開発環境
yahonda
0
180
32のキーワードで学ぶ はじめての耐量子暗号(PQC) / Getting Started with Post-Quantum Cryptography in 32 keywords
quiver
0
200
著者と読み解くAIエージェント現場導入の勘所 Lancers TechBook#2
smiyawaki0820
9
3.1k
Contract One Engineering Unit 紹介資料
sansan33
PRO
0
9.9k
Introduction to Sansan for Engineers / エンジニア向け会社紹介
sansan33
PRO
5
48k
Introduction to Sansan, inc / Sansan Global Development Center, Inc.
sansan33
PRO
0
2.9k
プラットフォームエンジニアリングとは何であり、なぜプラットフォームエンジニアリングなのか
doublemarket
1
550
Featured
See All Featured
Save Time (by Creating Custom Rails Generators)
garrettdimon
PRO
32
1.8k
Raft: Consensus for Rubyists
vanstee
140
7.2k
Optimizing for Happiness
mojombo
379
70k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
A Modern Web Designer's Workflow
chriscoyier
697
190k
The Language of Interfaces
destraynor
162
25k
The Straight Up "How To Draw Better" Workshop
denniskardys
239
140k
Site-Speed That Sticks
csswizardry
13
990
Making the Leap to Tech Lead
cromwellryan
135
9.6k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
46
7.8k
Done Done
chrislema
186
16k
The Cult of Friendly URLs
andyhume
79
6.7k
Transcript
Viewport Trickery or, putting responsive UIs atop desktop-only sites
Jessica Stokes Cybersorceress jessicastokes.net | @ticky
None
Photo by Patrick Lauke (CC-BY-NC-ND; Cropped) https://flic.kr/p/bTt6P8
Bugherd • Needs to work on desktop and mobile sites
• Responsive or not • On any device • Mobile browsers are liars • …for kinda reasonable reasons • position: fixed; // more-or-less useless on mobile
BugHerd Classic • Sidebar-based • Never handled mobile devices
None
New Bugherd • Simple layer over Stack, our task management
product • Just buttons and an issue report UI • Mobile-compatible, day 1
None
Solution? • Detect real zoom level and viewport position •
Scale and position the whole UI to suit
Viewporter • Tools for working with all sorts of browser
viewports • getScaleFactor getMobileScaleFactor for zoom detection • getViewportCoordinates for viewport location • Demo at https://macropodhq.github.io/viewporter https://github.com/macropodhq/viewporter | https://git.io/vOlJ9
PostCSS px to em • Makes your UI scalable •
Pixel measurements become ems • Base font size, 16px by default • Designers developers work in pixels for precision https://github.com/macropodhq/postcss-px-to-em | https://git.io/vOlUr
Jessica Stokes Cybersorceress jessicastokes.net | @ticky • Viewporter is available
at https://git.io/vOlJ9 • PostCSS px to em is available at https://git.io/vOlUr • Go make something cool with them!