Mosmoxmosmox

Mosmox journal

In focus — mobile UI.

A selection of publications grouped under the mobile UI tag.

Adaptive Apps for Foldables and Googlebook: What Google Play Will Start Looking At

Adaptive Apps for Foldables and Googlebook: What Google Play Will Start Looking At

Google has warned developers that next year Google Play will look more closely at how apps and games run on foldables and will offer more opportunities to showcase adaptive products. Specific store requirements are promised later this year. Until they appear, the best preparation is to understand what Google counts as adaptive quality and to fix weak spots now.

What is known today

In its October Android Dev Summit announcement, Google linked two things. First, with the arrival of Googlebook, apps can scale across phones and laptops without a separate codebase. Second, next year Google Play will look closely at how apps run on foldables. Details are promised "later this year", so there are no official requirements at the time of writing. For apps, Google advises following the Adaptive app quality guidelines; for games, a separate set of adaptive games guidelines.

Three tiers of adaptive quality

TierNameIn short
Tier 3 (basic)Adaptive readyThe app runs full screen or full window on all devices, without letterboxing or compatibility mode; basic support for keyboard, mouse, trackpad and stylus
Tier 2 (better)Adaptive optimizedLayout optimizations for all screen sizes and configurations, with enhanced support for external input devices
Tier 1 (best)Adaptive differentiatedAn experience designed for the device: multitasking, foldable postures, drag and drop, stylus

To earn the Large Screen Badge on Google Play, Google says to complete Tier 2 (optimize for all screen sizes) and Tier 1 (a differentiated experience for large screens). Google also notes that your app probably does not need to meet every requirement: implement the ones that make sense for your use cases.

How to test

According to Google, layout and UX testing should cover at least these device types:

  • Googlebook (160 ppi);
  • foldable (841×701 dp);
  • 8-inch tablet (1024×640 dp);
  • 10.5-inch tablet (1280×800 dp);
  • 13-inch Chromebook (1600×900 dp).

Android Studio provides emulators for this: Pixel Fold for foldables, Medium Tablet for tablets and Desktop (Preview) for desktop, which needs a Canary build. There is also the resizable emulator for arbitrary configurations.

What breaks first

Google states plainly that when screens fold, windows resize and apps move across form factors, usual layout assumptions can break and apps easily lose state. So your checklist should include:

  • State preservation when folding and unfolding, resizing the window and rotating.
  • Multi-pane layouts instead of a stretched phone screen (Grid, FlexBox, Navigation 3, WindowManager).
  • Tabletop posture for camera and media screens.
  • External input: keyboard shortcuts, hover states, tooltips, trackpad and mouse cursors.
  • Tablet and foldable screenshots on your Google Play listing: Google recommends showing the app on these devices and mentioning it in the description.

Speeding up work with agents

The updated Compose Adaptive skill helps agents turn compact screens into responsive multi-pane layouts and handle state and configuration changes. According to Google, it now adds foldable and desktop support: windowing, keyboard shortcuts, tooltips and trackpad hover states. The skill also audits Compose UI for these elements and refactors camera and media screens into tabletop layouts. It is a tool for a first-draft audit, but the result still needs manual checks on real devices.

Where to start in your project

  1. Find your current tier: go through the Tier 3 checklist and make sure the app does not run in compatibility mode.
  2. Run a critical flow on a foldable emulator while folding and resizing.
  3. Fix state loss before polishing visuals.
  4. Add keyboard and mouse support for the main actions.
  5. Update your store listing with large-screen screenshots.
  6. Watch for the Google Play announcement on requirements and opportunities for adaptive apps.

For more on technical approaches, see our article on tablet and foldable apps and our comparison of SwiftUI, Compose and classic Views.

Adaptivity is no longer a nice extra: it is becoming a visible quality signal in the store. Teams that start with state preservation and basic layouts will be ready before the requirements appear.

Sources: Android Developers Blog: Agentic and Flexible: A next era of Android development; Android Developers: Adaptive app quality guidelines; Android Developers Blog: Build for every screen with the latest Jetpack Compose updates.

Dark Mode: Why Adding a Toggle Is Not Enough

Dark Mode: Why Adding a Toggle Is Not Enough

Dark mode is not a colour inversion or a decorative toggle in settings. It has to preserve hierarchy, contrast, readability and clear states across the whole product: from the home screen to the rarely opened account deletion dialog.

