Orbit motion: shared timings, gliding focus, sliding screens, EffectCraft moments (0.108.58)
From the approved motion sheet: one set of timings for moving around the app (focus eases, gold glides on Home and the top bar, screens slide on, cards rise in turn, pop-up cards dim and rise, the guide eases), all following Reduce motion. Four EffectCraft moments built by design/motion/build-moments.py: Welcome, Rooms linked, an opening for each Arcade game, and Tuning in while Orbit opens. Any button skips a moment. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package tv.orbit.classic
|
||||
|
||||
import org.junit.Assert.*
|
||||
import org.junit.Test
|
||||
|
||||
/** Orbit motion (Paul, 6 November 2026, design/motion): one set of timings, and a moment for every Arcade game. */
|
||||
class MotionTest {
|
||||
@Test fun screensSlideFromTheSideTheyLieOnAlongTheBar() {
|
||||
assertEquals(1, sectionDirection("Home", "TV Guide"))
|
||||
assertEquals(-1, sectionDirection("Arcade", "Home"))
|
||||
assertEquals(1, sectionDirection("Home", "Connect Emby"))
|
||||
}
|
||||
|
||||
@Test fun everyArcadeGameHasItsOpening() {
|
||||
for (game in listOf("OrbMan", "Blast", "Sky", "Hive", "Snake", "Blocks", "Bricks", "Pairs", "Patience")) assertNotNull(game, Moment.forGame(game))
|
||||
assertNull(Moment.forGame("Welcome".lowercase()))
|
||||
}
|
||||
|
||||
@Test fun theTimingsMatchTheSheet() {
|
||||
assertEquals(140, Motion.FOCUS); assertEquals(240, Motion.SCREEN); assertEquals(200, Motion.BACK)
|
||||
assertEquals(180, Motion.CARD); assertEquals(40, Motion.STAGGER); assertEquals(220, Motion.GUIDE); assertEquals(120, Motion.CALM)
|
||||
assertTrue(Motion.BACK < Motion.SCREEN)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user