Archived
Template
1
Fork 0
An Astro template
This repository has been archived on 2024-09-04. You can view files and clone it, but cannot push or open issues or pull requests.
Find a file Use this template
2024-02-02 08:39:08 -05:00
public Add placeholder videos (Should be replaced during production) 2024-02-02 08:38:25 -05:00
src Add Features section 2024-02-02 08:39:08 -05:00
.gitignore Add rest of stuff 2024-01-30 11:04:16 -05:00
astro-i18next.config.mjs Add Astro i18next 2024-01-30 11:00:33 -05:00
astro.config.mjs Minor updates 2024-02-02 08:37:24 -05:00
bun.lockb Minor updates 2024-02-02 08:37:24 -05:00
docker-compose.yml Add Docker files 2024-01-30 11:02:33 -05:00
Dockerfile Add Docker files 2024-01-30 11:02:33 -05:00
LICENSE Closed Source 2024-01-29 08:09:37 -05:00
package.json Minor updates 2024-02-02 08:37:24 -05:00
README.md Provide documentations on dealing with support center. 2024-01-31 09:32:18 -05:00
tsconfig.json Minor updates 2024-02-02 08:37:24 -05:00

FluxNodes

Landing

The image shown is a concept

Support Center and Documents

All articles for Flux's support center is located at /src/content/docs/support/

All documents such as Terms of Service or when polices need to be added, they should be located at /src/content/docs/.

Articles

All articles are written in Markdown, do make sure you're adding the markdown file to the appropriate category folder.

Articles, at the least, should have a title and last updated:

---
title: Title of Article
lastUpdated: 2024-03-15
---

Feedback

Feelback has been integrated into each article, this will help us know if an article is doing well or doing not well.

FluxNodes LLC has a Feelback account, email korbs@sudovanilla.com to get access so you can see how articles are performing.

Components

In articles, you can add built-in components like asides, tabs, code, link cards, and cards.

In order to add components to Markdown files, the file extension has to be .mdx

Asides

Aside Types: note | tip | caution | danger

Asides can be used to let users know of something like tips, warning, and alert of any kind if it needs to be hinted.

As an exmaple, let's say we provide a tutorial of turning a Java Minecraft server into a crack server. We can use a danger aside to alert customers that running a crack server can be risky as they are easier for hackers to get into.

We can do that like so:

:::danger
Running your server with `online-mode` turned off can be risky. Doing this means hackers can log in as an operator and raid and/or destroy your server.

If you need to add more the message like lists or something, here's an example:

:::danger
Your users may be more productive and find your product easier to use thanks to helpful Starlight features.

- Clear navigation
- User-configurable colour theme
- [i18n support](/guides/i18n)

:::

You can add a custom title as well:

:::tip[Did you know?]
Korbs is epic!
:::

Tabs

Using tabs can be useful in some areas.

First, add the Tabs and TabItem component from Starlight:

import { Tabs, TabItem } from '@astrojs/starlight/components'

Then, you can add Tabs:

<Tabs>
  <TabItem label="Stars">
    Sirius, Vega, Betelgeuse
  </TabItem>
  <TabItem label="Moons">
    Io, Europa, Ganymede
  </TabItem>
</Tabs>

This can also be used if you need to provide a different version of the same article. Like providing a version for both Minecraft Java and Bedrock:

<Tabs>
  <TabItem label="Java">
    ## Creating a Minecraft World
    So, here's how we do that in Minecraft Java.
  </TabItem>
  <TabItem label="Bedrock">
    ## Creating a Minecraft World
    So, here's how we do that in Minecraft Bedrock.
  </TabItem>
</Tabs>

Preview

We can use link cards to direct users to another location when it's needed.

First, add the LinkCard and CardGrid component from Starlight:

import { LinkCard, CardGrid } from '@astrojs/starlight/components'

Then, we can add a link card:

<LinkCard
  title="Customizing Starlight"
  description="Learn how to make your Starlight site your own with custom styles, fonts, and more."
  href="/guides/customization/"
/>

The description is not required.

If you add two, have them side by side with CardGrid:

<CardGrid>
  <LinkCard title="Authoring Markdown" href="/guides/authoring-content/" />
  <LinkCard title="Components" href="/guides/components/" />
</CardGrid>

Code

When it comes to provides configuration and other code we can provide to customers, we can do so with the Code component.

First, add the Code component from Starlight:

import { Code } from '@astrojs/starlight/components'

Then, write the code you'll be supplying. As an example, let's do server.properties from Minecraft Java.

export const CustomNameForCode = 
`
gamemode=survival
motd=A Minecraft Server
max-players=20
online-mode=true
server-port=25565
`

Optionally, you can provide the file name, this will help customers know which file we are referring to.

You'll use title to apply the file name. Which in this example will be title={CustomFileName}.

export const CustomFileName = `server.properties`

You can also highlight text in the code using the mark variable in the code. Which in this example will be mark={CustomHighlightText}.

export const CustomHighlightText = ['=20', '25565']

Now, to add the actual code into the article. Make sure to set the language to colors are set correctly.

<Code code={CustomNameForCode} lang="json" title={CustomFileName} mark={CustomHighlightText} />

Preview:

Frontmatter

In each article, there are plenty of options to add to the frontmatter which can be used to add stuff such as banners, table of contents, and other variables.

Banners

Banner Example

To add a banner, add the following:

---
banner:
  content: |
    This is an example of a banner.
    <a href="https://fluxnodes.net/">Important Link</a>
---

Table of Contents

Table of Contents Preview

If for whatever reason you want to enable the table of contents for an article, you can enable by adding:

---
tableOfContents: true
---

Badge

Badges can be used to add a little text next to the article name like "New" or "Outdated".

Varients: note | tip | caution | danger | success | default

---
sidebar:
  badge:
    text: Outdated
    variant: caution
---

Slug

If you need to override the URL, you can use slug.

---
slug: /support/minecraft/world-management
---

Layouts

This should only be set for documents such as Terms of Service and polices.

Starlight provides two options: doc | splash

The doc layouts includes both the sidebar and content, useful for articles. The splash layout removes the sidebar.

---
template: splash
---

Development

Requirements

  • Bun
  • NodeJS 20 or later

Install Packages

Installing packages is required to start run and to build the website, run:

bun install

Run

To start running the website on a port, run:

bun dev

Production

Build Static

To build the website in static mode, run:

bun build

Server Side Rendering

To run the website in server side rendering mode, run:

bun start

Docker

This website is Docker ready!

Build the Docker image, run:

docker build -t fluxnodes.net .

Then, to run:

docker run -d -p 2000:2000 fluxnodes.net

or use the already provided Docker Compose file:

docker compose up -d

sudo might be required on some systems to run Docker commands.