|
1
|
import clsx from "clsx" |
|
2
|
import { HeadlineTags, ShadedBlock } from "docs-ui" |
|
3
|
import Link from "next/link" |
|
4
|
import { LinksSectionBloomIcon } from "./Icon" |
|
5
|
|
|
6
|
const HomepageLinksSection = () => { |
|
7
|
const links: { |
|
8
|
tag: string |
|
9
|
links: { |
|
10
|
text: string |
|
11
|
link: string |
|
12
|
}[] |
|
13
|
}[] = [ |
|
14
|
{ |
|
15
|
tag: "Customize Medusa Application", |
|
16
|
links: [ |
|
17
|
{ |
|
18
|
link: "/learn/installation", |
|
19
|
text: "Install Medusa", |
|
20
|
}, |
|
21
|
{ |
|
22
|
link: "https://docs.medusajs.com/cloud/sign-up", |
|
23
|
text: "Deploy to Cloud", |
|
24
|
}, |
|
25
|
{ |
|
26
|
link: "https://docs.medusajs.com/resources/integrations", |
|
27
|
text: "Browse integrations", |
|
28
|
}, |
|
29
|
], |
|
30
|
}, |
|
31
|
{ |
|
32
|
tag: "Admin Development", |
|
33
|
links: [ |
|
34
|
{ |
|
35
|
link: "/learn/fundamentals/admin/widgets", |
|
36
|
text: "Build a UI widget", |
|
37
|
}, |
|
38
|
{ |
|
39
|
link: "/learn/fundamentals/admin/ui-routes", |
|
40
|
text: "Add a UI route", |
|
41
|
}, |
|
42
|
{ |
|
43
|
link: "https://docs.medusajs.com/ui", |
|
44
|
text: "Browse the UI library", |
|
45
|
}, |
|
46
|
], |
|
47
|
}, |
|
48
|
{ |
|
49
|
tag: "Storefront Development", |
|
50
|
links: [ |
|
51
|
{ |
|
52
|
link: "https://docs.medusajs.com/resources/nextjs-starter", |
|
53
|
text: "Explore storefront starter", |
|
54
|
}, |
|
55
|
{ |
|
56
|
link: "https://docs.medusajs.com/resources/storefront-development", |
|
57
|
text: "Build custom storefront", |
|
58
|
}, |
|
59
|
{ |
|
60
|
link: "https://docs.medusajs.com/learn/introduction/build-with-llms-ai#ecommerce-storefront-best-practices", |
|
61
|
text: "Use agent skills", |
|
62
|
}, |
|
63
|
], |
|
64
|
}, |
|
65
|
{ |
|
66
|
tag: "Medusa Cloud", |
|
67
|
links: [ |
|
68
|
{ |
|
69
|
link: "https://docs.medusajs.com/cloud/projects", |
|
70
|
text: "Deploy from GitHub", |
|
71
|
}, |
|
72
|
{ |
|
73
|
link: "https://docs.medusajs.com/cloud/environments/preview", |
|
74
|
text: "Preview environments", |
|
75
|
}, |
|
76
|
{ |
|
77
|
link: "https://docs.medusajs.com/cloud/emails", |
|
78
|
text: "Medusa Emails", |
|
79
|
}, |
|
80
|
], |
|
81
|
}, |
|
82
|
{ |
|
83
|
tag: "Agentic Development", |
|
84
|
links: [ |
|
85
|
{ |
|
86
|
link: "https://docs.medusajs.com/learn/introduction/build-with-llms-ai/cloud-cli", |
|
87
|
text: "Agentic Deployments", |
|
88
|
}, |
|
89
|
{ |
|
90
|
link: "https://docs.medusajs.com/learn/introduction/build-with-llms-ai", |
|
91
|
text: "Agent Skills", |
|
92
|
}, |
|
93
|
{ |
|
94
|
link: "https://docs.medusajs.com/learn/introduction/build-with-llms-ai/docs-mcp-server", |
|
95
|
text: "Docs MCP", |
|
96
|
}, |
|
97
|
], |
|
98
|
}, |
|
99
|
] |
|
100
|
|
|
101
|
return ( |
|
102
|
<div className="w-full flex gap-0 flex-col md:flex-row flex-wrap border-b border-medusa-border-base"> |
|
103
|
{links.map((section, index) => ( |
|
104
|
<div |
|
105
|
key={index} |
|
106
|
className={clsx( |
|
107
|
"p-2 flex justify-between flex-col w-full md:w-1/3 gap-2 md:min-h-[320px]", |
|
108
|
"border-b border-medusa-border-base md:border-b-0", |
|
109
|
index !== 2 && "md:border-r", |
|
110
|
index > 2 && "md:border-t" |
|
111
|
)} |
|
112
|
> |
|
113
|
<HeadlineTags tags={[section.tag]} className="!justify-start" /> |
|
114
|
<div className="flex flex-col gap-0.75"> |
|
115
|
{section.links.map((link, linkIndex) => ( |
|
116
|
<div className="flex gap-0.75" key={linkIndex}> |
|
117
|
<ShadedBlock className="!w-2 min-h-2" /> |
|
118
|
<Link |
|
119
|
href={link.link} |
|
120
|
className={clsx( |
|
121
|
"flex-1 text-medusa-fg-base text-h2 hover:underline hover:text-medusa-fg-interactive" |
|
122
|
)} |
|
123
|
> |
|
124
|
{link.text} |
|
125
|
</Link> |
|
126
|
</div> |
|
127
|
))} |
|
128
|
</div> |
|
129
|
</div> |
|
130
|
))} |
|
131
|
<div |
|
132
|
className={clsx( |
|
133
|
"p-2 flex justify-center items-center w-full md:w-1/3 gap-2 md:min-h-[320px]", |
|
134
|
"border-medusa-border-base md:border-t bg-medusa-bg-component" |
|
135
|
)} |
|
136
|
> |
|
137
|
<LinksSectionBloomIcon /> |
|
138
|
</div> |
|
139
|
</div> |
|
140
|
) |
|
141
|
} |
|
142
|
|
|
143
|
export default HomepageLinksSection |