Blog1 min read
Introducing Duo: a folding iPhone you can build for
A web page that folds, an OS that runs twice, and a sandbox for strangers’ code. Drag every figure.
A folding phone lives between 0° and 180°. A mockup shows the two ends. So we built the phone.
Duo is an unofficial, experimental project by Doan Labs. It is not an Apple product and is not affiliated with Apple.
Two ways to draw a screen
DOM can take typing but can't bend. A texture can bend but can't take typing. Duo uses both and swaps between them:








- Surface
- Live DOM
- Typeable
- Yes
- Bends
- No
- Column
- 70 px
A fixed eye
The bent glass shows whatever the flat panel showed along a ray from one eye, fixed at 40 cm:
- Lead display
- Inner
- Mirror copy
- Cover
- Cover glass
- 100%
- Inner surface
- Projected
Run the OS twice
One OS per display. The cover is the inner grid's left four columns, and both copies are always running:
















inner · os.mirror = falsecover · os.mirror = true- Lead display
- Inner
- Running copy
- Inner
- Mirror copy
- Cover
- Fetches from
- Inner only
The real shell, not a recording:
Measured, not eyeballed
Every radius comes off Apple's mesh. Every swipe follows the finger through a paused animation:

currentTime = 0 ms- Inner glass
- R 10.7 mm
- Cover free edge
- R 11.4 mm
- Cover hinge edge
- R 1.3 mm
- Bezel
- 1.2 mm
A sandbox for strangers' code
Duo, taken apart. Tap a layer:
- Layer
- App
- Trust
- Sandboxed
- Runs as
- an opaque iframe
- Below the line
- No
Below is a stranger's app, running for real in the same sandbox. Watch it try to get out:
- Escapes blocked
- 0 / 6
- Hash
- Matches
- Nonce
- One use
- View
- …
Then the part developers touch:
1// The hinge, live: 0 is closed, 180 flat. At most one event a frame.2os.onView((v) => {3lid.style.transform = `rotateX(${180 - v.angle}deg)`4})