Skip to content

Commit b7dc7a5

Browse files
committed
fix a lot
Signed-off-by: zxypro1 <1018995004@qq.com>
1 parent c2c2b5a commit b7dc7a5

26 files changed

+509
-364
lines changed

astro.config.mjs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import icon from "astro-icon";
66
import { SIDEBAR, SITE } from "./src/utils/config.ts";
77
import topLevelAwait from "vite-plugin-top-level-await";
88
import starlightUtils from "@lorenzo_lewis/starlight-utils";
9+
import rehypeAstroRelativeMarkdownLinks from "astro-rehype-relative-markdown-links";
910

1011
// https://astro.build/config
1112
export default defineConfig({
@@ -16,13 +17,18 @@ export default defineConfig({
1617
image: {
1718
domain: ["img.alicdn"],
1819
},
20+
// markdown: {
21+
// rehypePlugins: [rehypeAstroRelativeMarkdownLinks],
22+
// },
23+
// trailingSlash: 'never',
1924
integrations: [
2025
autoImportComponents(),
2126
starlight({
2227
title: SITE.name,
2328
favicon: "/favicon.png",
2429
logo: {
25-
src: "./public/assets/logo.png",
30+
light: "./public/assets/logo-black.svg",
31+
dark: "./public/assets/logo.png",
2632
replacesTitle: true,
2733
},
2834
//自定义组件

package-lock.json

Lines changed: 24 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"astro-compress": "^2.2.11",
3434
"astro-icon": "^1.1.0",
3535
"astro-navbar": "^2.3.3",
36+
"astro-rehype-relative-markdown-links": "^0.15.0",
3637
"astro-seo": "^0.8.4",
3738
"axios": "^1.7.4",
3839
"date-fns": "^3.4.0",

public/assets/logo-black.svg

Lines changed: 1 addition & 0 deletions
Loading

s-test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
edition: 3.0.0
77
name: flask-app
8-
access: default
8+
access: agentcraft
99
vars:
1010
region: cn-hangzhou
1111
resources:

src/components/Footer.astro

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -76,16 +76,16 @@ const contactWays = [{
7676

7777
<div class="col-span-4 lg:col-span-2">
7878
<div class="rounded-lg p-4">
79-
<h2 class="text-sm font-medium mb-4 text-info">DOCUMENTATION</h2>
79+
<h2 class="text-sm font-medium mb-4 text-info">相关链接</h2>
8080
<div class="flex flex-col space-y-2 text-white text-sm mt-10">
81-
<a>帮助文档</a>
82-
<a>Serverless社区</a>
83-
<a>Registry</a>
81+
<a href="/docs/overview">帮助文档</a>
82+
<!-- <a>Serverless社区</a> -->
83+
<a href="https://registry.serverless-devs.com/">Registry</a>
8484
</div>
8585
</div>
8686
</div>
8787

88-
<div class="col-span-4 lg:col-span-2">
88+
<!-- <div class="col-span-4 lg:col-span-2">
8989
<div class="rounded-lg p-4">
9090
<h2 class="text-sm font-medium mb-4 text-info">RESOURCES (文案占位)</h2>
9191
<div class="flex flex-col space-y-2 text-white text-sm mt-10">
@@ -94,7 +94,7 @@ const contactWays = [{
9494
<a>CLoud Service EDAS (文案占位)</a>
9595
</div>
9696
</div>
97-
</div>
97+
</div> -->
9898
</div>
9999
</div>
100100

src/components/LineCard.astro

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,33 @@ import {Picture} from "astro:assets";
33
import blueFireIcon from "@assets/icons/blurFire.svg";
44
import starIcon from "@assets/icons/star.svg";
55
6-
const {url, title, description, date, hot} = Astro.props;
6+
const {url, title, description, date, hot, logo} = Astro.props;
7+
const iconMap = {
8+
'start-springboot-v3': starIcon,
9+
'video-transcode-v3': starIcon,
10+
'start-modelscope-v3': starIcon,
11+
'fc-ai-character': starIcon,
12+
'fc-stable-diffusion-v3': starIcon,
13+
'start-flask-v3': starIcon
14+
}
715
---
816

917
<div class="card flex flex-col gap-8 text-white border border-[#4a4c57] rounded-xl p-5 hover:bg-[#1e1f22]" onclick=`window.open('${url}', '_blank')` >
10-
<div class="p-3 bg-white bg-opacity-5 rounded-xl border-[0.8px] border-[#b3b6c1] w-fit">
11-
<Picture class="rounded-full" src={starIcon} alt="starIcon"/>
18+
<div class="p-3 bg-white bg-opacity-5 rounded-xl border-[0.8px] border-[#b3b6c1] w-[52px] h-[52px]">
19+
<Picture
20+
class="object-contain w-full h-full"
21+
src={iconMap[title] || logo || starIcon}
22+
alt="starIcon"
23+
width={52}
24+
height={52}
25+
/>
1226
</div>
1327
<div class="flex flex-col">
1428
<a class="text-lg font-bold title"
1529
href={url}>{title}</a>
1630
<p class="text-sm text-info">{description}</p>
1731
</div>
18-
<div class="flex flex-row justify-between items-center">
32+
<div class="flex flex-row justify-between items-center mt-auto">
1933
<div class="flex flex-row gap-1 items-center text-white">
2034
<Picture class="rounded-full" src={blueFireIcon} alt="blueFireIcon"/>
2135
<span class="text-sm font-light">{hot}</span>

src/components/ThemeProvider.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import type {Props} from '@astrojs/starlight/props';
77
const storedTheme =
88
typeof localStorage !== 'undefined' && localStorage.getItem('starlight-theme');
99
const theme =
10-
storedTheme || 'dark';
10+
storedTheme || 'light';
1111
document.documentElement.dataset.theme = theme === 'light' ? 'light' : 'dark';
1212
localStorage.setItem('starlight-theme', theme);
1313

src/components/home/BuildForms.astro

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ import SmoothButton from "./SmoothButton.astro";
1919
<span>并且可以在流水线无缝集成</span>
2020

2121
<div class="mt-[2vw] text-[1vw]">
22-
<SmoothButton href="https://registry.serverless-devs.com/">查看更多</SmoothButton>
22+
<SmoothButton href="https://registry.serverless-devs.com/application.html">查看更多</SmoothButton>
2323
</div>
2424
</div>
2525

@@ -39,7 +39,7 @@ import SmoothButton from "./SmoothButton.astro";
3939
<span>都是精心打磨的云资源管理利器</span>
4040

4141
<div class="mt-[2vw] text-[1vw]">
42-
<SmoothButton href="https://registry.serverless-devs.com/">查看更多</SmoothButton>
42+
<SmoothButton href="https://registry.serverless-devs.com/component.html">查看更多</SmoothButton>
4343
</div>
4444
</div>
4545
</div>
@@ -54,7 +54,7 @@ import SmoothButton from "./SmoothButton.astro";
5454
<span>实现服务的热启动</span>
5555

5656
<div class="mt-[2vw] text-[1vw]">
57-
<SmoothButton href="https://registry.serverless-devs.com/">查看更多</SmoothButton>
57+
<SmoothButton href="https://registry.serverless-devs.com/plugin.html">查看更多</SmoothButton>
5858
</div>
5959
</div>
6060

src/components/home/Hero.astro

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,26 @@ import SmoothButton from "./SmoothButton.astro";
1111
<div class="hero-background"></div>
1212

1313
<!-- 热门模板 -->
14-
<a href="https://registry.serverless-devs.com/"
15-
class="hidden md:flex bg-white bg-opacity-20 opacity-80 border-[#9295a5] border-[0.8px] px-3 py-2 w-fit rounded-3xl text-center flex-row items-center gap-3 z-10">
14+
<div
15+
class="hidden md:flex bg-white bg-opacity-20 opacity-80 border-[#9295a5] border-[0.8px] px-3 py-2 w-fit rounded-3xl text-center flex-row items-center gap-3 z-10 ">
1616
<div class="text-center text-white rounded-3xl text-xs px-5 py-2"
1717
style="background:linear-gradient(134.09deg, rgba(38, 44, 244, 1) 0%, rgba(113, 64, 255, 1) 100%)">
1818
HOT !
1919
</div>
20-
<p class="text-white text-xs">stable-diffusion,comfyui,cosyvoice,ollama 等应用模版上架</p>
21-
<Picture
20+
<p class="text-white text-xs mr-2">
21+
<a href="https://registry.serverless-devs.com/details.html?name=fc-stable-diffusion-v3&package_type=v3" target="_blank" class="hover:text-[#ee6590]">Stable-Diffusion</a>,
22+
<a href="https://registry.serverless-devs.com/details.html?name=fc-comfyui&package_type=v3" target="_blank" class="hover:text-[#ee6590]">ComfyUI</a>,
23+
<a href="https://registry.serverless-devs.com/details.html?name=cosyvoice&package_type=v3" target="_blank" class="hover:text-[#ee6590]">CosyVoice</a>,
24+
<a href="https://registry.serverless-devs.com/details.html?name=ollama&package_type=v3" target="_blank" class="hover:text-[#ee6590]">Ollama</a>,
25+
<a href="https://registry.serverless-devs.com/details.html?name=fc-gpt-sovits&package_type=v3" target="_blank" class="hover:text-[#ee6590]">GPT-SoVITS</a>
26+
等应用模版上架</p>
27+
<!-- <Picture
2228
src={nextIcon}
2329
alt="nextIcon"
2430
loading="eager"
2531
format="avif"
26-
/>
27-
</a>
32+
/> -->
33+
</div>
2834

2935
<!-- 大标题 -->
3036
<h1

0 commit comments

Comments
 (0)