@techskillplanet/planet-components-react-native
v0.1.1
Published
TechSkillPlanet themed React Native basic controls library.
Readme
Basic Controls React Native
React Native implementation for the Star Planet basic controls library.
Library
src/starPlanet/index.jssrc/starPlanet/theme.jssrc/starPlanet/components/*.jssrc/starPlanet/utils/shared.js
Package name: @techskillplanet/planet-components-react-native.
Theme API (aligned with Android style_token.json / color_token.json):
starPlanetThemes: color presets (sky,night,mint)starPlanetStyleProfiles: style presets (island_raised,island_flat)builtInThemePresets: 6 sample presetsresolveTheme(colorKey, styleProfile): merged runtime theme object
Component File Rule
React Native follows the same structure rule as the other platforms:
- one component = one JavaScript file under
src/starPlanet/components/ index.jsonly exports public APIs- shared helpers and styles live under
utils/ - no component implementation should be added directly to
index.js
Sample
../samples/App.js../samples/src/navigation/AppRouter.js../samples/src/pages/HomePage.js../samples/src/pages/ComponentDetailPage.js../samples/src/pages/SettingsPage.js../samples/src/data/componentDocs.js
The sample is a runnable Expo React Native project. It depends on the local library exports and follows the same structure as Web, Android, iOS and Kuikly:
- Learning tab: grouped component list.
- One list item per component.
- One visual-only detail page per component.
- Settings tab: theme and language switching.
- Route state is centralized in
../samples/src/navigation/AppRouter.js.
Run it from the sample directory:
cd ../samples
npm install
npm run start