mirror of
https://github.com/massbug/judge4c.git
synced 2025-05-17 23:12:23 +00:00
refactor(back-button): relocate and rename back button component
- Move from features/problems/components to shared components directory - Rename NavigateBackButton to simpler BackButton - Update component interface naming to BackButtonProps - Keep all existing functionality intact
This commit is contained in:
parent
ad8a3e646e
commit
9766dea138
@ -10,12 +10,12 @@ import { useTranslations } from "next-intl";
|
|||||||
import { ArrowLeftIcon } from "lucide-react";
|
import { ArrowLeftIcon } from "lucide-react";
|
||||||
import { Button } from "@/components/ui/button";
|
import { Button } from "@/components/ui/button";
|
||||||
|
|
||||||
interface NavigateBackButtonProps {
|
interface BackButtonProps {
|
||||||
href: string;
|
href: string;
|
||||||
className?: string;
|
className?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
const NavigateBackButton = ({ href, className }: NavigateBackButtonProps) => {
|
export const BackButton = ({ href, className }: BackButtonProps) => {
|
||||||
const t = useTranslations();
|
const t = useTranslations();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@ -39,5 +39,3 @@ const NavigateBackButton = ({ href, className }: NavigateBackButtonProps) => {
|
|||||||
</TooltipProvider>
|
</TooltipProvider>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export { NavigateBackButton };
|
|
Loading…
Reference in New Issue
Block a user