Skip to content

Commit 8239a40

Browse files
authored
Merge branch 'main' into main
2 parents 159d8db + e437932 commit 8239a40

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+917
-360
lines changed

src/components/Community.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,7 @@ export const Community = () => {
8686

8787
<div className="flex-auto">
8888
<h3 className="font-bold">Substack</h3>
89-
<p className="text-sm text-gray-700">
90-
Ideas worth reading — delivered directly to you.
91-
</p>
89+
<p>Ideas worth reading — delivered directly to you.</p>
9290
</div>
9391
</a>
9492
</li>
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
import React from "react";
2+
import Link from "@docusaurus/Link";
3+
4+
export default function EnterpriseInstallReminder() {
5+
return (
6+
<div
7+
style={{
8+
padding: "1rem",
9+
border: "1px solid #eee",
10+
borderRadius: "10px",
11+
background: "#fff8f5",
12+
margin: "2rem 0",
13+
}}
14+
>
15+
<h3>Don’t have Keploy installed yet?</h3>
16+
<p>
17+
Before running this sample, make sure Keploy Enterprise version is
18+
installed on your system.
19+
</p>
20+
<Link
21+
to="/docs/keploy-cloud/cloud-installation/"
22+
style={{
23+
display: "inline-block",
24+
marginTop: "0.5rem",
25+
padding: "0.6rem 1rem",
26+
background: "#e67e22",
27+
color: "#fff",
28+
borderRadius: "6px",
29+
fontWeight: "bold",
30+
textDecoration: "none",
31+
}}
32+
>
33+
👉 Go to Installation Guide
34+
</Link>
35+
</div>
36+
);
37+
}

src/components/QuickStartFilter.js

Lines changed: 151 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import {TbBrandCSharp} from "react-icons/tb";
99
import {FaPython} from "react-icons/fa";
1010
import {FaDocker} from "react-icons/fa";
1111
import {IoLogoJavascript} from "react-icons/io5";
12+
import {useColorMode} from "@docusaurus/theme-common";
1213

1314
// 🔹 Wrapper for icons to make them uniform
1415
const IconWrapper = ({icon, bg}) => (
@@ -20,7 +21,7 @@ const IconWrapper = ({icon, bg}) => (
2021
alignItems: "center",
2122
justifyContent: "center",
2223
borderRadius: "50%",
23-
backgroundColor: bg || "#f3f4f6",
24+
backgroundColor: bg,
2425
boxShadow: "0 3px 6px rgba(0,0,0,0.1)",
2526
transition: "transform 0.2s ease",
2627
}}
@@ -31,6 +32,9 @@ const IconWrapper = ({icon, bg}) => (
3132
);
3233

3334
export default function QuickstartFilter({defaultLanguage = null}) {
35+
const {colorMode} = useColorMode();
36+
const isDark = colorMode === "dark";
37+
3438
// 👇 initialize with defaultLanguage if provided
3539
const [language, setLanguage] = useState(defaultLanguage);
3640
const [server, setServer] = useState(null);
@@ -42,6 +46,18 @@ export default function QuickstartFilter({defaultLanguage = null}) {
4246
);
4347
});
4448

