Skip to content

Commit daaad83

Browse files
committed
Update markdown.mdx based on issue #242
1 parent 093548f commit daaad83

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Images
2+
3+
In Fern documentation, you can add images using standard Markdown syntax or HTML image tags. Images provide visual aids to help users better understand concepts, follow tutorials, or see examples of the interface.
4+
5+
## Basic Image Syntax
6+
7+
### Markdown
8+
```md
9+
![Alt text](./path/to/image.png)
10+
```
11+
12+
### HTML
13+
```html
14+
<img src="./path/to/image.png" alt="Alt text" />
15+
```
16+
17+
## Image Options
18+
19+
### Disable Zoom
20+
To prevent an image from being zoomable when clicked, add the `noZoom` attribute:
21+
22+
```html
23+
<img src="./path/to/image.png" alt="Alt text" noZoom />
24+
```
25+
26+
### Dark Mode Support
27+
For images that need different versions in light and dark modes:
28+
29+
```html
30+
<img src="./light-image.png" alt="Light mode image" className="dark:hidden" />
31+
<img src="./dark-image.png" alt="Dark mode image" className="hidden dark:block" />
32+
```
33+
34+
## Best Practices
35+
36+
- Use descriptive alt text for accessibility
37+
- Keep image file sizes optimized
38+
- Provide appropriate context around images
39+
- Use consistent image dimensions within a document
40+
- Consider dark mode compatibility when relevant

0 commit comments

Comments
 (0)