Skip to content

Commit

Permalink
feat: initial files
Browse files Browse the repository at this point in the history
Copied from galexrt/fivenet docs/ folder.

Signed-off-by: Alexander Trost <[email protected]>
  • Loading branch information
galexrt committed Apr 22, 2024
0 parents commit 352a824
Show file tree
Hide file tree
Showing 71 changed files with 31,418 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# EditorConfig is awesome: https://EditorConfig.org

# top-most EditorConfig file
root = true

[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.{yml,yaml}]
indent_size = 2

[Makefile]
indent_style = tab
indent_size = 4

[*.json]
indent_style = space
indent_size = 4
insert_final_newline = false
5 changes: 5 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Production license for @nuxt/ui-pro, get one at https://ui.nuxt.com/pro/purchase
NUXT_UI_PRO_LICENSE=

# Public URL, used for OG Image when running nuxt generate
NUXT_PUBLIC_SITE_URL=
4 changes: 4 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
dist
node_modules
.output
.nuxt
13 changes: 13 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
module.exports = {
root: true,
extends: ['@nuxt/eslint-config'],
rules: {
// Global
quotes: ['error', 'single'],
'quote-props': ['error', 'as-needed'],
// Vue
'vue/multi-word-component-names': 0,
'vue/max-attributes-per-line': 'off',
'vue/no-v-html': 0,
},
};
18 changes: 18 additions & 0 deletions .github/workflows/commitlint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Lint Commit Messages

on:
pull_request:

jobs:
commitlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- run: rm tsconfig.json

- uses: wagoid/commitlint-github-action@v6
with:
configFile: "./.commitlintrc.json"
55 changes: 55 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Docs Build & Publish

on:
push:
branches:
- main

jobs:
docs:
runs-on: ubuntu-latest
permissions:
contents: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
steps:
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 20.12.2
cache: pnpm

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: Cache dependencies
uses: actions/cache@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Get JS dependencies
run: pnpm install

- name: Build site
env:
NUXT_PUBLIC_SITE_URL: "https://fivenet.app/"
NUXT_UI_PRO_LICENSE: "${{ secrets.NUXT_UI_PRO_LICENSE }}"
run: |
pnpm generate
- name: Deploy
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./.output/public/
cname: fivenet.app
30 changes: 30 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Test Code

on:
push:
branches:
- main
- develop
pull_request:
branches:
- main
- develop

jobs:
node-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 20.12.2
cache: pnpm

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Run pnpm build
env:
NUXT_UI_PRO_LICENSE: "${{ secrets.NUXT_UI_PRO_LICENSE }}"
run: pnpm build
27 changes: 27 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Nuxt dev/build outputs
.output
.data
.nuxt
.nitro
.cache
dist

# Node dependencies
node_modules

# Logs
logs
*.log

# Misc
.DS_Store
.fleet
.idea

# Local env files
.env
.env.*
!.env.example

# VSC
.history
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
shamefully-hoist=true
5 changes: 5 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"i18n-ally.localesPaths": [
"lang"
]
}
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# FiveNet Website + Documentation

