Files
Anthony ShewandGitHub c4be53cc57 chore: Move applications to apps/ directory (#11613)
## Summary

- Moves `docs/site` to `apps/docs`
- Moves `packages/coverage-reporter` to `apps/coverage-reporter`

These are applications (Next.js sites), not packages meant to be
consumed by other packages. Moving them to `apps/` follows monorepo
conventions and makes the distinction clear.

## Changes

- Created `apps/` directory
- Updated `pnpm-workspace.yaml` to include `apps/*`
- Updated path references in:
  - Root `package.json` (`docs:dev` script)
  - `.gitignore` and `.prettierignore`
  - `apps/docs/components/geistdocs/edit-source.tsx` (GitHub edit URL)
  - `apps/docs/package.json` (link-checker path)
  - `docs/link-checker/package.json` (path to docs content)
2026-01-31 20:48:07 -07:00

49 lines
918 B
TypeScript

import type { ImageProps } from "next/image";
import Image from "next/image";
import { cn } from "@/lib/utils";
interface ImageAttrs {
src: string;
alt: string;
className?: string;
props?: Omit<ImageProps, "src" | "alt">;
}
interface ThemeAwareImageProps {
className?: string;
light: ImageAttrs;
dark: ImageAttrs;
}
export function ThemeAwareImage({
className,
light,
dark,
...other
}: ThemeAwareImageProps) {
const Images = (
<>
<Image
alt={dark.alt}
className={cn("hidden dark:block", dark.className)}
src={dark.src}
{...dark.props}
{...other}
/>
<Image
alt={light.alt}
className={cn("block dark:hidden", light.className)}
src={light.src}
{...light.props}
{...other}
/>
</>
);
if (className) {
return <div className={className}>{Images}</div>;
}
return Images;
}