Skip to main content

website-react-components

TSX component conventions for the Scala CLI Docusaurus website.

소스 정보

저장소
VirtusLab/scala-cli
최근 소스 활동
2026년 10월 1일 13:06
감지된 SKILL.md 언어
영어
스타
643
포크
169

설치 방법

기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.

소스 파일 검토

설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.

SKILL.md 표시 중

SKILL.md
소스 지침 · 읽기 전용 미리보기
name
website-react-components
description
TSX component conventions for the Scala CLI Docusaurus website.
# React components (website) ## Conventions - Files: PascalCase `.tsx` (helpers `.ts`) - Typed props (`type` / `interface`); `ReactNode` for children - Style with Tailwind + `cn()` from `@site/src/lib/utils` or relative `../lib/utils` - Inline Tailwind in JSX — do not export static layout `*ClassName` constants - Keep components small; extract helpers to `*.ts` when logic grows ## MDX-facing helpers `MarkdownComponents.tsx` (`ChainedSnippets`, `GiflikeVideo`) and `DownloadButton.tsx` are imported from docs. Prefer extensionless imports from MDX. Keep `.runnable-command` styles in `tokens.css`. ## Theme / swizzles `src/theme/Root.tsx` — GTM / document shell only unless swizzling more chrome. Local / swizzled chrome (do not revert to stock Infima look): | Path | Role | |------|------| | `Navbar/Content` | Brand, search, GitHub, theme switch, mobile toggle | | `Navbar/Logo` | Wordmark brand link | | `NavbarItem/DropdownNavbarItem/Desktop` | Custom chevron dropdown | | `Footer` | Product footer + external icons on `href` | | `DocBreadcrumbs` (+ `Items/Home`) | Soft chips, clickable parents, House icon | | `PaginatorNavLink` | Lucide chevrons instead of `«`/`»` | Also under `src/components/`: `ThemeSwitch`, `NavbarDevTools`, `ScalaCliWordmark`, `HomeNavbarEffect`, sticky navs. Product layout: [home-layout](../website-home-layout/SKILL.md). Docs: [docs-chrome](../website-docs-chrome/SKILL.md). Mobile: [responsive](../website-responsive/SKILL.md). New files under `src/theme/**` often need a **yarn start restart**. ## Icons Prefer **lucide-react** for product UI (benefits, use cases, chrome). Pass `LucideIcon` into `IconBox`; map use-case slugs in `UseCaseTile`. Do not reintroduce PNG icons for those cards.
GitHub에서 보기