Skip to content

feat(react-native): @hopline/ux4g-react-native — all 41 UX4G components - #11

Merged
2002Bishwajeet merged 3 commits into
mainfrom
worktree-react-native-mvp
Jun 14, 2026
Merged

2002Bishwajeet merged 3 commits into
mainfrom
worktree-react-native-mvp

Conversation

@2002Bishwajeet

Copy link
Copy Markdown
Contributor

What

Adds @hopline/ux4g-react-native (v0.1.0) — a full React Native port of the UX4G design system, sibling to the web @hopline/ux4g-react package in the same pnpm monorepo. All 41 components are reimplemented against the shared design tokens, using RN primitives (View/Text/Pressable/TextInput/Modal/ScrollView) + react-native-svg (icons, Chart, IndiaMap). Theming flows through a ThemeProvider/useUX4GTheme context with an optional theme/primary/secondary override.

Components: actions (Button, IconButton), forms (Input, Textarea, Select, Checkbox, Radio, Switch, Search, DatePicker, RangeSlider, ColorPicker, FileUpload), display (Card, Badge, Chip, Avatar, Comment), feedback (Alert, Progress, Spinner, EmptyState, FeedbackWidget), overlay (Modal, Tooltip, Menu, Toast, Popover), data (Table, Accordion, Pagination, List, Chart, IndiaMap), navigation (Tabs, Breadcrumb, Stepper, Navbar, Footer), media (Carousel), accessibility (AccessibilityWidget).

How it's built

  • Genuinely native RN — no DOM, no react-native-web, no WebView; not a wrapper around the web package. The library tsconfig uses lib: ["ES2020"] (no DOM lib).
  • tsup build → ESM + CJS + .d.ts, with react / react-native / react-native-svg externalized (peer deps).
  • Expo SDK 56 gallery under examples/rn-playground exercising all 41 components, each isolated in its own ErrorBoundary cell.

Verification

  • Strict TypeScript, no any/unknown across library and example; the 41-component gallery type-checks against the published .d.ts (a type-level integration test of every public API).
  • 494 tests / 43 suites green (@testing-library/react-native mounts every component) + a public-API integration suite.
  • expo export bundle gate passed for both iOS and Android (Hermes .hbc for each target).
  • Android device QA (Pixel 9): uiautomator confirms 41/41 component cells render with 0 ErrorBoundary trips across the full scroll; screenshots of every section incl. the SVG Chart and IndiaMap choropleth.
  • iOS (iPhone 17 simulator): bundle gate + live render confirmed; full scrolled per-component screenshots were limited only by Expo Go's onboarding modal + the lack of iOS touch-injection tooling in the QA environment (same JS bundle, identical first-screen render to Android).

Notes

  • Button fix: a fixed height combined with vertical padding + border was clipping label descenders; dropped the redundant paddingVertical. Covered by a new regression test.
  • dist/, node_modules/, and local tooling files are gitignored / excluded from this PR.

…onents

Port the full UX4G component set to React Native (RN primitives + react-native-svg) against the shared design tokens, with a ThemeProvider context and a tsup ESM+CJS+dts build.

- 41 components across actions/forms/display/feedback/overlay/data/navigation/media/accessibility
- Strict TypeScript, no any/unknown; 494 tests across 43 suites (RNTL mounts every component) + a public-API integration suite
- Expo SDK 56 gallery example (examples/rn-playground) device-QA'd: Android 41/41 render with 0 ErrorBoundary trips; iOS bundle gate + live render confirmed
- Button: fixed-height label no longer clips descenders (dropped redundant paddingVertical)
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jun 14, 2026 •

Copy link
Copy Markdown

Deploying ux4g with  Cloudflare Pages  Cloudflare Pages

Latest commit: ce8a1f7
Status: ✅  Deploy successful!
Preview URL: https://a3dcc77a.ux4g.pages.dev
Branch Preview URL: https://worktree-react-native-mvp.ux4g.pages.dev

View logs

…ease @hopline/ux4g-react-native 0.1.0

- Single source of truth for design tokens: tokens/ux4g.primitives.tokens.json (DTCG) -> scripts/gen-tokens.mjs -> src/tokens.generated.ts, consumed by theme.ts. A snapshot test guards exact token values (no behaviour change across all 41 components).
- Perf: Select now virtualizes its option list with FlatList (long lists mount only the visible window); items/selected memoised.
- Add package README (install, theming, 41-component list, token pipeline, performance + native-bridge notes).
- 496 tests / 44 suites green; tsc clean; no any/unknown; ESM+CJS+dts build.
@2002Bishwajeet
2002Bishwajeet merged commit 3abad17 into main Jun 14, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant