Commit Graph

45 Commits

Author SHA1 Message Date
Maas Lalani
99af53b01f remove redundent ruby tests 2021-10-21 20:41:02 -04:00
darmiel
5f76976a4a fix: remove chmod +x <file> 2021-10-20 20:53:15 -04:00
darmiel
518028e6d3 refactor: only use multi, removed single and base 2021-10-20 20:53:15 -04:00
darmiel
e7fa9dad68 fix: broke ruby, oops! 2021-10-20 20:53:15 -04:00
darmiel
a065914f73 feat: multiple code execute commands; rust code support (#104) 2021-10-20 20:53:15 -04:00
Maas Lalani
99c32cc8fc Clean up navigation 2021-10-10 17:36:33 -04:00
stoovon
d561ab99fc Incorporate code review comments
- Remove redundant comment.
- Streamline "G" case.
- Streamline "ClearVirtualText".
- Include NumSlides within State for improved separation.
2021-10-10 17:16:37 -04:00
stoovon
5adcb09a14 Move tests
This completes the refactoring.
2021-10-10 17:16:37 -04:00
stoovon
2dd286e93f Make Navigate a state function
This simplifies the contract for testing.
It's also more idiomatic functional programming.
Also rule of three (i.e. returning three arguments now, so better to return a type).

Moving tests in next commit. Again, demonstrating no gap in coverage.
2021-10-10 17:16:37 -04:00
stoovon
f31e238378 Refactor to extract navigation package
Introduce a clean separation of concerns between model and navigation.
Note that the tests are not moved in this commit, to prove no break in
functionality. They'll be moved in the next commit.
2021-10-10 17:16:37 -04:00
stoovon
b3dda422d0 Vim-like navigation
Supported sequence examples:

* G = go to last slide
* gg = go to first slide
* 4j = go forward 4 slides
* 13G = go to slide 13

Extracted navigateX methods to increase maintainability of
model.Update() given the additional functionality.

Closes https://github.com/maaslalani/slides/issues/96
2021-10-10 17:16:37 -04:00
Eduardo Cuducos
e4a3413409 Uses custom date format YYYY-MM-DD
Fix #106
2021-10-04 21:26:43 -04:00
Maas Lalani
4d826524e1 WithWordWrap 2021-09-18 21:18:10 -04:00
gsol10
dcf3c49fd6 Word wrap support 2021-09-18 21:18:10 -04:00
Maas Lalani
3bd39616b2 var rename 2021-09-10 16:38:45 -04:00
林玮 (Jade Lin)
644ff86a6b update unittest TestParse 2021-09-10 16:36:46 -04:00
林玮 (Jade Lin)
68adc0a622 be able to run multiple code blocks in a single slide 2021-09-10 16:36:46 -04:00
Maas Lalani
bf5f13f3b3 s/numbering/paging/g 2021-08-06 16:45:12 -04:00
Eduardo Cuducos
74d6d19a30 Adds customization to the bottom metadata
Fix #87
2021-08-06 16:45:12 -04:00
Eduardo Cuducos
45ea575822 Fixes metadata fallback strategy 2021-08-05 17:42:37 -04:00
Paul
caa98c45fd ignore shebang 2021-08-02 18:53:08 -04:00
Maas Lalani
03ed79bf57 fix: bug with preceeding --- and YAML comments as headers in markdown 2021-07-11 16:51:02 -04:00
Maas Lalani
095ea050e7 feat: Add lua language support for code blocks execution 2021-07-07 16:27:48 -04:00
Maas Lalani
a86cf85712 Ensure slides has at least some content to prevent crashing 2021-07-01 20:42:44 -04:00
Kjell Kvinge
7ac31fc040 add perl code execution 2021-06-30 17:29:42 -04:00
Mark Stenglein
de9baaf976 EXECUTE: TEST: Use more common sed instead of sd
This patch updates the `sd Find Replace` test case to make use of `sed`
instead of `sd`. This should help tests pass on a wider range of
systems without introducing a testing dependency.
2021-06-27 22:15:39 -04:00
Maas Lalani
742251d742 Ensure file is executable for preprocessing to work 2021-06-27 21:02:01 -04:00
Maas Lalani
e7274f993e Pre-process any commands 2021-06-27 21:02:01 -04:00
Maas Lalani
6d4f555579 Add node/js code execution 2021-06-27 10:20:45 -04:00
Maas Lalani
7b1b2cd894 Add pre-processing of slides 2021-06-25 22:28:48 -04:00
Maas Lalani
09f46bae4b Short tests don't rely on PATH 2021-06-25 22:09:17 -04:00
satoru
a158018e07 Do not render output of code blocks as Markdown 2021-06-25 11:03:52 -04:00
Maas Lalani
4e7df034f5 Remove ~~~ as a slide delimiter 2021-06-25 08:54:04 -04:00
Maas Lalani
53a81cdc9c Swap J and K controls 2021-06-23 10:39:08 -04:00
satoru
2bf2cd5506 Fix #39, allow code blocks without trailing new line to run 2021-06-23 09:48:29 -04:00
suzaku
8c1a1aee53 Add support for Elixir code block execution 2021-06-23 04:15:49 -04:00
Maas Lalani
f6fecdc435 code exec on ctrl+e 2021-06-21 16:52:43 -04:00
Maas Lalani
eae6b6ffcd feat: execute code on slides 2021-06-21 16:52:43 -04:00
Alexei Yuzhakov
9cf9e4f1fe Fix #18 Add live reload support 2021-06-19 15:17:51 -04:00
Maas Lalani
be0a54a1a6 Execute code block for supported languages (bash,go,ruby,python) 2021-06-13 11:13:09 -04:00
Maas Lalani
2a4ea2ed9d Add code package with Parse function (with tests) 2021-06-12 23:05:13 -04:00
Maas Lalani
cb2c4ba2aa fix: go fmt 2021-06-12 17:54:24 -04:00
Britton Hayes
e21cc0c0b3 Allow user customization for slide themes
Closes #1.

This change allows users to add a configuration section to their slides,
which allows them to specify a different theme if they would like to
change the styles of the default theme.

A user can add
```
---
theme: ascii
---
```

To use an ascii theme or use `theme: ./styles.json` to specify their own
custom JSON theme using glamour styles.

Co-authored-by: Britton Hayes <brittonhayes@users.noreply.github.com>
2021-06-12 16:59:00 -04:00
Maas Lalani
d9fef570d8 Don't word wrap 2021-06-12 16:17:46 -04:00
Maas Lalani
93ccd2525f Internal API 2021-06-06 10:44:18 -04:00