System-wide dark mode arrived with iOS 13 and Android 10, and since then users expect apps to adapt automatically. In our projects we regularly see the same picture: dark mode is "added" in a sprint, and then for six months the team fixes invisible borders, "glowing" images and red errors that suddenly became unreadable on a dark background. Here's how to do it once and do it right.

What breaks with a quick inversion

  • Grey text loses contrast. A shade that worked well on white can drop below 4.5:1 on a dark background.
  • Shadows disappear. On a dark surface a shadow is barely visible, so cards blend into the background unless depth is conveyed another way.
  • Borders become too bright or, conversely, vanish entirely.
  • Images glare. Illustrations and photos with white backgrounds look like a flashlight in the middle of the screen.
  • Statuses lose distinction. Saturated red and green on a dark background either "vibrate" or become too dark.
  • Third-party components don't adapt. WebViews, payment SDKs, maps and support chat stay light and break consistency.

Why the same colours don't work on a dark background

Numbers make the strongest case. We calculated the contrast of typical light-theme colours on white and on the #121212 dark surface recommended by Material Design.

ColourOn whiteOn #121212Verdict
#B00020 (dark "error" red)7.33:12.56:1unreadable on dark
#2E7D32 (dark "success" green)5.13:13.65:1fails for normal text
#1976D2 (blue accent)4.6:14.07:1borderline; text needs a lighter tone
#CF6679 (lighter red)—5.2:1suitable for errors in dark mode
#90CAF9 (light blue)—10.71:1a reliable dark-mode accent
White at 60% opacity (secondary text)—7.16:1passes
White at 38% opacity (disabled)—3.57:1acceptable only for inactive states

The takeaway is simple: every accent and status colour needs a separate, usually lighter and less saturated tone for dark mode. Material Design recommends exactly that — using lighter tones of the palette instead of saturated primaries. We covered contrast thresholds in more detail in our guide to large text, contrast and scaling.

Start with roles, not hex values

Dark mode is impossible to maintain if the code is full of hundreds of specific colours. You need a layer of semantic tokens: surface, elevated surface, primary text, secondary text, border, accent, danger, success, warning. Each token has two values — light and dark — and components reference tokens only.

  • iOS provides this out of the box: system colours such as systemBackground, secondarySystemBackground, label and secondaryLabel already adapt to the theme. Custom colours are defined in the Asset Catalog with Any and Dark variants, plus a High Contrast variant.
  • Android uses values-night and drawable-night resources and a DayNight-based theme, and in Jetpack Compose darkColorScheme and lightColorScheme in MaterialTheme.
  • Depth. Instead of shadows, dark mode conveys elevation with a lighter tone: the higher the element, the lighter the surface. Apple also distinguishes base and elevated backgrounds for modal screens.
  • Black or dark grey. Material recommends #121212 instead of pure black: dark grey shows shadows and surface levels, and the extreme contrast of white text on black makes letters look blurry for some people.

Images, illustrations and third-party content

  • Prepare separate variants for illustrations and icons, or use vector assets that take their colours from tokens.
  • Don't invert photos, but you can slightly reduce their brightness or add a subtle border so they don't "glow".
  • Partner logos often exist only in a light version — plan a backing plate for them.
  • For WebView on Android 13+, enable algorithmic darkening or pass the theme to the web page through prefers-color-scheme.
  • Check whether payment, maps and support SDKs support dark mode and how to configure them.

On energy efficiency: a 2021 Purdue University study showed that on OLED screens, switching to dark mode at 100% brightness saves 39–47% power on average, but at typical 30–50% brightness only 3–9%. So dark mode is primarily about comfort and accessibility, not battery life.

How to check quality

  1. Walk through key scenarios in both themes, and switch themes in the middle of a scenario: the app must not lose state or entered data.
  2. Lower screen brightness to the minimum and check that field borders and dividers are visible.
  3. Turn on larger text and Increase Contrast — dark mode needs a high-contrast variant too.
  4. Check contrast for the default, disabled, pressed, focus and error states of each component, not a single screenshot.
  5. Review all images, illustrations and empty states.
  6. Open every screen with third-party content: WebView, payments, maps, chat.
  7. Add screenshot tests for both themes so new components don't break the system.

