Skip to content

Commit

Permalink
Merge pull request #148 from wilkyrlx/docs
Browse files Browse the repository at this point in the history
update FAQ docswith resize canvas
  • Loading branch information
amcdnl authored Dec 6, 2023
2 parents a7c500d + c78599d commit 0108eea
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions docs/FAQ.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,15 @@ import { Meta, Story } from '@storybook/blocks';

# FAQ

## Resizing the GraphCanvas
If you are having trouble resizing the canvas such that it does not take up the whole page, you can
use wrap the `<GraphCanvas/>` component with a fixed position div and adjust the size. For example:
```
<div style={{ position: "fixed", width: '75%', height: '75%'}}>
<GraphCanvas nodes={n} edges={e} />
</div>
```

## Font Support
By default, regraph uses `troika-three-text` which uses the Roboto font
loaded by Google Fonts CDN. You can override this by passing `labelFontUrl`.
Expand Down

0 comments on commit 0108eea

Please sign in to comment.