Has been built using
[![Nuxt UI Pro](https://img.shields.io/badge/Made%20with-Nuxt%20UI%20Pro-00DC82?logo=nuxt.js&labelColor=020420)](https://ui.nuxt.com/pro)

## Development

### Setup

Make sure to install the dependencies:

```bash
pnpm install
```

### Development Server

Start the development server on `http://localhost:3000`:

```bash
pnpm run dev
```
35 changes: 35 additions & 0 deletions app.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
export default defineAppConfig({
ui: {
primary: 'malibu',
gray: 'slate',
footer: {
bottom: {
left: 'text-sm text-gray-500 dark:text-gray-400',
wrapper: 'border-t border-gray-200 dark:border-gray-800',
},
},
icons: {
dynamic: true,
// Nuxt UI Pro Icons
dark: 'i-mdi-moon-and-stars',
light: 'i-mdi-weather-sunny',
system: 'i-mdi-computer',
search: 'i-mdi-search',
external: 'i-mdi-external-link',
chevron: 'i-mdi-chevron-down',
hash: 'i-mdi-hashtag',
menu: 'i-mdi-menu',
close: 'i-mdi-window-close',
check: 'i-mdi-check-circle',
},
},
toc: {
bottom: {
edit: 'https://github.com/galexrt/fivenet/edit/main/content',
},
},
links: {
imprint: '',
privacyPolicy: '',
},
});
65 changes: 65 additions & 0 deletions app.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
<script setup lang="ts">
import type { NavItem, ParsedContent } from '@nuxt/content/dist/runtime/types';
const { t } = useI18n();
const { data: navigation } = await useAsyncData<NavItem[]>('navigation', () => fetchContentNavigation(), {
default: () => [],
});
const { data: files } = useLazyFetch<ParsedContent[]>('/api/search.json', {
default: () => [],
server: false,
});
useHead({
meta: [{ name: 'viewport', content: 'width=device-width, initial-scale=1' }],
link: [{ rel: 'icon', href: '/favicon.ico' }],
htmlAttrs: {
lang: 'en',
},
titleTemplate: (title?: string) => {
if (title?.includes('.')) {
title = t(title);
}
return title ? `${title} - FiveNet` : 'FiveNet';
},
});
useSeoMeta({
titleTemplate: (title?: string) => {
if (title?.includes('.')) {
title = t(title);
}
return title ? `${title} - FiveNet` : 'FiveNet';
},
ogSiteName: 'FiveNet',
ogImage: '/images/social-card.png',
twitterImage: '/images/social-card.png',
twitterCard: 'summary_large_image',
});
provide('navigation', navigation);
</script>

<template>
<div>
<NuxtLoadingIndicator color="repeating-linear-gradient(to right, #55dde0 0%, #34cdfe 50%, #7161ef 100%)" />

<UMain>
<NuxtLayout>
<NuxtPage />
</NuxtLayout>
</UMain>

<Footer />

<ClientOnly>
<LazyUContentSearch :files="files" :navigation="navigation" />
</ClientOnly>

<UModals />
<UNotifications />

<CookieControl />
</div>
</template>
79 changes: 79 additions & 0 deletions app/spa-loading-template.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
<link rel="stylesheet" href="/css/herofull-pattern.css" />

<style>
.loader {
position: fixed;
left: 0;
top: 0;
right: 0;
bottom: 0;
z-index: 99999999;
user-select: none;
}
.loader-overlay {
display: flex;
justify-content: center;
align-items: center;
text-align: center;
min-height: 100vh;
flex-direction: column;
}
.loader-overlay-img {
margin: 25px auto;
}
.loader-overlay img {
max-width: 92px;
}
.loader-spinner {
margin: 25px auto;
}
.loader-spinner svg {
height: 92px;
max-width: 92px;
fill: #ffffff;
animation-name: spin;
animation-duration: 900ms;
animation-iteration-count: infinite;
animation-timing-function: linear;
}

@-moz-keyframes spin {
from {
-moz-transform: rotate(0deg);
}
to {
-moz-transform: rotate(360deg);
}
}
@-webkit-keyframes spin {
from {
-webkit-transform: rotate(0deg);
}
to {
-webkit-transform: rotate(360deg);
}
}
@keyframes spin {
from {
transform: rotate(0deg);
}
to {
transform: rotate(360deg);
}
}
</style>

<div class="loader hero">
<div class="loader-overlay hero-overlay">
<div class="loader-overlay-img">
<img src="/images/logo-200x200.png" alt="FiveNet Logo" />
</div>

<div class="loader-spinner">
<!-- Material Design Icons - Loading Icon -->
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
<path d="M12,4V2A10,10 0 0,0 2,12H4A8,8 0 0,1 12,4Z" />
</svg>
</div>
</div>
</div>
Loading

0 comments on commit 352a824

Please sign in to comment.