Typical mistakes

  • Colours hard-coded inside components, bypassing tokens: these are the first to stay white.
  • A toggle only in the app's settings, with no "Match system" option.
  • Pure black backgrounds with bright white text in large blocks.
  • Saturated brand colours without adaptation, which "vibrate" on a dark background.
  • Relying on Android's Force Dark as the final solution: it's a quick start, not design.
  • Testing only the home screen while dialogs, bottom sheets and push-driven screens go unchecked.

Implementation checklist

  1. Create semantic colour tokens and ban hex values inside components.
  2. Pick dark variants for every accent and status colour with at least 4.5:1 contrast for text.
  3. Convey depth through surface tone, not just shadow.
  4. Prepare image variants and backing plates for logos.
  5. Configure dark mode in WebView and third-party SDKs.
  6. Add a "Match system" option and make it the default.
  7. Cover both themes with screenshot tests and a manual pass through key scenarios.

Dark mode is a test of the design system: if the team can't explain a colour's role, it's hard to scale. And the best dark mode doesn't look like a different product — users recognise components, understand statuses and perform the same actions without relearning anything. If the interface has animations, check them too: dark transitions with abrupt brightness jumps are tiring, as we discussed in our article on animation in mobile interfaces.

Sources: Android Developers: What a great user experience looks like; Android Developers: Implement dark theme; Apple Human Interface Guidelines: Dark Mode; Material Design: Dark theme; Purdue University: Dark mode may not save your phone's battery life as much as you think.

Animation in Mobile Interfaces: When It Helps and When It Slows Users Down

Animation in Mobile Interfaces: When It Helps and When It Slows Users Down

Animation can explain a change of state, show the relationship between elements and make the interface's response tangible. But it can also delay an action, eat up the resources of a weak device and cause nausea in people who are sensitive to motion.

In our projects, debates about animation usually sound like "is it pretty or not". A more productive question is: what exactly does this motion explain to the user, and how much time does it take from them? Below are the criteria, numbers and testing routine we use to make animation work for the product rather than against it.

When motion makes sense

Functional animation answers one of four user questions:

  • Where did this come from? A card expands from the list item that was tapped, and the person understands how the screens relate.
  • Did the system hear me? A button reacts to the touch instantly, before the server responds.
  • What's happening now? A progress indicator shows that a request is running and the app hasn't frozen.
  • Did it work? A short completion confirmation removes the need to check the result manually.

If an animation answers none of these questions, it's most likely decorative. Decorative motion isn't forbidden, but it should be short, never block the main action, and switch off or simplify when the system reduce-motion setting is on.

Numbers worth keeping in mind

The classic response-time limits formulated by Jakob Nielsen still hold: about 0.1 s feels instantaneous, up to 1 s keeps the flow of thought uninterrupted, and beyond 10 s the person loses focus on the task. Transition animations live between the first and second limits.

Type of motionApproximate durationComment
Touch feedback (ripple, button state change)start within 100 msmust begin immediately, even if the action is still running
Small changes (switch, checkbox, icon)50–200 msshort tokens in Material 3
In-screen transitions, expanding a card250–400 msmedium tokens in Material 3
Full-screen transitions450–600 mslong tokens; longer only with a strong reason
Single-frame budget16.7 ms at 60 Hz, 8.3 ms at 120 Hzanything that doesn't fit is seen as a stutter

Android documentation distinguishes slow frames (16 to 700 ms), frozen frames (700 ms to 5 s) and ANRs, when the app doesn't respond to input for more than 5 seconds. A heavy animation on a weak device easily pushes a product over these limits. That's why we always test motion on inexpensive devices, not only on the developer's flagship.

Reduced motion and motion sensitivity

For people with vestibular disorders, parallax, full-screen zooms and fast rotations can trigger dizziness and nausea. According to a study by Agrawal and colleagues (Archives of Internal Medicine, 2009) based on the 2001–2004 NHANES national survey, 35.4% of US adults aged 40 and over showed signs of vestibular dysfunction. This is not a niche group.

Both platforms provide a signal you should respond to:

  • iOS: the Reduce Motion setting; in code, UIAccessibility.isReduceMotionEnabled or the accessibilityReduceMotion environment value in SwiftUI.
  • Android: the "Remove animations" setting sets the system animation duration scale to zero; you can check it via ValueAnimator.areAnimatorsEnabled().

Reducing motion doesn't mean removing all change. Replace slides and zooms with a gentle opacity fade, and parallax with a static background. WCAG criterion 2.3.3 (level AAA) explicitly recommends letting users disable motion triggered by interaction, and 2.2.2 requires that any automatic motion lasting longer than 5 seconds can be paused. For the broader context, see our article on mobile app accessibility.

