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/ThemedImageFigure.tsx | |
| parent | 8f135707d069c900e055dae71e69909d6b9a41bb (diff) | |
| download | HydroRoll-9f0d43fe099a95ab1516ae951dcb60a89e76a5a5.tar.gz HydroRoll-9f0d43fe099a95ab1516ae951dcb60a89e76a5a5.zip | |
chore: delete useless codes
Diffstat (limited to 'docs/components/image/ThemedImageFigure.tsx')
| -rw-r--r-- | docs/components/image/ThemedImageFigure.tsx | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/docs/components/image/ThemedImageFigure.tsx b/docs/components/image/ThemedImageFigure.tsx deleted file mode 100644 index 9c50dc7..0000000 --- a/docs/components/image/ThemedImageFigure.tsx +++ /dev/null @@ -1,47 +0,0 @@ -import React from "react"; -import { ImageFigureProps } from "./ImageFigure"; -import { ThemedImage, ThemedImageProps } from "./ThemedImage"; -import cn from "classnames"; -export type ThemedImageFigureProps = Omit<ImageFigureProps, "src"> & - ThemedImageProps; - -export function ThemedImageFigure( - props: ThemedImageFigureProps -): React.ReactNode { - const { - caption, - margin = 40, - captionSpacing = null, - shadow = false, - borderRadius = false, - ...rest - } = props; - - return ( - <figure - className="block -mx-4 text-center sm:-mx-4 md:-mx-7 lg:-mx-12" - style={{ marginTop: `${margin}px`, marginBottom: `${margin}px` }} - > - <div - className={cn( - "relative inline-block max-w-full overflow-hidden border-box text-[0px]", - { - "rounded-md": borderRadius, - "shadow-lg": shadow, - } - )} - > - {/* eslint-disable-next-line jsx-a11y/alt-text */} - <ThemedImage {...rest} /> - </div> - {caption && ( - <figcaption - className="m-0 text-xs text-center text-gray-500" - style={captionSpacing ? { marginTop: captionSpacing } : {}} - > - {caption} - </figcaption> - )} - </figure> - ); -} |