49+
// Icon backgrounds for dark mode
50+
const darkIconBgs = {
51+
Go: "#223044",
52+
Python: "#243447",
53+
Java: "#392a2a",
54+
"JS/TS": "#3b3924",
55+
Rust: "#44392b",
56+
"C#": "#332e44",
57+
Local: "#44392b",
58+
Docker: "#233044",
59+
};
60+
4561
const languages = [
4662
{
4763
name: "Go",
@@ -63,11 +79,13 @@ export default function QuickstartFilter({defaultLanguage = null}) {
6379
icon: <IoLogoJavascript size={36} color="#F7DF1E" />,
6480
bg: "#FFF8E1",
6581
},
66-
{
82+
83+
/*{
6784
name: "Rust",
6885
icon: <FaRust size={36} color="#DEA584" />,
6986
bg: "#FFF3E0",
7087
},
88+
*/
7189
{
7290
name: "C#",
7391
icon: <TbBrandCSharp size={36} color="#512BD4" />,
@@ -88,6 +106,79 @@ export default function QuickstartFilter({defaultLanguage = null}) {
88106
},
89107
];
90108

109+
// ----- Styles -----
110+
const headingStyle = {
111+
textAlign: "left",
112+
marginLeft: "1rem",
113+
fontSize: "1.4rem",
114+
fontWeight: "600",
115+
color: isDark ? "#fff" : "#222",
116+
};
117+
118+
const serverContainer = {
119+
display: "flex",
120+
flexWrap: "wrap",
121+
gap: "1.5rem",
122+
justifyContent: "flex-start",
123+
marginTop: "1.5rem",
124+
marginLeft: "1rem",
125+
};
126+
127+
const stepContainer = {
128+
display: "flex",
129+
flexWrap: "wrap",
130+
gap: "1.5rem",
131+
marginLeft: "1rem",
132+
justifyContent: "flex-start",
133+
marginTop: "1.5rem",
134+
};
135+
136+
const buttonCard = {
137+
border: isDark ? "2px solid #333" : "2px solid #ddd",
138+
borderRadius: "12px",
139+
padding: "1rem 2rem",
140+
cursor: "pointer",
141+
background: isDark ? "#222428" : "#fff",
142+
transition: "all 0.2s ease",
143+
textAlign: "center",
144+
display: "flex",
145+
flexDirection: "column",
146+
alignItems: "center",
147+
justifyContent: "center",
148+
gap: "0.5rem",
149+
color: isDark ? "#fff" : "#222",
150+
boxShadow: isDark
151+
? "0 2px 10px rgba(0,0,0,0.5)"
152+
: "0 2px 6px rgba(0, 0, 0, 0.08)",
153+
};
154+
155+
const gridContainer = {
156+
display: "grid",
157+
gap: "1.5rem",
158+
gridTemplateColumns: "repeat(auto-fit, minmax(250px, 1fr))",
159+
marginTop: "2rem",
160+
};
161+
162+
const cardStyle = {
163+
border: isDark ? "1px solid #333" : "1px solid #eee",
164+
borderRadius: "12px",
165+
padding: "1rem",
166+
background: isDark ? "#23272f" : "#fff",
167+
boxShadow: isDark
168+
? "0 2px 10px rgba(0,0,0,0.6)"
169+
: "0 2px 6px rgba(0, 0, 0, 0.08)",
170+
color: isDark ? "#fff" : "#222",
171+
};
172+
173+
const linkStyle = {
174+
marginTop: "0.8rem",
175+
display: "inline-block",
176+
color: "#f97316",
177+
fontWeight: "bold",
178+
textDecoration: "none",
179+
};
180+
181+
// ----- Render -----
91182
return (
92183
<div style={{marginTop: "2rem"}}>
93184
{/* Language Selection */}
@@ -100,15 +191,32 @@ export default function QuickstartFilter({defaultLanguage = null}) {
100191
style={{
101192
...buttonCard,
102193
border:
103-
language === lang.name ? "2px solid #f97316" : "2px solid #ddd",
194+
language === lang.name
195+
? "2px solid #f97316"
196+
: buttonCard.border,
104197
boxShadow:
105198
language === lang.name
106-
? "0 3px 8px rgba(249, 115, 22, 0.3)"
107-
: "none",
199+
? isDark
200+
? "0 3px 12px rgba(249,115,22,0.2)"
201+
: "0 3px 8px rgba(249, 115, 22, 0.3)"
202+
: buttonCard.boxShadow,
108203
}}
109204
>
110-
<IconWrapper icon={lang.icon} bg={lang.bg} />
111-
<p style={{marginTop: "0.5rem", fontWeight: "500"}}>{lang.name}</p>
205+
<IconWrapper
206+
icon={lang.icon}
207+
bg={isDark ? darkIconBgs[lang.name] || "#222" : lang.bg}
208+
/>
209+
<p
210+
style={{
211+
margin: 0,
212+
fontWeight: "500",
213+
color: isDark ? "#fff" : "#222",
214+
opacity: language === lang.name ? 1 : 0.7,
215+
transition: "color 0.2s, opacity 0.2s",
216+
}}
217+
>
218+
{lang.name}
219+
</p>
112220
</button>
113221
))}
114222
</div>
@@ -125,15 +233,30 @@ export default function QuickstartFilter({defaultLanguage = null}) {
125233
style={{
126234
...buttonCard,
127235
border:
128-
server === srv.name ? "2px solid #f97316" : "2px solid #ddd",
236+
server === srv.name ? "2px solid #f97316" : buttonCard.border,
129237
boxShadow:
130238
server === srv.name
131-
? "0 3px 8px rgba(249, 115, 22, 0.3)"
132-
: "none",
239+
? isDark
240+
? "0 3px 12px rgba(249,115,22,0.2)"
241+
: "0 3px 8px rgba(249, 115, 22, 0.3)"
242+
: buttonCard.boxShadow,
133243
}}
134244
>
135-
<IconWrapper icon={srv.icon} bg={srv.bg} />
136-
<p style={{marginTop: "0.5rem", fontWeight: "500"}}>{srv.name}</p>
245+
<IconWrapper
246+
icon={srv.icon}
247+
bg={isDark ? darkIconBgs[srv.name] || "#222" : srv.bg}
248+
/>
249+
<p
250+
style={{
251+
margin: 0,
252+
fontWeight: "500",
253+
color: isDark ? "#fff" : "#222",
254+
opacity: server === srv.name ? 1 : 0.7,
255+
transition: "color 0.2s, opacity 0.2s",
256+
}}
257+
>
258+
{srv.name}
259+
</p>
137260
</button>
138261
))}
139262
</div>
@@ -148,10 +271,21 @@ export default function QuickstartFilter({defaultLanguage = null}) {
148271
{filteredQuickstarts.length > 0 ? (
149272
filteredQuickstarts.map((app, idx) => (
150273
<div key={idx} style={cardStyle}>
151-
<h3 style={{margin: "0 0 0.5rem 0", fontSize: "1.2rem"}}>
274+
<h3
275+
style={{
276+
margin: "0 0 0.5rem 0",
277+
fontSize: "1.2rem",
278+
color: isDark ? "#fff" : "#222",
279+
}}
280+
>
152281
{app.title}
153282
</h3>
154-
<p style={{color: "#555", fontSize: "0.95rem"}}>
283+
<p
284+
style={{
285+
color: isDark ? "#ccc" : "#555",
286+
fontSize: "0.95rem",
287+
}}
288+
>
155289
{app.description}
156290
</p>
157291
<Link to={app.link} style={linkStyle}>
@@ -160,70 +294,13 @@ export default function QuickstartFilter({defaultLanguage = null}) {
160294
</div>
161295
))
162296
) : (
163-
<p>No quickstarts available for this selection.</p>
297+
<p style={{color: isDark ? "#fff" : "#222"}}>
298+
No quickstarts available for this selection.
299+
</p>
164300
)}
165301
</div>
166302
</>
167303
)}
168304
</div>
169305
);
170306
}
171-
172-
// Styles
173-
const headingStyle = {
174-
textAlign: "left",
175-
marginLeft: "1rem",
176-
fontSize: "1.4rem",
177-
fontWeight: "600",
178-
};
179-
180-
const serverContainer = {
181-
display: "flex",
182-
flexWrap: "wrap",
183-
gap: "1.5rem",
184-
justifyContent: "flex-start",
185-
marginTop: "1.5rem",
186-
marginLeft: "1rem",
187-
};
188-
189-
const stepContainer = {
190-
display: "flex",
191-
flexWrap: "wrap",
192-
gap: "1.5rem",
193-
marginLeft: "1rem",
194-
justifyContent: "flex-start",
195-
marginTop: "1.5rem",
196-
};
197-
198-
const buttonCard = {
199-
border: "2px solid #ddd",
200-
borderRadius: "12px",
201-
padding: "1rem 2rem",
202-
cursor: "pointer",
203-
background: "#fff",
204-
transition: "all 0.2s ease",
205-
textAlign: "center",
206-
};
207-
208-
const gridContainer = {
209-
display: "grid",
210-
gap: "1.5rem",
211-
gridTemplateColumns: "repeat(auto-fit, minmax(250px, 1fr))",
212-
marginTop: "2rem",
213-
};
214-
215-
const cardStyle = {
216-
border: "1px solid #eee",
217-
borderRadius: "12px",
218-
padding: "1rem",
219-
background: "#fff",
220-
boxShadow: "0 2px 6px rgba(0, 0, 0, 0.08)",
221-
};
222-
223-
const linkStyle = {
224-
marginTop: "0.8rem",
225-
display: "inline-block",
226-
color: "#f97316",
227-
fontWeight: "bold",
228-
textDecoration: "none",
229-
};

0 commit comments

Comments
 (0)