useThemeColors
Returns the installed theme's semantic colors for the current light/dark scheme, and the installed style's tokens and helpers. Used by every component.
Installation
npx nativra-cli add use-theme-colorsWrites use-theme-colors.ts to hooks, rewrites imports to your aliases and records hashes in nativra.lock.json, along with 2 registry dependencies. Existing files are never overwritten without asking.
Want to try it first? Open it in the playground: a real React Native project in your browser, with this item installed by the CLI.
Source
Exactly what the CLI writes, before your import aliases are applied.
Dependencies
Registry items
Used by
- AccordionComponentAn interactive collapsible accordion component supporting single and multiple open items.
- Account Settings FlowTemplateEnterprise SaaS account, organization seats, security sessions, and billing management flow.
- Action TileComponentQuick-action icon button tile for mobile dashboards, wallets, and launcher grids.
- Activity TimelineBlockVertical audit log and activity timeline item with status node, connector line, and timestamp metadata.
- AlertComponentDisplays a callout banner for user attention with icons and status variants.
- Analytics DashboardTemplateExecutive SaaS mobile dashboard template with KPI metrics, time-range filter pills, channel breakdown bars, and recent audit activity feed.
- App HeaderBlockVersatile enterprise application navigation header with branding, back navigation, search, action buttons, notifications badge, and user avatar.
- App SidebarBlockEnterprise collapsible application navigation sidebar with grouped navigation items, active route indicators, user profile card, and footer actions.
- Auth FlowTemplateA complete mobile authentication template with Sign In, Sign Up, Forgot Password, and OTP verification steps.
- AvatarComponentAvatar component displaying profile image with automatic text initials fallback.
- BadgeComponentA small status indicator label for React Native.
- Booking FlowTemplateAppointment booking in three steps: date and free time slots, contact details with phone, a summary to confirm, then a success screen.
- Bottom SheetComponentAn interactive modal bottom drawer with drag handle and backdrop dismiss.
- Bottom Tab BarComponentNative-feeling bottom tab navigation bar with active indicator pill and notification badge counts.
- ButtonComponentA pressable button with variant and size presets for React Native.
- CardComponentA surface container for grouped content.
- Chat & Messaging FlowTemplateIn-app support and customer messaging template with conversation threads, speech bubbles, and keyboard-avoiding input bar.
- Chat BubbleBlockA chat message with sender grouping, delivery ticks, a failed state with retry, and an avatar for other people.
- CheckboxComponentAccessible checkbox component with check indicator and label support.
- ChipComponentInteractive filter, selection, and removable tag chip with selected state and close action.
- CodeScannerComponentQR and barcode scanner on expo-camera with a framing guide, torch toggle, duplicate filtering and permission states.
- ColorSwatchComponentA row of selectable color choices (product variants, label colors) that screen readers treat as a radio group.
- CountryPickerComponentA country field that opens a searchable list with flags and dial codes. Ships the country data PhoneInput uses.
- CreditCardInputComponentCard number, expiry and CVC fields with formatting, brand detection, Luhn validation and auto-advance.
- Data TableComponentMobile-optimized horizontally scrollable data grid with columns, sorting indicators, and striped rows.
- Date PickerComponentNative-feeling calendar date and quick-preset selector input for mobile forms and scheduling.
- DialogComponentAn accessible modal dialog with backdrop, title, description, and action buttons.
- eCommerce FlowTemplateProduction mobile retail and eCommerce storefront template with product catalog, search filters, detail sheet, cart, and order summary.
- Empty StateBlockClean empty state illustration card with title, description, and call to action.
- Error BoundaryComponentMobile crash recovery error boundary card with diagnostic summary and retry action.
- Filter SheetBlockEnterprise slide-up filter sheet with multi-select category chips, price range slider, status toggles, and CTA controls.
- Fintech WalletTemplateHigh-impact mobile finance and crypto wallet screen with total balance card, quick action pills, asset allocation list, and recent transactions.
- Floating Action ButtonComponentAn elevated circular action button anchored above screen content.
- FormFieldComponentLabel, description, any control and its error message as one accessible unit.
- Header BarComponentMobile screen navigation bar with back action, title, subtitle, and right action button.
- Icon ButtonComponentAn accessible, compact icon-only button with 44x44pt minimum touch target.
- ImageWithFallbackComponentAn image with a skeleton while it loads and a themed fallback when it fails or has no source.
- InputComponentA text input with label, helper and error state.
- KPI Comparison CardBlockEnterprise dual-metric comparison card featuring current vs target performance, progress indicators, and trend badges.
- LabelComponentAccessible form label component with required asterisk and disabled state.
- ListItemComponentA list row with leading icon, title, subtitle, trailing element, chevron and divider.
- Metric CardBlockReady-to-use mobile analytics KPI stat card with positive/negative trend badges.
- Mini Sparkline CardBlockExecutive KPI metric card with integrated zero-dependency trend sparkline curve.
- Notification ItemBlockInteractive mobile notification card with user avatar, timestamp, unread indicator dot, and action buttons.
- Onboarding FlowTemplateA multi-step walkthrough walkthrough template with slides, pagination indicators, next/skip controls, and completion actions.
- Order SummaryBlockComplete mobile e-commerce checkout invoice summary with line items, voucher discount, and checkout button.
- OTP InputComponentA discrete multi-cell numeric pin input for one-time passwords and verification codes.
- Pagination DotsComponentStep and carousel pagination dot indicator with active pill expansion and interactive dot press.
- Payment Method CardBlockVisual credit card and digital payment method card with card brand logo, masked PAN, and default selector.
- PhoneInputComponentA phone number field with a searchable country-code picker; autofilled international numbers pick their country.
- Pricing CardBlockReady-to-use mobile subscription tier card with features list and checkout CTA.
- Product CardBlockProduct tile with image, badge, wishlist heart, name, rating, price with compare-at price, and add-to-cart.
- Profile FlowTemplateProfile screen with avatar, bio, stats and grouped settings, plus an edit mode with validation, photo change and async save.
- ProgressComponentDisplays an indicator showing the completion progress of a task.
- Radio GroupComponentAn accessible group of radio buttons with keyboard and screen reader support.
- Rating StarsComponentAccessible tap-to-rate star component supporting custom sizes, ratings, and read-only display.
- Register FormBlockSign-up form with name, email, password and confirm, inline validation, terms consent and autofill hints.
- Safe AreaComponentCross-platform viewport safe area container respecting notch and navigation bar insets.
- Search Results RowBlockA search hit with the query highlighted in its title and subtitle, leading media, trailing meta and a fill-in arrow.
- SearchBarComponentA search field with icon, clear button, loading state and an optional Cancel action.
- SectionListComponentReact Native's SectionList with themed sticky headers, section footers and an inset-grouped (settings) variant.
- Segmented ControlComponentiOS and Material style sliding segmented pill switcher with animated selection indicator.
- SelectComponentA native mobile dropdown/modal picker component with search and selection state.
- SeparatorComponentA horizontal or vertical divider line.
- Settings FlowTemplateA comprehensive mobile settings screen template with account profile header, preference toggles, security options, and logout dialog.
- Settings ListBlockReady-to-use mobile settings group with switches, badges, and navigation rows.
- SkeletonComponentLoading placeholder skeleton with a subtle pulse that holds still when Reduce Motion is on.
- SliderComponentA touch-friendly continuous input control for selecting a value within a range.
- Social FeedTemplateInfinite-scroll feed with post cards, optimistic likes, comments and native share, pull to refresh, and error and end states.
- SpinnerComponentAccessible activity indicator spinner with size and semantic color presets.
- Stat Progress CardBlockMobile goal KPI card with target value, percent indicator, and embedded progress bar with milestone indicators.
- Stat TileComponentCompact KPI metric tile with tabular value, trend delta badge, and caption.
- SwipeableRowComponentA row that swipes to reveal actions (Delete, Archive), with screen-reader actions and no extra dependencies.
- SwitchComponentAccessible toggle switch with themed active/inactive colors.
- TabsComponentSegmented mobile navigation tabs for switching between views.
- Team Member RowBlockEnterprise team member row with avatar, identity details, role selector pill, and action menu.
- TextComponentTypography component with semantic heading, body, and muted variants.
- TextareaComponentA multiline text input with character counting and error state.
- TimePickerComponentAn inline hour and minute picker with snap-scrolling columns, 12/24-hour cycles and minute steps.
- ToastComponentA floating toast notification with success, error, and info variants.
- Transaction HistoryBlockTransactions grouped by day with daily net totals, an optional running balance, and locale-aware money and dates.
- Transaction RowBlockHigh-density enterprise financial ledger item with counterparty icon, status badge, and monetary values.
- User ProfileBlockReady-to-use mobile profile card with avatar, verified badge, stats, and actions.