Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Skip to main content

Overview

@amazon-devices/kepler-a11y-settings-interface-turbo provides accessibility settings APIs and UI scaling hooks for Kepler applications.

Getting Started

Installation

In the package.json file, add the @amazon-devices/kepler-a11y-settings-interface-turbo package as a dependency: From the command line, run the following:
Or, you can manually edit the package.json file as shown:
Then run npm install.

Usage

Settings Getters, Setters, and Listeners

Reading Settings

Use the KeplerA11ySettingsInterface to query current accessibility settings. All getter methods return Promises.

Listening for Changes

Add listeners to respond to accessibility setting changes. Listener registration and removal methods are asynchronous and return Promises:

Writing Settings (System Apps Only)

Setter methods require the com.amazon.devconf.privilege.accessibility.write permission, which is reserved for system applications. Third-party apps are not eligible to declare this permission.

UI Scale Setting Hooks

React Hooks for Dynamic Scaling

Use the provided hooks to create responsive UI that automatically adapts to scale setting changes. These hooks are necessary where UI sizes are defined, in the case that the associated UI element should scale. If you are using UI elements that have already wrapped underlying predefined sizes with these hooks, you simply need to wrap your App definition in the UiScaleSettingContextProvider. Application developers are responsible for ensuring that their app gracefully handles changes in size to the onboarded UI elements. For example, an application developer may need to ensure that a container is scrollable, or text component has overflow behavior defined, even if these properties were unnecessary at the default scale.

Scaling Types

The library supports different scaling behaviors for various UI elements:
  • 'low_upscale' - Large items that scale minimally (e.g., cards)
  • 'medium_upscale' - Standard UI elements with moderate scaling
  • 'large_upscale' - Small elements that need significant scaling (e.g., buttons)
  • 'low_downscale' - Whitespace that reduces at higher scales
  • 'large_downscale' - Large padding that reduces dramatically
  • 'text' - Text elements with corresponding line height scaling
  • 'image' - Images and visual assets

Advanced Scaling Options

Control scaling limits with optional parameters:

Density Independent Pixels (DIP)

The scaling APIs (useScaledSize, useScalingMultiplier, getScaledSize, getScalingMultiplier) support both Density Independent Pixel (DIP) and physical pixel inputs, depending on whether the consuming application has enabled the PLATFORM_DENSITY_INDEPENDENT_PIXEL runtime feature flag in its react-native.config.js.
  • DIP enabled (PLATFORM_DENSITY_INDEPENDENT_PIXEL: true): Size values passed to the scaling APIs are expected to be in density-independent pixels.
  • DIP not enabled: Size values are expected to be in physical pixels.

API Reference

Classes

Interfaces

Type Aliases

Functions

Variables


Last modified on July 22, 2026