Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update documentation #95

Merged
merged 2 commits into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ theme by [Alex Gil](https://twitter.com/elotroalex).
- Metadata in OpenGraph to play nice with social media and search engines
- Automatic table of content generation
- Simple search functionality
- Comments system
- Annotations via [hypothes.is](https://hypothes.is/)
- Contact form
- Custom `robots.txt` (changes values based on environment)
Expand Down
2 changes: 1 addition & 1 deletion exampleSite/config/_default/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ markup:
goldmark:
parser:
attribute:
# Enable custom attribute support for blocks
# Enable custom attribute support for blocks
block: true

# If enableGitInfo is true, it will override any lastmod dates in our
Expand Down
6 changes: 3 additions & 3 deletions exampleSite/content/documentation/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ By default Hugo uses a special Markdown processor called Goldmark. The processor

## Genres

Ed offers three different layouts: poem, narrative and drama. To create content of a certain genre, create a file in the appropriate folder. For example, if you want to create a poem, create a file in the `content/poem` folder. Another way is to indicated genre in the YAML front matter on your texts. The templates that govern how these genres are displayed can be found in the Ed's `layouts` folder. Redefining these layouts in project wide level will allow you to tweak the stylesheets according to your different needs. Out of the box, Ed contains some special instructions for poetry in its stylesheets that allow you to deal with some of the peculiarities of poetry layouts.
Ed offers four different layouts: poem, narrative, drama and simple post. To create content of a certain genre, create a file in the appropriate folder. For example, if you want to create a poem, create a file in the `content/poems` folder. Another way is to indicated genre in the YAML front matter on your texts. The templates that govern how these genres are displayed can be found in the Ed's `layouts` folder. Redefining these layouts in project wide level will allow you to tweak the stylesheets according to your different needs. Out of the box, Ed contains some special instructions for poetry in its stylesheets that allow you to deal with some of the peculiarities of poetry layouts.

To indicate lines in poetry we use the line syntax from Markdown:

Expand Down Expand Up @@ -404,8 +404,8 @@ That should do it. If you have suggestions on how to improve Ed, make sure to le

Happy editing!

Serghei Iakovlev
Serghei Iakovlev\
April 2024

Alex Gil
Alex Gil\
April 2016
18 changes: 9 additions & 9 deletions netlify-preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,22 +21,22 @@ fs.readFile(path.resolve(__dirname, netlifyConfig), 'utf8', (err, data) => {
// <- default-src 'self' blob:;
line = line.replace(/(default-src) ('self')(;)/, '$1 $2 blob:$3');

// -> style-src 'self' cdn.hypothes.is;
// <- style-src 'self' 'unsafe-inline' cdn.hypothes.is;
line = line.replace(/(style-src) ('self') (cdn\.hypothes\.is)(;)/, '$1 $2 $3 \'unsafe-inline\'$4');
// -> style-src 'self' cdn.hypothes.is giscus.app;
// <- style-src 'self' 'unsafe-inline' cdn.hypothes.is giscus.app;
line = line.replace(/(style-src) ('self') (cdn\.hypothes\.is giscus\.app)(;)/, '$1 $2 $3 \'unsafe-inline\'$4');

// -> media-src 'self';
// <- media-src 'self' blob: https://app.netlify.com;
line = line.replace(/(media-src) ('self')(;)/, '$1 $2 blob: https://app.netlify.com$3');

// -> frame-src hypothes.is;
// <- frame-src hypothes.is app.netlify.com;
line = line.replace(/(frame-src) (hypothes\.is)(;)/, '$1 $2 app.netlify.com$3');
// -> frame-src hypothes.is giscus.app;
// <- frame-src hypothes.is giscus.app app.netlify.com;
line = line.replace(/(frame-src) (hypothes\.is giscus\.app)(;)/, '$1 $2 app.netlify.com$3');

// -> script-src 'self' www.googletagmanager.com hypothes.is cdn.hypothes.is;
// <- script-src 'self' www.googletagmanager.com hypothes.is cdn.hypothes.is netlify-cdp-loader.netlify.app;
// -> script-src 'self' www.googletagmanager.com hypothes.is cdn.hypothes.is giscus.app;
// <- script-src 'self' www.googletagmanager.com hypothes.is cdn.hypothes.is giscus.app netlify-cdp-loader.netlify.app;
line = line.replace(
/(script-src) ('self' www\.googletagmanager\.com hypothes\.is cdn\.hypothes\.is)(;)/,
/(script-src) ('self' www\.googletagmanager\.com hypothes\.is cdn\.hypothes\.is giscus\.app)(;)/,
'$1 $2 netlify-cdp-loader.netlify.app$3'
);

Expand Down
6 changes: 3 additions & 3 deletions netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,14 @@
# (including inline scripts and event-handling HTML attributes).
Content-Security-Policy = """
default-src 'self';
script-src 'self' www.googletagmanager.com hypothes.is cdn.hypothes.is;
style-src 'self' cdn.hypothes.is;
script-src 'self' www.googletagmanager.com hypothes.is cdn.hypothes.is giscus.app;
style-src 'self' cdn.hypothes.is giscus.app;
img-src 'self' data: *.google-analytics.com www.googletagmanager.com www.gstatic.com stats.g.doubleclick.net;
font-src 'self';
connect-src 'self' *.google-analytics.com *.analytics.google.com analytics.google.com www.googletagmanager.com stats.g.doubleclick.net;
media-src 'self';
object-src 'self';
frame-src hypothes.is;
frame-src hypothes.is giscus.app;
worker-src 'self';
frame-ancestors 'none';
form-action 'self' submit-form.com;
Expand Down