Skip to content

Commit

Permalink
README: add AnkiCanvasOptions
Browse files Browse the repository at this point in the history
  • Loading branch information
pigoz committed Dec 29, 2019
1 parent 589345a commit 80b8bf7
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,45 @@ Download the premade Anki deck from the [Releases page](https://github.com/pigoz
You can easily customize some variables picked up by AnkiCanvas. Open the card
layout and edit the `AnkiCanvasOptions` JavaScript object in the Front and
Back templates.


The current default options object is the following:

```html
<script>
window.AnkiCanvasOptions = {
frontCanvasSize: 300,
frontLineWidth: 7,
backCanvasSize: 150,
backLineWidth: 3.5,
// 'auto' is a special value that will automatically select either 'light' or
// 'dark' depending on Anki's "Night Mode" status. If you wish to force a
// colorScheme, you can pass it's name from the colorSchemes settings below.
colorScheme: 'auto',
// You can modify the default colorSchemes in the dictionary below, or even
// add your own colorSchemes beyond light and dark.
colorSchemes: {
light: {
brush: '#000',
grid: '#dcdcdc',
gridBg: '#fff',
buttonIcon: '#464646',
buttonBg: '#dcdcdc',
frontBrushColorizer: 'none', // none | spectrum | contrast
backBrushColorizer: 'spectrum',
},
dark: {
brush: '#fff',
grid: '#646464',
gridBg: '#000',
buttonIcon: '#000',
buttonBg: '#646464',
frontBrushColorizer: 'none',
backBrushColorizer: 'spectrum',
},
},
}
</script>
```

0 comments on commit 80b8bf7

Please # to comment.