-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 892eea7
Showing
48 changed files
with
9,809 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
node_modules | ||
dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: GitHub Pages | ||
|
||
on: | ||
push: | ||
branches: | ||
# The branch where the project source code resides | ||
# 项目源代码所在的分支 | ||
- main | ||
- master | ||
- valaxy | ||
|
||
jobs: | ||
build: | ||
runs-on: ${{ matrix.os }} | ||
|
||
strategy: | ||
matrix: | ||
node-version: [lts/*] | ||
os: [ubuntu-latest] | ||
fail-fast: false | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
registry-url: https://registry.npmjs.org/ | ||
|
||
- name: 📦 Install Dependencies | ||
run: npm i | ||
|
||
- name: 🌌 Build Valaxy Blog | ||
run: npm run build | ||
|
||
- name: 🪤 Deploy to GitHub Pages | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./dist | ||
force_orphan: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# valaxy | ||
|
||
valaxy-fuse-list.json | ||
|
||
# vite-ssg | ||
|
||
.vite-ssg-dist | ||
.vite-ssg-temp | ||
|
||
temp/ | ||
|
||
.DS_Store | ||
*.local | ||
dist | ||
dist-ssr | ||
node_modules | ||
.idea/ | ||
*.log | ||
|
||
components.d.ts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# for pnpm | ||
shamefully-hoist=true | ||
strict-peer-dependencies=false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
/* eslint-disable */ | ||
/* prettier-ignore */ | ||
// @ts-nocheck | ||
// Generated by unplugin-vue-router. ‼️ DO NOT MODIFY THIS FILE ‼️ | ||
// It's recommended to commit this file. | ||
// Make sure to add this file to your tsconfig.json file as an "includes" or "files" entry. | ||
|
||
declare module 'vue-router/auto-routes' { | ||
import type { | ||
RouteRecordInfo, | ||
ParamValue, | ||
ParamValueOneOrMore, | ||
ParamValueZeroOrMore, | ||
ParamValueZeroOrOne, | ||
} from 'vue-router' | ||
|
||
/** | ||
* Route name map generated by unplugin-vue-router | ||
*/ | ||
export interface RouteNamedMap { | ||
'/': RouteRecordInfo<'/', '/', Record<never, never>, Record<never, never>>, | ||
'/[...path]': RouteRecordInfo<'/[...path]', '/:path(.*)', { path: ParamValue<true> }, { path: ParamValue<false> }>, | ||
'/404': RouteRecordInfo<'/404', '/404', Record<never, never>, Record<never, never>>, | ||
'/about/': RouteRecordInfo<'/about/', '/about', Record<never, never>, Record<never, never>>, | ||
'/about/site': RouteRecordInfo<'/about/site', '/about/site', Record<never, never>, Record<never, never>>, | ||
'/archives/': RouteRecordInfo<'/archives/', '/archives', Record<never, never>, Record<never, never>>, | ||
'/categories/': RouteRecordInfo<'/categories/', '/categories', Record<never, never>, Record<never, never>>, | ||
'/links/': RouteRecordInfo<'/links/', '/links', Record<never, never>, Record<never, never>>, | ||
'/page/[page]': RouteRecordInfo<'/page/[page]', '/page/:page', { page: ParamValue<true> }, { page: ParamValue<false> }>, | ||
'/posts/': RouteRecordInfo<'/posts/', '/posts', Record<never, never>, Record<never, never>>, | ||
'/posts/关于DataVz在vue3版本的BUG': RouteRecordInfo<'/posts/关于DataVz在vue3版本的BUG', '/posts/关于DataVz在vue3版本的BUG', Record<never, never>, Record<never, never>>, | ||
'/posts/hello-valaxy': RouteRecordInfo<'/posts/hello-valaxy', '/posts/hello-valaxy', Record<never, never>, Record<never, never>>, | ||
'/posts/test/tset': RouteRecordInfo<'/posts/test/tset', '/posts/test/tset', Record<never, never>, Record<never, never>>, | ||
'/projects/': RouteRecordInfo<'/projects/', '/projects', Record<never, never>, Record<never, never>>, | ||
'/tags/': RouteRecordInfo<'/tags/', '/tags', Record<never, never>, Record<never, never>>, | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"recommendations": [ | ||
"antfu.iconify", | ||
"antfu.unocss", | ||
"csstools.postcss", | ||
"dbaeumer.vscode-eslint", | ||
"vue.volar", | ||
"lokalise.i18n-ally", | ||
"YunYouJun.valaxy" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"cSpell.words": ["valaxy", "valaxyjs"], | ||
"i18n-ally.sourceLanguage": "en", | ||
"i18n-ally.keystyle": "nested", | ||
"i18n-ally.localesPaths": "locales", | ||
"i18n-ally.sortKeys": true, | ||
"prettier.enable": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": "explicit" | ||
}, | ||
"editor.formatOnSave": false, | ||
"files.associations": { | ||
"*.css": "postcss" | ||
}, | ||
"svg.preview.background": "editor" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
FROM node:20-alpine as build-stage | ||
|
||
WORKDIR /app | ||
RUN corepack enable | ||
|
||
COPY .npmrc package.json pnpm-lock.yaml ./ | ||
RUN --mount=type=cache,id=pnpm-store,target=/root/.pnpm-store \ | ||
pnpm install --frozen-lockfile | ||
|
||
COPY . . | ||
RUN pnpm build | ||
|
||
FROM nginx:stable-alpine as production-stage | ||
|
||
COPY nginx.conf /etc/nginx/nginx.conf | ||
COPY --from=build-stage /app/dist /usr/share/nginx/html | ||
EXPOSE 80 | ||
|
||
CMD ["nginx", "-g", "daemon off;"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# create-valaxy | ||
|
||
Example: [valaxy.site](https://valaxy.site) | ||
|
||
## Usage | ||
|
||
```bash | ||
# install | ||
npm i | ||
# or pnpm i | ||
|
||
# start | ||
npm run dev | ||
# or pnpm dev | ||
``` | ||
|
||
See `http://localhost:4859/`, have fun! | ||
|
||
### Config | ||
|
||
Modify `valaxy.config.ts` to custom your blog. | ||
|
||
English & Chinese Docs is coming! | ||
|
||
> Wait a minute. | ||
### Docker | ||
|
||
```bash | ||
docker build . -t your-valaxy-blog-name:latest | ||
``` | ||
|
||
## Structure | ||
|
||
In most cases, you only need to work in the `pages` folder. | ||
|
||
### Main folders | ||
|
||
- `pages`: your all pages | ||
- `posts`: write your posts here, will be counted as posts | ||
- `styles`: override theme styles, `index.scss`/`vars.csss`/`index.css` will be loaded automatically | ||
- `components`: custom your vue components (will be loaded automatically) | ||
- `layouts`: custom layouts (use it by `layout: xxx` in md) | ||
- `locales`: custom i18n | ||
|
||
### Other | ||
|
||
- `.vscode`: recommend some useful plugins & settings, you can preview icon/i18n/class... | ||
- `.github`: GitHub Actions to auto build & deploy to GitHub Pages | ||
- `netlify.toml`: for [netlify](https://www.netlify.com/) | ||
- `vercel.json`: for [vercel](https://vercel.com/) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Components | ||
|
||
Components in this dir will be auto-registered and on-demand, powered by [`unplugin-vue-components`](https://github.com/antfu/unplugin-vue-components). | ||
|
||
## Icons | ||
|
||
You can use icons from almost any icon sets by the power of [Iconify](https://iconify.design/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<script lang="ts" setup> | ||
import { onMounted } from 'vue'; | ||
import YunFooter from 'valaxy-theme-yun/components/YunFooter.vue' | ||
import 'aplayer/dist/APlayer.min.css'; | ||
import APlayer from 'aplayer'; | ||
onMounted(() => { | ||
const ap = new APlayer({ | ||
container: document.getElementById('aplayer'), | ||
fixed: true, | ||
order: 'random', | ||
audio: [ | ||
{ | ||
name: '酒馆儿', | ||
artist: '蛋黄', | ||
url: 'https://music.163.com/song/media/outer/url?id=1466888386.mp3', | ||
cover: 'https://p2.music.126.net/yKVO0wAri_TPgq1ds12e2w==/109951165184677384.jpg?param=130y130', | ||
} | ||
] | ||
}); | ||
}); | ||
</script> | ||
|
||
<template> | ||
<YunFooter> | ||
<div style="display: flex; justify-content: center;"> | ||
<img src="https://count.getloli.com/@:ZengziZhao?theme=booru-twifanartsfw" alt="Ciallo~(∠・ω< )⌒★"> | ||
</div> | ||
<div id="aplayer"></div> | ||
</YunFooter> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<script lang="ts" setup> | ||
import { useAddonWaline } from 'valaxy-addon-waline' | ||
const addon = useAddonWaline() | ||
</script> | ||
|
||
<template> | ||
要不要和我说些什么? | ||
<WalineClient w="full" :options="addon.options" /> | ||
</template> |
Oops, something went wrong.