Skip to content

Commit

Permalink
add a proper example page, and a guide to editing docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mirrorcult committed Sep 12, 2023
1 parent 5b5eee9 commit deb632a
Show file tree
Hide file tree
Showing 10 changed files with 129 additions and 47 deletions.
17 changes: 8 additions & 9 deletions src/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,13 @@ Space Wizards Development Wiki

[The Robust Book](index.md)

- [Links](en/links.md)
Meta
====

----------------------

- [Guide to Editing Docs](en/meta/guide-to-editing-docs.md)
- [Docs Example Page](en/meta/docs-example-page.md)

General Development
===================
Expand Down Expand Up @@ -132,11 +138,4 @@ Community
- [Grafana Dashboards](en/community/infrastructure-reference/grafana-dashboards.md)
- [Space Wizards Hub Rules](en/community/space-wizards-hub-rules.md)
- [Space Wizards Role Hierarchy](en/community/space-wizards-role-hierarchy.md)
- [Discord Rich Presence Repository](en/community/discord-rich-presence-repository.md)

Miscellaneous
=============

----------------------

- [Test Page](en/miscellaneous/test_page.md)
- [Discord Rich Presence Repository](en/community/discord-rich-presence-repository.md)
Binary file added src/en/assets/images/meta-create-fork.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/en/assets/images/meta-edit-file.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/en/assets/images/meta-edit-page-button.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 0 additions & 3 deletions src/en/links.md

This file was deleted.

88 changes: 88 additions & 0 deletions src/en/meta/docs-example-page.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
# Docs Example Page

This page is used for showing off plugins and styling available in this `mdbook` instance.

Its best to view the raw markdown source of this page, which you can do using the button in the top right and clicking 'Code' instead of 'Preview' on GitHub.

## markdown

Best to look at [a general markdown guide](https://www.markdownguide.org/getting-started/) for this! There's a lot.

**bold**

*italic*

~~strikethrough~~

## templates

You can also pass args into a template invocation which are interpolated into the page by `mdbook-template`. See [their docs](https://github.com/sgoudham/mdbook-template#format) for more info

`\{\}#template {link to template file})\}\}`

{{#template ../templates/outdated.md}}

{{#template ../templates/wip.md}}

{{#template ../templates/stub.md}}

## admonishments

All available admonishment types.

To use an admonishment:
``````
```admonishment {type} "{text you want as title, or leave blank}"
description
```
``````

```admonish note
```

```admonish abstract
```

```admonish info
```

```admonish tip
```

```admonish success
```

```admonish question
```

```admonish warning
```

```admonish failure
```

```admonish danger
```

```admonish bug
```

```admonish example
```

```admonish quote
```

## latex

\\[ \mu = \frac{1}{N} \sum_{i=0} x_i \\]

## mermaid

```mermaid
graph TD;
A-->B;
A-->C;
B-->D;
C-->D;
```
27 changes: 27 additions & 0 deletions src/en/meta/guide-to-editing-docs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Guide to Editing Docs

Hello! As you may be able to notice, this docs site is completely open source and free to edit on GitHub. You can see the GitHub page for this site at [https://github.com/space-wizards/docs](https://github.com/space-wizards/docs).

There are a couple things to keep in mind when contributing. While we disallow web-edit PRs (those made exclusively on GitHub) on the main Space Station 14 & Robust Toolbox repos, that is not the case here. **Web-editing is encouraged** to make editing documentation as painless as possible.

If you want to get an idea of what features are at your disposal when writing documentation, go to our [Docs Example Page](./docs-example-page.md).

To start a basic edit of a page, simply follow these steps:

1. Create an accout on GitHub, or log in if you already have one.

2. Fork the [space-wizards/docs](https://github.com/space-wizards/docs) repo on GitHub.

![](../assets/images/meta-create-fork.png)

3. Click the 'View & Edit Page on GitHub` icon in the very top right of any page on this site.

![](../assets/images/meta-edit-page-button.png)

4. Click the 'Edit this file' button at the top right of the file view.

![](../assets/images/meta-edit-file.png)

5. Make your changes, then commit & create a pull request! We'll handle the rest.

More in-depth information for contributors, like how to test locally & port pages from our old docs site, is available on our [README](https://github.com/space-wizards/docs/blob/master/README.md) for the GitHub docs site.
33 changes: 0 additions & 33 deletions src/en/miscellaneous/test_page.md

This file was deleted.

6 changes: 5 additions & 1 deletion src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@ Do not rely on any links to this site (spacestation14.io/docs) to remain alive
This is the developer's wiki. If you are a player, you are looking for [the player wiki](https://wiki.spacestation14.io/wiki/Main_Page).
```

This wiki is written in [Markdown](https://docs.requarks.io/en/editors/markdown). If you would like to make contributions to this wiki, it's hosted fully open source on GitHub and you can make a webedit PR to any page using the button in the top right.
This wiki is written in [Markdown](https://docs.requarks.io/en/editors/markdown) using `mdbook`. You can view our README.md for the docs site [here](https://github.com/space-wizards/docs/blob/master/README.md), which has useful information.

```admonish info "Making contributions"
If you would like to make contributions to this documentation site, it's hosted fully open source on GitHub and you can make a webedit PR to any page using the button in the top right. Check out our [Guide to Editing Docs](en/meta/guide-to-editing-docs.md) page for more information.
```

## Getting Started

Expand Down
2 changes: 1 addition & 1 deletion theme/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@
</a>
{{/if}}
{{#if git_repository_edit_url}}
<a href="{{git_repository_edit_url}}" title="Make an edit" aria-label="Make an edit">
<a href="{{git_repository_edit_url}}" title="View & edit page on GitHub" aria-label="View & edit page on GitHub">
<i id="git-edit-button" class="fa fa-edit"></i>
</a>
{{/if}}
Expand Down

0 comments on commit deb632a

Please sign in to comment.