Index of every page on this site: llms.txt
All skills
neha avatar

/theming

@eb9f097
Run it yourself

Apply colour scheme, dark mode, and theme tokens in React Native. Use when adding a theme, supporting dark mode, or replacing hardcoded colours.

Use this Skill: https://skilld.dev/gh/neha/rn-developer-skills/theming

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈38 tokens for metadata: the name and description. ≈553 when used: this file.

Description uses 1.9% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈154 characters, or 1.9%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Theming Skill

Applicability

  • Platforms: iOS and Android
  • React Native: 0.76+ (New Architecture interop assumed unless a checklist item says otherwise)

When to Use

  • Adding light and dark appearance, or an in-app theme choice
  • Replacing hardcoded colours in a screen or component
  • Checking contrast, status bar, and images against the active scheme

Contrast and dynamic type also belong to accessibility. User-facing theme names belong to i18n-and-localization.

Severity

Findings from this skill are should-fix.

Guidance

Tokens

  • Components take colours from theme tokens, not from hex values in the component file
  • The same token names exist for every supported scheme
  • An in-app choice (system, light, dark) is persisted and applied on the next cold start

Incorrect:

<Text style={{ color: '#111' }}>Total</Text>

Correct:

const colors = useThemeColors();
<Text style={{ color: colors.textPrimary }}>Total</Text>

System appearance

  • When the user has not chosen a scheme, the app follows the system colour scheme and updates if the system changes while the app is open
  • The status bar and navigation chrome stay readable on both schemes
  • Images and icons that assume a light background have a dark-scheme variant, or are simple enough to sit on either

Contrast

Safe-area insets are owned by architecture. Colour-only state is owned by accessibility.

  • Text and icons on the themed background stay readable in both schemes (see accessibility)

Anti-Patterns

Anti-Pattern Risk Fix
Reading the colour scheme once at launch The UI stays light after the user switches the system to dark Subscribe to scheme changes
A second palette inside one feature Dark mode fixes miss that feature Use the shared tokens

Pitfalls

  • A snapshot test locked to one scheme will not catch a dark-mode contrast failure.
  • Native screens and webviews do not inherit JS theme tokens unless they are given the same colours.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts9d3 checks · Risk SAFE
  • Gen Agent Trust Hub9d

    The skill provides guidelines and best practices for implementing theming and dark mode in React Native applications. No security issues were detected.

  • Socket9d

    No alerts

  • Snyk9d

    Risk: LOW · No issues

Signed by skilld at eb9f097. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub last month.

Steadyupdated 2 months ago
version
1.1.0
platforms
[
  "ios",
  "android"
]
react-native-version
0.76+
Other metadata
tags
[
  "react-native",
  "theming",
  "dark-mode"
]

README badge

README badge for neha/rn-developer-skills/theming