Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
106 changes: 106 additions & 0 deletions src/app/preview/tech-stack/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
import { backend, design, frontend } from '@/components/ui/Icon/iconRegistry';
import React from 'react';

export default function TechStackPage() {
return (
<div className="mx-auto max-w-4xl space-y-12 p-8">
{/* Frontend Section */}
<section>
<h2 className="mb-6 text-2xl font-bold">Frontend Technologies</h2>

{/* Core */}
<div className="mb-8 flex flex-col gap-8">
<h3 className="text-lg font-semibold">Core</h3>
<div className="flex flex-wrap gap-4">
<frontend.JavascriptIcon size={24} radius="lg" />
<frontend.TypescriptIcon size={24} radius="lg" />
<frontend.ReactIcon size={24} radius="lg" />
<frontend.VueIcon size={24} radius="lg" />
</div>
<div className="flex flex-wrap gap-4">
<frontend.JavascriptIcon size={12} radius="lg" />
<frontend.TypescriptIcon size={12} radius="lg" />
<frontend.ReactIcon size={12} radius="lg" />
<frontend.VueIcon size={12} radius="lg" />
</div>
Comment on lines +14 to +25
Copy link

@coderabbitai coderabbitai bot Feb 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๐Ÿ› ๏ธ Refactor suggestion

์•„์ด์ฝ˜ ํฌ๊ธฐ ์ค‘๋ณต ์ฝ”๋“œ๋ฅผ ์ œ๊ฑฐํ•ด์ฃผ์„ธ์š”.

๋™์ผํ•œ ์•„์ด์ฝ˜์ด ๋‹ค๋ฅธ ํฌ๊ธฐ๋กœ ๋ฐ˜๋ณต๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. ์ปดํฌ๋„ŒํŠธ๋กœ ๋ถ„๋ฆฌํ•˜์—ฌ ์žฌ์‚ฌ์šฉ์„ฑ์„ ๋†’์ผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

+const TechIcon = ({ icon: Icon, size = 24 }) => (
+  <Icon size={size} radius="lg" />
+);
+
 <div className="flex flex-wrap gap-4">
-  <frontend.JavascriptIcon size={24} radius="lg" />
-  <frontend.TypescriptIcon size={24} radius="lg" />
-  <frontend.ReactIcon size={24} radius="lg" />
-  <frontend.VueIcon size={24} radius="lg" />
+  <TechIcon icon={frontend.JavascriptIcon} />
+  <TechIcon icon={frontend.TypescriptIcon} />
+  <TechIcon icon={frontend.ReactIcon} />
+  <TechIcon icon={frontend.VueIcon} />
 </div>
๐Ÿ“ Committable suggestion

โ€ผ๏ธ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<div className="flex flex-wrap gap-4">
<frontend.JavascriptIcon size={24} radius="lg" />
<frontend.TypescriptIcon size={24} radius="lg" />
<frontend.ReactIcon size={24} radius="lg" />
<frontend.VueIcon size={24} radius="lg" />
</div>
<div className="flex flex-wrap gap-4">
<frontend.JavascriptIcon size={12} radius="lg" />
<frontend.TypescriptIcon size={12} radius="lg" />
<frontend.ReactIcon size={12} radius="lg" />
<frontend.VueIcon size={12} radius="lg" />
</div>
const TechIcon = ({ icon: Icon, size = 24 }) => (
<Icon size={size} radius="lg" />
);
<div className="flex flex-wrap gap-4">
<TechIcon icon={frontend.JavascriptIcon} />
<TechIcon icon={frontend.TypescriptIcon} />
<TechIcon icon={frontend.ReactIcon} />
<TechIcon icon={frontend.VueIcon} />
</div>
<div className="flex flex-wrap gap-4">
<frontend.JavascriptIcon size={12} radius="lg" />
<frontend.TypescriptIcon size={12} radius="lg" />
<frontend.ReactIcon size={12} radius="lg" />
<frontend.VueIcon size={12} radius="lg" />
</div>

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

์˜ˆ์‹œ ํŽ˜์ด์ง€๊ธฐ๋•Œ๋ฌธ์— ๋ฌด์‹œํ•ด์ค˜

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@clyde-yoonjae ์•Œ๊ฒ ์Šต๋‹ˆ๋‹ค. ์˜ˆ์‹œ ํŽ˜์ด์ง€์— ๋Œ€ํ•œ ๋ฆฌ๋ทฐ ์˜๊ฒฌ์„ ์ฒ ํšŒํ•˜๊ฒ ์Šต๋‹ˆ๋‹ค.


โœ๏ธ Learnings added
Learnt from: clyde-yoonjae
PR: MoimService/Moim-FE#22
File: src/app/preview/tech-stack/page.tsx:14-25
Timestamp: 2025-02-21T05:01:06.124Z
Learning: Code in preview/example pages (e.g., paths containing "preview") can have relaxed code quality standards as they serve demonstration purposes rather than production code.

Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.

</div>

{/* Framework & Libraries */}
<div className="mb-8">
<h3 className="mb-4 text-lg font-semibold">Framework & Libraries</h3>
<div className="flex flex-wrap gap-4">
<frontend.NextIcon size={24} radius="lg" />
<frontend.SvelteIcon size={24} radius="lg" />
</div>
</div>

{/* Mobile & Others */}
<div>
<h3 className="mb-4 text-lg font-semibold">Mobile & Others</h3>
<div className="flex flex-wrap gap-4">
<frontend.ReactNativeIcon size={24} radius="lg" />
<frontend.FlutterIcon size={24} radius="lg" />
<frontend.SwiftIcon size={24} radius="lg" />
<frontend.KotlinIcon size={24} radius="lg" />
<frontend.UnityIcon size={24} radius="lg" className="bg-black" />
<frontend.JestIcon size={24} radius="lg" />
</div>
</div>
</section>

{/* Backend Section */}
<section>
<h2 className="mb-6 text-2xl font-bold">Backend Technologies</h2>

{/* Language & Runtime */}
<div className="mb-8">
<h3 className="mb-4 text-lg font-semibold">Language & Runtime</h3>
<div className="flex flex-wrap gap-4">
<backend.JavaIcon size={24} radius="lg" />
<backend.NodeIcon size={24} radius="lg" />
<backend.PythonIcon size={24} radius="lg" />
<backend.GoIcon size={24} radius="lg" />
<backend.CIcon size={24} radius="lg" />
</div>
</div>

{/* Framework */}
<div className="mb-8">
<h3 className="mb-4 text-lg font-semibold">Framework</h3>
<div className="flex flex-wrap gap-4">
<backend.SpringIcon size={24} radius="lg" />
<backend.NestIcon size={24} radius="lg" />
<backend.ExpressIcon size={24} radius="lg" />
<backend.DjangoIcon size={24} radius="lg" />
</div>
</div>

{/* Database & Infrastructure */}
<div>
<h3 className="mb-4 text-lg font-semibold">
Database & Infrastructure
</h3>
<div className="flex flex-wrap gap-4">
<backend.MySQLIcon size={24} radius="lg" />
<backend.MongoDBIcon size={24} radius="lg" />
<backend.FirebaseIcon size={24} radius="lg" />
<backend.AWSIcon size={24} radius="lg" />
<backend.DockerIcon size={24} radius="lg" />
<backend.KubernetesIcon size={24} radius="lg" />
<backend.GitIcon size={24} radius="lg" />
</div>
</div>
</section>

{/* Design Tools */}
<section>
<h2 className="mb-6 text-2xl font-bold">Design Tools</h2>
<div className="flex flex-wrap items-center gap-4">
<design.FigmaIcon size={24} radius="lg" />
<design.ZeplinIcon size={24} radius="lg" />
<design.SketchIcon size={24} radius="lg" />
</div>
</section>
</div>
);
}
46 changes: 46 additions & 0 deletions src/components/ui/Icon/BaseIcon.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
import { cn } from '@/util/cn';

export interface BaseIconProps {
color?: string;
size?: number;
radius?: 'none' | 'sm' | 'md' | 'lg' | 'full';
className?: string;
path: string;
ariaLabel?: string;
title?: string;
}

export function BaseIcon({
color,
size = 24,
radius = 'none',
className,
path,
ariaLabel,
title,
}: BaseIconProps) {
const radiusMap = {
none: 'rounded-none',
sm: 'rounded-sm',
md: 'rounded',
lg: 'rounded-lg',
full: 'rounded-full',
};

return (
<svg
role="img"
width={size}
height={size}
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
fill={color}
className={cn(radiusMap[radius], className)}
aria-label={ariaLabel}
preserveAspectRatio="xMidYMid meet"
>
{title && <title>{title}</title>}
<path d={path} />
</svg>
);
}
Loading
Loading