Skip to content

Commit cd586ea

Browse files
committed
Update readme and example slides
1 parent 1a3c9e1 commit cd586ea

File tree

3 files changed

+69
-26
lines changed

3 files changed

+69
-26
lines changed

example.md

+23-18
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,18 @@
11
---
2-
marp: true
2+
# Edit this metadata
33
title: New Codestar Marp theme
44
author: Hamza Haiken
5-
theme: codestar
6-
# class: invert
7-
paginate: true
85
header: "New Codestar Marp theme"
96
footer: "Example slides"
7+
8+
# Uncomment for dark mode
9+
# class: invert
1010
transition: wipe
11+
12+
# Keep these settings
13+
marp: true
14+
theme: codestar
15+
paginate: true
1116
math: mathjax
1217
---
1318

@@ -20,28 +25,24 @@ math: mathjax
2025

2126
---
2227

23-
## this is what title<br>cards look like
28+
<center>
2429

25-
Optional sub-title
30+
Scan to follow along or keep the link for later:
2631

27-
<!-- Presenter notes are derived from HTML comments -->
28-
29-
---
32+
<!-- Update this link with the name of your slides instead of 'example' -->
33+
![w:256px](https://api.qrserver.com/v1/create-qr-code/?size=256x256&data=code-star.github.io/codestar-marp/example/&margin=16)
3034

31-
<!-- _footer: That guy is doing some serious business -->
35+
*Link to the slides*
3236

33-
![bg opacity:.1](https://picsum.photos/1080?image=5)
37+
</center>
3438

35-
A slide with a background image
36-
<br>
39+
---
3740

38-
<center>
41+
## this is what title<br>cards look like
3942

40-
<!-- Update this link with the name of your slides instead of 'example' -->
41-
![w:256px](https://api.qrserver.com/v1/create-qr-code/?size=256x256&data=code-star.github.io/codestar-marp/example/&margin=16)
42-
*Link to the slides*
43+
Optional sub-title
4344

44-
</center>
45+
<!-- Presenter notes are derived from HTML comments -->
4546

4647
---
4748

@@ -126,6 +127,10 @@ And numbered:
126127

127128
---
128129

130+
<!-- _footer: That guy is doing some serious business -->
131+
132+
![bg opacity:.1](https://picsum.photos/1080?image=5)
133+
129134
**bold!** _italic!_ emoji codes: :satellite: :otter:
130135

131136
link: https://github.com/code-star

listing/listing.css

+1
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,7 @@ button, input, ul, li {
135135
margin-bottom: -0.15em;
136136
overflow: hidden;
137137
text-overflow: ellipsis;
138+
justify-content: start;
138139
}
139140

140141
.author {

readme.md

+45-8
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
# Codestar theme for Marp
22

3+
Contents:
4+
35
- [Theme features](#features)
46
- [Usage](#usage)
7+
- [Editing guidelines](#editing-guidelines)
58
- [Development](#development)
69

10+
---
11+
712
## Features
813

914
- The new Codestar styles and fonts
@@ -18,23 +23,55 @@ Quick links:
1823

1924
## Usage
2025

21-
- Install [Marp for VS Code](https://marketplace.visualstudio.com/items?itemName=marp-team.marp-vscode)
26+
- Requirements:
27+
- If you want to write your Markdown in VS Code with a live preview: [Marp for VS Code](https://marketplace.visualstudio.com/items?itemName=marp-team.marp-vscode)
28+
- Or, if you want to run a live preview server: `npm install -g @marp-team/marp-cli`
29+
2230
- Run:
2331

2432
```bash
2533
mkdir decks/presentation-name
2634
cp example.md decks/presentation-name/slides.md
2735
```
28-
- Extra resource files (for example images) can go in that new folder as well
29-
- Edit the new file in VS Code, and in the top right corner of the editor, click the preview button (or <kbd>⌘ + K, V</kbd>)
30-
- Alternatively, you can run `marp -s --theme theme/codestar.css .` for a live server with a directory listing that you can navigate in a browser (you'll need [`marp-cli`](#development))
31-
- Make a pull request and merge, GitHub actions will build the slides and serve them on GitHub pages (TODO: link)
3236

33-
### Quick links to some reference pages:
37+
Extra resource files (for example images) can go in that new folder as well.
38+
39+
- Edit and preview your slides:
40+
41+
- VS Code: open this repository's folder, edit the new `slides.md` file, and in the top right corner of the editor, click the preview button (or <kbd>⌘ + K, V</kbd>).
42+
43+
- `marp-cli`: from this repo's root, run `marp -s --theme theme/codestar.css .` to start a live server with a directory listing that you can navigate in a browser.
44+
45+
- Make a pull request and merge. GitHub actions will build the slides and serve them on our [decks listing hosted on GH pages](https://code-star.github.io/codestar-marp/).
46+
47+
## Editing guidelines
48+
49+
- Fill all the metadata in the front matter
50+
- Keep the `div` structure of the title card intact
51+
- Make sure to update the QR code's link by replacing `example/` with the name of your presentation's directory.
52+
- If you prefer a dark theme, uncomment `class: invert` in the front matter.
53+
- Keep section title cards short, with at most a subtitle.
54+
- Presenter notes can be added using regular HTML comments, and will be visible on each slide when using the presenter mode. To start presenter mode, move the mouse over the presentation and click the right button on the toolbar.
55+
- Metadata directives can be changed for a particular slide. For example, if you want a different footer on one slide, include this:
56+
57+
```html
58+
<!-- _footer: This slide has a different footer! -->
59+
```
60+
61+
If you want a slide without a footer or header, add:
62+
63+
```html
64+
<!-- _header: '' -->
65+
<!-- _footer: '' -->
66+
```
67+
- For reference on other formatting options, slide layouts, slide backgrounds, etc., check out all the slides from `examples.md` (you can also watch that presentation [here](https://code-star.github.io/codestar-marp/example/)).
68+
69+
Quick reference links:
3470

71+
- [Image syntax](https://marpit.marp.app/image-syntax)
3572
- [Transitions](https://github.com/marp-team/marp-cli/blob/main/docs/bespoke-transitions/README.md#built-in-transitions)
36-
- [Emoji codes](https://github.com/markdown-it/markdown-it-emoji/blob/master/lib/data/full.mjs)
37-
TODO: More links
73+
- [Directives](https://marpit.marp.app/directives)
74+
- [Supported emoji codes](https://github.com/markdown-it/markdown-it-emoji/blob/master/lib/data/full.mjs)
3875

3976
## Development
4077

0 commit comments

Comments
 (0)