NativeShareSheet
ShareSheet — sharing one published page (a form, a course, a worksheet) from the phone: its link with Copy and the system share sheet, and a QR code to show someone across the desk. The twin of genesis-ui's `ShareDialog`: the host passes the link and how to draw a QR code (`renderQr`, the same approach as the web; Genesis bundles no QR library), so nothing native is added. Copy goes through `onCopy` (pass expo-clipboard's `setStringAsync`); without it, Copy opens the system share sheet, which has Copy.
packages/ui-native/src/components/share-sheet.tsx
Import
Subpath export:
@marktiderman/genesis-ui-nativeimport { NativeShareSheet } from "@marktiderman/genesis-ui-native";Components
Auto-generated from TypeScript source via
react-docgen-typescript.NativeShareSheet
| Prop | Type | Default | Description |
|---|---|---|---|
| onOpenChange* | (open: boolean) => void | — | |
| open* | boolean | — | |
| url* | string | null | — | The public link; null while it is still loading. |
| description | ReactNode | Anyone with the link can open it. | Default "Anyone with the link can open it." |
| name | string | — | Its name, sent with the link to the system share sheet. |
| noun | string | page | What it is, in the default title and buttons: "page" (default), "form", "course". |
| onCopy | ((text: string) => void | Promise<void>) | — | Copies text (expo-clipboard's `setStringAsync`). Default: the system share sheet. |
| renderQr | ((url: string) => ReactNode) | — | Draws a QR code for a link. None hides the QR code. |
| testID | string | native-share-sheet | |
| title | string | `Share your ${noun}` | Default "Share your {noun}". |