Skip to content

Commit 5ad7b25

Browse files
Frontend polish
1 parent 771a2f5 commit 5ad7b25

File tree

3 files changed

+66
-44
lines changed

3 files changed

+66
-44
lines changed

apps/web/app/FeaturesSection.tsx

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,12 @@ export const FeaturesSection = () => {
55
{"Features 👑"}
66
</h2>
77

8-
<ul className="list-disk list-inside space-y-2">
9-
<li>{"Easy to use primitive for building your own components."}</li>
10-
<li>{"Available for React, (other libraries coming soon)"}</li>
8+
<ul className="list-none list-inside space-y-2">
9+
<li>{"💃 Easy to use primitive for building your own components."}</li>
10+
<li>{"🚀 Available for React, (other libraries coming soon)"}</li>
11+
<li>{"😏 React 18 support (server components)"}</li>
1112
<li>
12-
{"Fallback for no JavaScript (try disabling JS for this page)"}
13+
{"🙏 Fallback for no JavaScript (try disabling JS for this page)"}
1314
<noscript>
1415
<br />
1516
<div className="ml-[22px] pt-2">
@@ -18,8 +19,8 @@ export const FeaturesSection = () => {
1819
</div>
1920
</noscript>
2021
</li>
21-
<li>{"React 18 support (server components)"}</li>
22-
<li>{"CommonJS and ES6"}</li>
22+
<li>{"🐁 Just 2.1kB gzipped."}</li>
23+
<li>{"👌 CommonJS and ES6"}</li>
2324
</ul>
2425
</div>
2526
);

apps/web/app/SquircleDemoSection.tsx

Lines changed: 48 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,26 @@ export const SquircleDemoSection = () => {
1212
return (
1313
<div className="container mx-auto max-w-[960px] md:pt-24 mb-36">
1414
<h1 className="font-bold text-4xl leading-[180%] sm:text-5xl sm:leading-[150%] md:text-6xl text-center md:mx-auto mb-6 md:leading-[130%]">
15-
Squircle{" "}
15+
<span className="text-6xl sm:text-inherit leading-[200%]">
16+
Squircle
17+
</span>{" "}
1618
<Squircle
1719
as="span"
18-
className="bg-black text-white pl-8 pr-8 pt-2 pb-2"
20+
className="bg-black text-white pl-8 pr-8 pt-2 pb-2 text-6xl sm:text-inherit"
1921
cornerRadius={cornerRadius}
2022
cornerSmoothing={cornerSmoothing}
2123
>
2224
Element
2325
</Squircle>
2426
<br />
25-
for your Frontend
27+
for{" "}
28+
<span className="relative before:absolute before:-inset-x-1 before:h-1 before:-bottom-1 before:-rotate-2 before:bg-black before:-z-10">
29+
your
30+
</span>{" "}
31+
Frontend
2632
</h1>
2733

28-
<div className="text-center text-lg mb-10">
34+
<div className="text-center text-lg mb-6">
2935
Use{" "}
3036
<Squircle
3137
as="code"
@@ -41,42 +47,46 @@ export const SquircleDemoSection = () => {
4147
other frontend frameworks soon!
4248
</div>
4349

44-
<div className="flex flex-col gap-4 w-full mb-8 mx-auto max-w-[360px]">
45-
<h2 className="font-bold text-2xl mx-auto">Try it out! 🙌</h2>
46-
<p className="text-center">
47-
{`Use sliders to control the "Element" component above. After, don't forget to star the repo 😉`}
48-
</p>
50+
<div className="space-y-12 mb-8 mx-auto max-w-[360px]">
51+
<div className="space-y-4">
52+
<Label
53+
htmlFor="corner-radius"
54+
className="mt-4"
55+
>{`Corner Radius (${cornerRadius}px)`}</Label>
56+
<Slider
57+
id="corner-radius"
58+
min={0}
59+
max={50}
60+
value={[cornerRadius]}
61+
onValueChange={(v) => setCornerRadius(v.at(0))}
62+
/>
4963

50-
<Label
51-
htmlFor="corner-radius"
52-
className="mt-4"
53-
>{`Corner Radius (${cornerRadius}px)`}</Label>
54-
<Slider
55-
id="corner-radius"
56-
min={0}
57-
max={50}
58-
value={[cornerRadius]}
59-
onValueChange={(v) => setCornerRadius(v.at(0))}
60-
/>
64+
<Label htmlFor="corner-smoothing">
65+
{`Corner Smoothing (${cornerSmoothing}) `}
66+
{cornerSmoothing === 0
67+
? "- Just like regular old button"
68+
: cornerSmoothing === 1
69+
? "- Silky smooth!"
70+
: cornerSmoothing === 0.6
71+
? "- like iOS icons"
72+
: ""}
73+
</Label>
74+
<Slider
75+
id="corner-smoothing"
76+
min={0}
77+
max={1}
78+
step={0.01}
79+
value={[cornerSmoothing]}
80+
onValueChange={(v) => setCornerSmoothing(v.at(0))}
81+
/>
82+
</div>
6183

62-
<Label htmlFor="corner-smoothing">
63-
{`Corner Smoothing (${cornerSmoothing}) `}
64-
{cornerSmoothing === 0
65-
? "- Just like regular old button"
66-
: cornerSmoothing === 1
67-
? "- Silky smooth!"
68-
: cornerSmoothing === 0.6
69-
? "- like iOS icons"
70-
: ""}
71-
</Label>
72-
<Slider
73-
id="corner-smoothing"
74-
min={0}
75-
max={1}
76-
step={0.01}
77-
value={[cornerSmoothing]}
78-
onValueChange={(v) => setCornerSmoothing(v.at(0))}
79-
/>
84+
<div className="space-y-2">
85+
<h2 className="font-bold text-2xl mx-auto w-fit">Try it out! 🙌</h2>
86+
<p className="text-center">
87+
{`Use sliders to control the "Element" component above. The difference is not huge, but makes a difference! 😉`}
88+
</p>
89+
</div>
8090
</div>
8191
</div>
8292
);

apps/web/app/icon.svg

Lines changed: 11 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)