ldls-native
Skill627 starsChanged 8 days agoMITView on GitHub
Lumen UI React Native design system rules (`@ledgerhq/lumen-ui-rnative`) and how a native implementation maps a universal contract onto Lumen. Use when writing or reviewing native UI, in `*.native.tsx` files or under `apps/ledger-live-mobile/**`.
In this repository70 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
- analyticsSkill
- batch-feature-devSkill
- ci-runnersSkill
- ci-workflow-refsSkill
- cleanupSkill
- client-idsSkill
- cloud-sync-moduleSkill
- codeownershipSkill
- coin-families-contractSkill
- coin-modulesSkill
- commentsSkill
- configurationSkill
- console-logSkill
- create-changesetSkill
- create-prSkill
- data-layer-advancedSkill
- debug-rn-native-crashSkill
- dependency-patchesSkill
- detect-data-leaksSkill
- device-intent-executorSkill
- devtools-import-boundarySkill
- dialogs-sliceSkill
- docs-migrateSkill
- docs-update-or-createSkill
- domain-dataSkill
- e2e-desktop-add-or-updateSkill
- e2e-desktop-onboardSkill
- e2e-earnSkill
- e2e-mobile-add-or-updateSkill
- e2e-mobile-onboardSkill
- e2e-swapSkill
- errorsSkill
- feature-devSkill
- fix-ciSkill
- flow-packageSkill
- get-pr-commentsSkill
- git-conventionsSkill
- i18n-keysSkill
- impacting-prsSkill
- knip-migrationSkill
- ldls-webSkill
- ledger-wallet-cliSkill
- legacy-migrationSkill
- mvvm-architectureSkill
- new-packageSkill
- package-public-apiSkill
- pnpm-resolutionSkill
- prefer-set-hasSkill
- pre-reviewSkill
- react-generalSkill
- rebuild-to-fix-lib-import-errorsSkill
- remove-feature-flagSkill
- run-buildsSkill
- run-e2e-ciSkill
- runner-imagesSkill
- run-testsSkill
- slack-pr-messageSkill
- The first 60 shown.
The file
Files
Lumen UI React Native
Read the Lumen rules first
Lumen ships its own rules for components, the lx style system and tokens. Read them before writing UI:
apps/ledger-live-mobile/node_modules/@ledgerhq/lumen-ui-rnative/ai-rules/RULES.md.
The file exists once pnpm i has run. pnpm links @ledgerhq/lumen-ui-rnative under the packages that
depend on it, not at the repo root. If the path is missing, open ai-rules/RULES.md in the installed
@ledgerhq/lumen-ui-rnative package of any native consumer.
Map the contract onto Lumen
The rules both platforms follow are in
universal-components. On native,
X.native.tsx maps:
Contract (X.types.ts) | Native implementation (X.native.tsx) |
Intent callback, onOpenContacts() | onPress={onOpenContacts} |
Value callback, onSearchQueryChange | onChangeText={onSearchQueryChange} |
testID | testID={testID} |
// ContactsButton.native.tsx
import {
Card,
CardContent,
CardContentTitle,
CardHeader,
CardLeading,
} from "@ledgerhq/lumen-ui-rnative";
import type { ContactsButtonProps } from "./ContactsButton.types";
export function ContactsButton({ title, onOpenContacts, testID }: ContactsButtonProps) {
return (
<Card type="interactive" onPress={onOpenContacts} testID={testID}>
<CardHeader>
<CardLeading>
<CardContent>
<CardContentTitle>{title}</CardContentTitle>
</CardContent>
</CardLeading>
</CardHeader>
</Card>
);
}What stays in the native file
These never appear in the contract. The native file owns them:
- Lumen imports and Lumen props types (
@ledgerhq/lumen-ui-rnative), and anyreact-native*import. - Gesture and input props:
onPress,onLongPress,onChangeText,onSubmitEditing,onFocus,onBlur. - Event objects:
GestureResponderEvent,NativeSyntheticEvent. lx,style,StyleProp<ViewStyle>.- Refs to native views.
- Values the native file can read itself, such as the safe area under a sheet (
useBottomSheetBottomInset()), instead of abottomInsetprop.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