Animation and performance: the Gmail Wear OS case

The clearest public example of what decorative motion costs is the Gmail team's Wear OS case study on Android Developers. While analysing a startup trace in Perfetto, the team saw CPU contention on a watch with two cores. They replaced the animated loading spinner with a single static image and deferred the shimmer state by prolonging the splash screen. That group of changes improved startup latency by 50%. The loading indicator itself was slowing down the very thing it was meant to report on.

On phones the effect is usually less dramatic, but the mechanics are the same: animation on the main thread competes with building the first screen, processing data and responding to touch.

How to test: not just the looks

  1. For every animation in the mock-ups, write down which of the four questions it answers. If none, shorten it or remove it.
  2. Compare the time to complete a key scenario with and without animation. On Android you can temporarily change the animation duration scale in developer options.
  3. Run the scenario on a weak device and capture FrameTimingMetric with Macrobenchmark, or look at Profile GPU Rendering.
  4. Test interruptions: what happens if you press Back in the middle of a transition or tap a button twice quickly?
  5. Turn on Reduce Motion and "Remove animations" and make sure the interface doesn't break and states stay clear.
  6. Test repeat visits: an animation that delights the first time is annoying the twentieth time.

Typical mistakes

  • Blocking animation: the button stays inactive until the transition ends, and a fast user "taps into the void".
  • A splash screen with a logo animating for 2–3 seconds even though the app is ready earlier.
  • Skeletons and shimmer where data arrives in 100 ms: the user sees flicker instead of content.
  • Ignoring reduced motion: parallax and full-screen zooms for everyone without exception.
  • Large Lottie animations on the first screen that increase both build size and startup time.
  • Animations synchronised with network requests that "freeze" when the response is delayed.

Pre-release checklist

  1. Every animation has a functional justification.
  2. Touch feedback starts within 100 ms; transitions fit into 200–400 ms.
  3. No animation blocks the main action.
  4. Reduce Motion on iOS and "Remove animations" on Android are supported.
  5. Automatic motion longer than 5 seconds can be paused.
  6. Key scenarios are checked on a weak device using FrameTimingMetric.
  7. The first screen doesn't run heavy animations before it becomes useful.

The goal of animation is not to show off the team's skill but to help the user understand what happened. If motion makes the wait longer, it works against the product.

Sources: Android Developers: What a great user experience looks like; Android Developers: Gmail Wear OS startup case study; Material Design 3: Easing and duration; Android Developers: Slow rendering; W3C: Understanding SC 2.3.3 Animation from Interactions; Agrawal et al.: Disorders of balance and vestibular function in US adults (2009); Nielsen Norman Group: Response Times — The 3 Important Limits.

Large Text, Contrast, and Scaling: A Practical Guide to Mobile UI

Large Text, Contrast, and Scaling: A Practical Guide to Mobile UI

A mobile interface has to stay readable beyond the designer's mock-up. A user may enlarge the system font, raise contrast, turn on bold text or a screen reader, or look at the screen in bright sunlight. If the layout falls apart under those conditions, it's a product problem, not the user's personal problem.

This guide collects what we apply on our own projects: how system scaling actually works on iOS and Android, which contrast numbers to check, how to build components that survive 200% text, and what breaks most often.

How system scaling works

On iOS, text size is controlled by Dynamic Type. The user picks one of seven standard sizes, and in the accessibility settings five more enlarged ones (AX1 to AX5). The Body style is 17 pt by default and 53 pt at the largest AX5 size, roughly three times bigger. Separate Bold Text and Increase Contrast settings also change how the interface looks.

On Android, text size is defined in sp units, multiplied by the system font scale. Starting with Android 14, that scale can reach 200%, and scaling is non-linear: small text grows more, while large headings grow more moderately so they don't take over the screen. Separately from the font, the user can change "Display size", which enlarges all interface elements, not just text.

The practical takeaway is simple: you need to check not one but at least three states — default, enlarged and maximum — and combine them with long localised strings.

Typography that scales

