{"id":13457419,"url":"https://github.com/imsyy/home","last_synced_at":"2025-05-13T19:13:25.946Z","repository":{"id":37699610,"uuid":"410210509","full_name":"imsyy/home","owner":"imsyy","description":"个人主页，我的个人主页，个人主页源码，主页模板，homepage","archived":false,"fork":false,"pushed_at":"2025-03-10T08:56:50.000Z","size":16486,"stargazers_count":4027,"open_issues_count":37,"forks_count":2714,"subscribers_count":8,"default_branch":"dev","last_synced_at":"2025-04-27T05:57:11.610Z","etag":null,"topics":["home","homepage"],"latest_commit_sha":null,"homepage":"https://www.imsyy.top","language":"Vue","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/imsyy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-09-25T07:49:40.000Z","updated_at":"2025-04-27T05:51:33.000Z","dependencies_parsed_at":"2022-07-14T08:09:02.180Z","dependency_job_id":"e87ce19a-73cc-4483-9a86-15c0014fcccf","html_url":"https://github.com/imsyy/home","commit_stats":null,"previous_names":[],"tags_count":28,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imsyy%2Fhome","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imsyy%2Fhome/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imsyy%2Fhome/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imsyy%2Fhome/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/imsyy","download_url":"https://codeload.github.com/imsyy/home/tar.gz/refs/heads/dev","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251094662,"owners_count":21535328,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["home","homepage"],"created_at":"2024-07-31T08:01:43.140Z","updated_at":"2025-04-27T05:57:15.663Z","avatar_url":"https://github.com/imsyy.png","language":"Vue","funding_links":[],"categories":["Vue"],"sub_categories":[],"readme":"简体中文 | [English](./README_EN.md)\r\n\r\n\u003e [!IMPORTANT]\r\n\u003e ## 致大家\r\n\u003e 此项目最初只是一个简单的主页。然而，随着越来越多的小伙伴发现了这个项目，它受到了大量本不应有的关注。而且，此项目作为初学前端的作品，其代码相当杂乱且质量低下。此外，该项目还遭到众多不明资源站或下载站的倒卖，致使许多不明真相的购买者从源代码中找到本人的联系方式进行问题咨询或提出功能需求。但由于目前个人生活方面的原因，且本人未曾从此项目获取任何收益，所以已无力维护此项目。该仓库不会存档，会积极接受各位大佬的 PR，不过不会针对任何新功能或 Bug 做出更新，敬请谅解！\r\n\r\n\u003cp\u003e\r\n\u003cstrong\u003e\u003ch2\u003e無名の主页\u003c/h2\u003e\u003c/strong\u003e\r\n简单的小主页，原来的看够了，重新弄了一个\r\n\u003c/p\u003e\r\n\r\n![無名の主页](/screenshots/main.jpg)\r\n\r\n\u003e 主页的 Logo 字体已经过压缩，若用本站 Logo 以外的字母会变回默认字体，这里是 [完整字体](https://file.imsyy.top/font/Other/Pacifico-Regular.ttf)，若无法下载，可将字体目录下的 `Pacifico-Regular-all.ttf` 进行替换\r\n\r\n### 👀 Demo\r\n\r\n\u003e 由于 CDN 缓存原因，查看最新效果可能需要 `Ctrl` + `F5` 强制刷新浏览器缓存\r\n\r\n- [無名の主页](https://www.imsyy.top)\r\n- [無名の主页 - Dev](https://home-imsyy.vercel.app)\r\n- [無名の主页 - 备用线路](https://home-5iw.pages.dev)\r\n\r\n### 🎉 功能\r\n\r\n- [x] 载入动画\r\n- [x] 站点简介\r\n- [x] Hitokoto 一言\r\n- [x] 日期及时间\r\n- [x] 实时天气\r\n- [x] 时光进度条\r\n- [x] 音乐播放器\r\n- [x] 移动端适配\r\n\r\n### ⚙️ 自动部署\r\n\r\n如果遇到构建环境或者打包过程出现错误，则可以采用 `Github Actions` 来进行自动构建\r\n\r\n- 在成功 `fork` 仓库后，前往 `Actions` 页面，若您是首次开启，则会出现下面的提示，点击开启\r\n\r\n  ![步骤1](/screenshots/step1.jpg)\r\n\r\n- 然后在仓库中进行任意修改后均会触发工作流的运行，在工作流完成后，会在下方生成一个可供下载的压缩包，这就是构建出的静态文件，可自行上传至服务器\r\n\r\n  ![步骤2](/screenshots/step2.jpg)\r\n\r\n### ⚙️ 手动部署\r\n\r\n- **安装** [node.js](https://nodejs.org/zh-cn/) **环境**\r\n\r\n  \u003e node \u003e 16.16.0  \r\n  \u003e npm \u003e 8.15.0\r\n\r\n- 然后以 **管理员权限** 运行 `cmd` 终端，并 `cd` 到 项目根目录\r\n- 在 `终端` 中输入：\r\n\r\n```bash\r\n# 安装 pnpm\r\nnpm install -g pnpm\r\n\r\n# 安装依赖\r\npnpm install\r\n\r\n# 预览\r\npnpm dev\r\n\r\n# 构建\r\npnpm build\r\n```\r\n\r\n\u003e 构建完成后，静态资源会在 **`dist` 目录** 中生成，可将 **`dist` 文件夹下的文件**上传至服务器，也可使用 `Vercel` 等托管平台一键导入并自动部署\r\n\r\n### ⚙️ Docker 部署\r\n\r\n\u003e 安装及配置 Docker 将不在此处说明，请自行解决\r\n\r\n```bash\r\n# 构建\r\ndocker build -t home .\r\n# 运行\r\ndocker run -p 12445:12445 -d home\r\n```\r\n\r\n### ⚙️ Vercel 部署\r\n\r\n\u003e 其他部署平台大致相同，在此不做说明\r\n\r\n1. 点击本仓库右上角的 `Fork`，复制本仓库到你的 `GitHub` 账号\r\n2. 复制 `/.env.example` 文件并重命名为 `/.env`（ 重要 ）\r\n3. 按需修改 `/.env` 文件中的配置\r\n4. 点击 `Deploy`，即可成功部署\r\n\r\n### 网站链接\r\n\r\n在 `src/assets/siteLinks.json` 中可以自定义网站链接（以指向自己的网站）:\r\n\r\n```json\r\n{\r\n  \"icon\": \"Blog\",\r\n  \"name\": \"博客\",\r\n  \"link\": \"https://blog.imsyy.top/\"\r\n},\r\n```\r\n\r\n其中 `icon` 网站链接的图标可以在 `src/components/Links/index.vue` 中添加:\r\n\r\n```js\r\n// 可前往 https://www.xicons.org 自行挑选并在此处引入\r\n// 此处引入的是 fa 类型\r\nimport {\r\n  Link,\r\n  Blog,\r\n  CompactDisc,\r\n  Cloud,\r\n  Compass,\r\n  Book,\r\n  Fire,\r\n  LaptopCode,\r\n} from \"@vicons/fa\";\r\n\r\n...\r\n\r\n// 网站链接图标\r\nconst siteIcon = {\r\n  Blog,\r\n  Cloud,\r\n  CompactDisc,\r\n  Compass,\r\n  Book,\r\n  Fire,\r\n  LaptopCode,\r\n};\r\n```\r\n\r\n### 社交链接\r\n\r\n在 `src/assets/socialLinks.json` 中可以自定义社交链接。\r\n\r\n### 天气\r\n\r\n天气及地区获取需要 `高德开放平台` 相关 API\r\n\r\n- 前往 [高德开放平台控制台](https://console.amap.com/dev/index) 创建一个 `Web 服务` 类型的 `Key`，并将 `Key` 填入 `.env` 中的 `VITE_WEATHER_KEY` 中\r\n\r\n也可自行更换其他方式\r\n\r\n### 音乐\r\n\r\n\u003e 本项目采用了基于 `MetingJS` 的 `Aplayer` 音乐播放器，可实现快速自定义歌单  \r\n\u003e \\*仅支持 **中国大陆地区**\r\n\r\n请在 `.env` 文件中更改歌曲相关参数即可实现自定义歌单列表\r\n\r\n```bash\r\n# 歌曲 API 地址\r\nVITE_SONG_API = \"https://api-meting.imsyy.top\"\r\n# 歌曲服务器 ( netease-网易云, tencent-qq音乐 )\r\nVITE_SONG_SERVER = \"netease\"\r\n# 播放类型 ( song-歌曲, playlist-播放列表, album-专辑, search-搜索, artist-艺术家 )\r\nVITE_SONG_TYPE = \"playlist\"\r\n# 播放 ID\r\nVITE_SONG_ID = \"7452421335\"\r\n```\r\n\r\n### 字体\r\n\r\n现采用 `HarmonyOS Sans` 开源字体，采用字体拆分，提升加载速度\r\n\r\n\u003e 由于本站 `CDN` 已开启防盗链，**非本站域名不可访问**，请将字体引入链接更改为下方内容，否则 **自定义字体将失效**\r\n\u003e\r\n\u003e `https://s1.hdslb.com/bfs/static/jinkela/long/font/regular.css`\r\n\r\n\u003cdetails\u003e\r\n\u003csummary\u003e旧版方式\u003c/summary\u003e\r\n\r\n\u003e 由于本项目引入了中文字体，需要压缩中文字体以提高网页加载速度（ 也可以取消使用中文字体 ）\r\n\r\n#### 中文字体去除繁体\r\n\r\n- 安装 `Python 3.7` 和 `pip`\r\n- 运行 `pip install fonttools`\r\n- 下载 [sc_unicode.txt](https://gist.githubusercontent.com/imaegoo/d64e5088b723c2e02c40985f55ff12db/raw/5ebd2ce49418c73459a9dfe050483409306a6c1d/sc_unicode.txt)\r\n- 运行 `pyftsubset 字体名称.ttf --unicodes-file=sc_unicode.txt`\r\n\r\n#### 字体进一步压缩\r\n\r\n- 编译安装 `Google woff2`\r\n\r\n```bash\r\nsudo apt-get install -y git g++ make\r\ngit clone --recursive https://github.com/google/woff2.git\r\ncd woff2\r\nmake clean all\r\n```\r\n\r\n- 再压缩字体\r\n\r\n```\r\n./woff2_compress ./字体名称.ttf\r\n```\r\n\r\n- 最终可对原字体进行缓加载，**先行加载压缩后的字体**\r\n\r\n\u003e 详细信息可前往 [虹墨空间站](https://www.imaegoo.com/2020/chinese-font-compress/) 查看原文\r\n\r\n\u003c/details\u003e\r\n\r\n### 网站图标及网站背景\r\n\r\n#### 网站背景\r\n\r\n可以在 `public/images` 中修改网站背景\r\n\r\n如果想要添加更多的本地图片作为网站背景，可以将图片重命名 `background+数字` 的形式，并在 `src/components/Background/index.vue` 中进行修改：\r\n\r\n```js\r\nif (type == 0) {\r\n  // 修改此处 Math.random() 后面的第一个数字为图片的数量\r\n  bgUrl.value = `/images/background${Math.floor(Math.random() * 10 + 1)}.webp`;\r\n}\r\n```\r\n\r\n#### 网站图标\r\n\r\n可以在 `public/images/icon` 中修改网站图标。\r\n\r\n### 技术栈\r\n\r\n- [Vue](https://cn.vuejs.org/)\r\n- [Vite](https://vitejs.cn/vite3-cn/)\r\n- [Pinia](https://pinia.vuejs.org/zh/)\r\n- [IconPark](https://iconpark.oceanengine.com/official)\r\n- [xicons](https://xicons.org/)\r\n- [Aplayer](https://aplayer.js.org/)\r\n\r\n### API\r\n\r\n- [韩小韩 WebAPI 接口](https://api.vvhan.com/)\r\n- [搏天 API](https://api.btstu.cn/doc/sjbz.php)\r\n- [教书先生 API](https://api.oioweb.cn/doc/weather/GetWeather)\r\n- [高德开放平台](https://lbs.amap.com/)\r\n- [Hitokoto 一言](https://hitokoto.cn/)\r\n\r\n## Star History\r\n\r\n[![Star History Chart](https://api.star-history.com/svg?repos=imsyy/home\u0026type=Date)](https://star-history.com/#imsyy/home\u0026Date)\r\n\r\n\u003ca title=\"SSL\" target=\"_blank\" href=\"https://myssl.com/seal/detail?domain=blog.imsyy.top\"\u003e\u003cimg src=\"https://img.shields.io/badge/MySSL-安全认证-brightgreen\"\u003e\u003c/a\u003e\u0026nbsp;\u003ca title=\"CDN\" target=\"_blank\" href=\"https://cdnjs.com/\"\u003e\u003cimg src=\"https://img.shields.io/badge/CDN-Cloudflare-blue\"\u003e\u003c/a\u003e\u0026nbsp;\u003ca title=\"Copyright\" target=\"_blank\" href=\"https://imsyy.top/\"\u003e\u003cimg src=\"https://img.shields.io/badge/Copyright%20%C2%A9%202020--2023-%E7%84%A1%E5%90%8D-red\"\u003e\u003c/a\u003e\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimsyy%2Fhome","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimsyy%2Fhome","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimsyy%2Fhome/lists"}