Template - How to Build a Page
This page has just about all of the examples we should be using to build the site. Mkdocs material has a lot of features that are already built-in and able to be incorporated using markdown. We can also customize/add our own (may require a bit of javascript/css formatting) - for example the modal button is custom, and uses in-line html. For any other ideas feel free to add others or create your own!
Text Block
Numbered Lists
- Use Markdown
- With These Indents
- Another sub-list
- Item 2
- With These Indents
Modals
- Modals make is easy to store code snippets in a clickable button
- Includes a pop up window, a copy button, close button
- Notice the format is "inline html" this can be used instead of markdown syntax, but must be understood
The close button is inside of a span, and these icons can also be used to apply to your pages, see below for the example, as well as how its defined in the modal
<span class="material-icons btn-cyber btn-close" onclick="toggleModal('modal-docker-example', null)" style="cursor: pointer;">cancel</span>
- close - Similar to "cancel" but with a different design, often used for cancel operations.
- clear - Another clear or delete icon, straightforward and effective.
- remove - Often used for deletion but less aggressive than a trash icon.
- exit_to_app - Indicates an exit or leave action, which could metaphorically represent closing.
- highlight_off - A more emphasized version of a delete or close icon.
- backspace - Represents removal or going back, which could be conceptually similar to closing.
- keyboard_arrow_down - If you want to imply minimization rather than closing, this could be a creative choice.
Tables
- Tables are slick
Method | Description | Command Example |
---|---|---|
SCP | Secure file transfer using SSH. | scp file.txt user@remote:/path |
SMB | Access Windows shares from Linux. | smbclient //SERVER/share -U user |
Zip/Tar | Compress and decompress files. | zip -r archive.zip folder/ tar -xvf archive.tar |
Mount | Attach storage to the filesystem. | mount /dev/sda1 /mnt |
Code Snippets
- Includes a copy button
- Can be put into collapsable notes/examples/tips
Bash
PowerShell
Collapsable
Copyable SCP Command
Copy and paste the following command to securely transfer files between hosts over SSH:
Another Style
Copy and paste the following command to securely transfer files between hosts over SSH:
Yet Another Style
Copy and paste the following command to securely transfer files between hosts over SSH:
Start with an Open Note
Notice how this note is open when the page is refreshed and the other 3 are not?
Embedded YAML
Full Embedded Document
Embedded PDF
- To embed a pdf, or create a link, follow below
- Notice how the link responds based on formatting
NOTE - Python Cheat Sheets Hyperlink
Refer to the Python Cheat Sheet for specific setup instructions.
Full Embedded Document
- Embed the PDF inside a modal:
Download A File
- Clicking the hyperlink will download the file
Download Sample YAML Template
Template to deploy a sample cloudformation template - Download Template as an example.
Icons
- File Transfer cloud Link with Icon at the End: Standard link to another page with the icon after the text.
- folder_open Open Directory
- Security Settings security
- Tools build Bold Text with Icon: Strong emphasis on a section title with an inline icon.
-
Restore restore Blockquote with Icon: Uses a blockquote for emphasis with an icon.
- Sync Files sync Inline Code with Icon: Demonstrates a command or keyword inline with an icon.
- About Us face
- Settings Button with Icon: An HTML button element with an onclick JavaScript function, showing dynamic interaction.
- Help help_outline Admonition-like Tip with Link and Icon: Uses the question format to indicate a helpful tip or link.