The core rule: no fixed text sizes that bypass the system. On iOS, use text styles (body, headline, caption) or UIFontMetrics for custom fonts; in SwiftUI, a custom font can be tied to a style via relativeTo. On Android, specify text sizes only in sp, and in Jetpack Compose use the MaterialTheme type scale.

  • No fixed heights. Cards, buttons and list rows must grow with the text. A minimum height is fine; a maximum height is not.
  • Don't truncate content. The user must see the full product name, the error text and the primary action label. Truncation with an ellipsis is acceptable only for secondary data, and then there should be a way to see the full text.
  • Re-flow the layout. At large sizes, a horizontal "icon — text — value" row should become vertical. SwiftUI offers the dynamicTypeSize.isAccessibilitySize check and the ViewThatFits container for this.
  • Line height. Define line height relative to font size rather than as a fixed number, or lines will overlap at large sizes.
  • Scrolling. Every screen, even a short dialog, must be able to scroll. At maximum font size the "Confirm" button often ends up off-screen.

From our project experience: Ukrainian strings are usually 15–30% longer than English ones, so a layout drawn in English most often breaks during localisation. This is a studio estimate, not a formal norm, but it's always worth building in headroom.

Contrast is not just black and white

WCAG criterion 1.4.3 requires a contrast of at least 4.5:1 for normal text and 3:1 for large text. Criterion 1.4.11 extends the 3:1 requirement to icons, input field borders and visual component states. Here's how that plays out with typical colours.

Colour pairContrastVerdict
#767676 on white4.54:1the lightest grey that passes for normal text
#999999 on white2.85:1fails even for icons and borders
#BDBDBD on white (typical field border)1.88:1the field is nearly invisible in sunlight
#4CAF50 on white ("success" green)2.78:1unsuitable for text, needs a darker shade
#2E7D32 on white5.13:1passes for text
#D32F2F on white ("error" red)4.98:1passes for text
White on #12121218.73:1a solid base for dark theme

Check not only body text but also placeholders, helper text under fields, disabled states, badges, and text on images and banners. Disabled elements are formally exempt from contrast requirements, but if the user can't tell that a button is inactive and why, it's still a UX problem.

Colour must never be the only signal

Colour vision deficiency, mostly red-green, affects about 8% of men and 0.5% of women of Northern European descent. For them, a red and a green field border can look the same. So always duplicate status through another channel: text, an icon, shape or position. A simple test is to switch the phone to greyscale and walk through a key scenario. If the meaning survives, you're on the right track. We described how these principles fit into a broader review in our article on mobile app accessibility.

Step-by-step screen check

  1. Set the maximum system font: AX5 in iOS accessibility settings, the largest font scale on Android. For automation on Android you can use adb shell settings put system font_scale 2.0.
  2. Walk through key scenarios: sign-up, search, checkout, settings. Log truncated text, overlaps and buttons pushed off-screen.
  3. Switch to the longest supported language and repeat.
  4. Turn on Bold Text and Increase Contrast on iOS, and "High contrast text" on Android.
  5. Check the contrast of new colours with a tool: Accessibility Inspector, Accessibility Scanner or a Figma plugin.
  6. Switch on greyscale and make sure statuses are distinguishable without colour.
  7. Check focus, announcements and touch targets: at large font sizes elements shift, and touch areas can overlap.
  8. Add screenshot tests at maximum font size for key components so regressions are caught automatically.

Typical mistakes

  • Mock-ups are checked only at the designer's font size and in one language.
  • A developer "locks" the text size so a card won't break, disabling Dynamic Type for everyone.
  • A light-grey palette for an "airy" look that fails 4.5:1.
  • Input field borders below 3:1: you can't see the field until you tap it.
  • Text over a photo without a scrim: readable on some images, not on others.
  • Unlabelled icons in the bottom navigation that stay tiny at large font sizes because they're set in dp and never scale.

Design system checklist

  1. The type scale is tied to iOS system styles and to sp on Android.
  2. Every text and background colour pair is documented with its contrast ratio.
  3. Every component has a defined behaviour for accessibility font sizes.
  4. Statuses have a text or icon counterpart, not just colour.
  5. Screenshot tests cover default and maximum font sizes.
  6. The Definition of Done includes a check at maximum font size and in the longest language.

Accessible typography rarely requires complex solutions. Most often it needs component-system discipline and a willingness not to sacrifice content for the decorative precision of a mock-up.

Sources: Android Developers: What a great user experience looks like; Android 14: Non-linear font scaling to 200%; Apple Human Interface Guidelines: Typography; W3C: Understanding SC 1.4.3 Contrast (Minimum); W3C: Understanding SC 1.4.11 Non-text Contrast.

Journal

Ideas and products