Focus Ring
Give Flutter product composites a keyboard-only Tinyrack focus indicator.
Give a product-specific composite the same keyboard-only focus indicator as Tinyrack controls.
Contract
| Axis | Contract |
|---|---|
| Input modality | Pass raw focus through focused. The ring appears for keyboard navigation and stays hidden for pointer focus. |
| Layout | The ring paints inside the child bounds without changing its size or position. |
Install
Add the package, then import its public library.
flutter pub add tinyrack_uiimport 'package:tinyrack_ui/tinyrack_ui.dart';Playground
Usage
import 'package:material_ui/material_ui.dart';
import 'package:tinyrack_ui/tinyrack_ui.dart';
TRFocusRing(
focused: focusNode.hasFocus,
child: const CompositeControl(),
)API
TRFocusRing properties
| Prop | Type / default | Purpose |
|---|---|---|
focused | bool · required | Reports whether the composite currently owns focus. |
child | Widget · required | Supplies the composite whose bounds receive the ring. |