Compare commits
No commits in common. 'master' and 'v0.3.2' have entirely different histories.
24 changed files with 3545 additions and 25848 deletions
@ -1,66 +1,2 @@ |
|||||||
# ation |
# ation |
||||||
– a simple keynote software for markdown files – written using `electron` |
– a simple keynote software for Markdown files – written in `electron` |
||||||
|
|
||||||
 |
|
||||||
|
|
||||||
## Usage |
|
||||||
After opening any markdown file you can press <kbd>Tab</kbd> to show all |
|
||||||
available keybindings. The keybindings are chosen, so they work with commont |
|
||||||
presenters like the *"Logitech R400"*. |
|
||||||
|
|
||||||
### Markdown |
|
||||||
`ation` tries to make a presentation out of any ordinary markdown file. It |
|
||||||
considers `H1` titles to be a standalone slide and `H2` titles to start a new |
|
||||||
slide. There also is a special template for a "cover slide", which is |
|
||||||
provisioned by meta data at the top of your markdown file. |
|
||||||
|
|
||||||
### Meta data |
|
||||||
To keep compatibility with other markdown parsers, `ation` does not implement a |
|
||||||
`YAML` front matter or similar, but tries to parse the first `HTML` comment in |
|
||||||
your markdown file as meta data. The meta data is specified as simple key-value |
|
||||||
pairs, one pair per line, a color (`:`) seperating the key from the value. |
|
||||||
|
|
||||||
**Possible values** |
|
||||||
|
|
||||||
| Key | Type | Example Value | |
|
||||||
| ---------------- | ------------------- | ---------------------------- | |
|
||||||
| title | string | My Keynote | |
|
||||||
| subtitle | string | an introduction into `ation` | |
|
||||||
| author | string | MikO, Massive Dynamic | |
|
||||||
| email | email address | miko@mail.tld | |
|
||||||
| icon | path *(relative)* | ./my_logo.svg | |
|
||||||
| color_highlight | CSS color value | #4994DA | |
|
||||||
| color_background | CSS color value | #1A1A1A | |
|
||||||
| color_text | CSS color value | #DDDDDD | |
|
||||||
| font | CSS font identifier | Iosevka | |
|
||||||
|
|
||||||
**Example** |
|
||||||
```html |
|
||||||
<!-- |
|
||||||
title : My Keynote |
|
||||||
subtitle : an introduction into `ation` |
|
||||||
author : MikO, Massive Dynamic |
|
||||||
email : miko@mail.tld |
|
||||||
icon : ./my_logo.svg |
|
||||||
color_highlight : #4994DA |
|
||||||
color_background : #1A1A1A |
|
||||||
color_text : #DDDDDD |
|
||||||
font : Iosevka |
|
||||||
--> |
|
||||||
``` |
|
||||||
|
|
||||||
The color values override the ones that have been set in `ation`'s settings on a |
|
||||||
per slideshow basis. |
|
||||||
|
|
||||||
## Installation |
|
||||||
Either choose a pre-built release from the [releases page][release] or build |
|
||||||
`ation` yourself running |
|
||||||
|
|
||||||
```bash |
|
||||||
npm i |
|
||||||
npm run dist |
|
||||||
``` |
|
||||||
|
|
||||||
Releases are currently only available for `macOS` and `Windows`. |
|
||||||
|
|
||||||
[release]: releases |
|
||||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,36 +0,0 @@ |
|||||||
import React from "react"; |
|
||||||
import Monaco from "@monaco-editor/react"; |
|
||||||
|
|
||||||
const Editor = ({show, source}) => { |
|
||||||
|
|
||||||
const editorMount = (instance, monaco) => { |
|
||||||
// NOTE: I have no idea, why we have to re-add these ourselves, but this
|
|
||||||
// code works, so be it. --MikO
|
|
||||||
instance.addCommand(monaco.KeyMod.CtrlCmd | monaco.KeyCode.KeyC, () => instance.trigger("source","editor.action.clipboardCopyAction")); |
|
||||||
instance.addCommand(monaco.KeyMod.CtrlCmd | monaco.KeyCode.KeyV, () => instance.trigger("source","editor.action.clipboardPasteAction")); |
|
||||||
instance.addCommand(monaco.KeyMod.CtrlCmd | monaco.KeyCode.KeyX, () => instance.trigger("source","editor.action.clipboardCutAction")); |
|
||||||
instance.addCommand(monaco.KeyMod.CtrlCmd | monaco.KeyCode.KeyS, () => window.api.saveFile(instance.getValue())); |
|
||||||
} |
|
||||||
|
|
||||||
if (!show) |
|
||||||
return <></>; |
|
||||||
|
|
||||||
return ( |
|
||||||
<> |
|
||||||
<Monaco
|
|
||||||
defaultLanguage="markdown" |
|
||||||
height="100%" |
|
||||||
options={{ |
|
||||||
minimap : { |
|
||||||
enabled : false |
|
||||||
} |
|
||||||
}} |
|
||||||
onMount={editorMount} |
|
||||||
keepCurrentModel={true} |
|
||||||
defaultValue={source} |
|
||||||
theme="vs-dark" /> |
|
||||||
</> |
|
||||||
); |
|
||||||
}; |
|
||||||
|
|
||||||
export default Editor; |
|
@ -1,8 +1,7 @@ |
|||||||
const Mode = Object.freeze({ |
const Mode = Object.freeze({ |
||||||
NORMAL : 1, |
NORMAL : 1, |
||||||
PRESENT : 2, |
PRESENT : 2, |
||||||
BLACKOUT : 3, |
BLACKOUT : 3 |
||||||
EDIT : 4 |
|
||||||
}); |
}); |
||||||
|
|
||||||
export default Mode; |
export default Mode; |
Loading…
Reference in new issue