Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions docs/API_REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,22 @@ Whether text can be selected.
| --------- | ------------- | -------- |
| `boolean` | `true` | Both |

### `selectionColor`

Color of the text selection highlight. On iOS, this also affects the caret and selection handle colors (they share a single tint). On macOS, only the selection background is affected. On Android, use `selectionHandleColor` to override the handle color independently.

| Type | Default Value | Platform |
| ------------ | ------------- | ------------------ |
| `ColorValue` | - | Both, macOS, Web |

### `selectionHandleColor`

Color of the selection handles (drag anchors). No-op on Android API levels below 29.

| Type | Default Value | Platform |
| ------------ | ------------- | -------- |
| `ColorValue` | - | Android |

### `md4cFlags`

Configuration for md4c parser extension flags.
Expand Down
1 change: 1 addition & 0 deletions docs/MACOS.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ These will be addressed in upcoming releases:
- **Tail fade-in animation** falls back to instant reveal (no `CADisplayLink` on macOS)
- **VoiceOver** accessibility is stubbed (pending `NSAccessibility` implementation)
- **Font scale observation** does not respond to system font size changes
- **`selectionColor`** affects only the selection background. The iOS-style caret + handle tinting isn't available on macOS, since AppKit's `NSTextView` doesn't expose them via `tintColor`.

## Example app

Expand Down
3 changes: 2 additions & 1 deletion docs/WEB.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ All core `EnrichedMarkdownText` features are supported on web, including:
- Full GFM: tables (with horizontal scroll), task lists (with checkbox interaction), strikethrough, links, images (block and inline), code blocks, LaTeX math (block and inline)
- All `markdownStyle` customisation options
- `onLinkPress`, `onLinkLongPress` (mapped to `contextmenu` event), `onTaskListItemPress` callbacks
- `allowTrailingMargin`, `containerStyle`, `selectable`, `md4cFlags` (`underline`, `latexMath`)
- `allowTrailingMargin`, `containerStyle`, `selectable`, `selectionColor`, `md4cFlags` (`underline`, `latexMath`)
- RTL support via the `dir` prop (CSS logical properties automatically flip blockquote borders, list indentation, etc.)

### Accessibility
Expand Down Expand Up @@ -39,6 +39,7 @@ The web implementation also exports `WebMarkdownTextProps` which extends `Enrich
| `allowFontScaling` / `maxFontSizeMultiplier` | React Native text scaling props. Browsers handle font scaling natively via OS accessibility settings. |
| `streamingAnimation` | Native-only tail fade-in animation. Not yet implemented on web. |
| `contextMenuItems` | Not supported — browsers don't allow extending the native context menu. |
| `selectionHandleColor` | Android-only — desktop browsers don't render selection handles. |

## Not supported on web

Expand Down
Loading