diff options
| author | 2023-11-03 21:13:33 +0800 | |
|---|---|---|
| committer | 2023-11-03 21:13:33 +0800 | |
| commit | 9f0d43fe099a95ab1516ae951dcb60a89e76a5a5 (patch) | |
| tree | 51614fe47bff8bb11028a07d4a35c34c9ff6594a /docs/components/image/ThemedImage.tsx | |
| parent | 8f135707d069c900e055dae71e69909d6b9a41bb (diff) | |
| download | HydroRoll-9f0d43fe099a95ab1516ae951dcb60a89e76a5a5.tar.gz HydroRoll-9f0d43fe099a95ab1516ae951dcb60a89e76a5a5.zip | |
chore: delete useless codes
Diffstat (limited to 'docs/components/image/ThemedImage.tsx')
| -rw-r--r-- | docs/components/image/ThemedImage.tsx | 45 |
1 files changed, 0 insertions, 45 deletions
diff --git a/docs/components/image/ThemedImage.tsx b/docs/components/image/ThemedImage.tsx deleted file mode 100644 index 0416bd9..0000000 --- a/docs/components/image/ThemedImage.tsx +++ /dev/null @@ -1,45 +0,0 @@ -import React from "react"; -import Image from "next/image"; - -export interface Image { - height: number; - width: number; - source: string; -} - -export interface ThemedImageProps { - title?: string; - dark?: Image; - light?: Image; - priority?: boolean; -} - -export function ThemedImage({ - title, - light, - dark, - priority = false, -}: ThemedImageProps) { - return ( - <> - <div className="block w-full dark:hidden"> - <Image - alt={title} - src={light.source} - width={light.width} - height={light.height} - priority={priority} - /> - </div> - <div className="hidden w-full dark:block"> - <Image - alt={title} - src={dark.source} - width={dark.width} - height={dark.height} - priority={priority} - /> - </div> - </> - ); -} |
