UI/backButton: use button and icon component
This commit is contained in:
@@ -1,10 +1,15 @@
|
||||
import { useNavigate } from "@solidjs/router";
|
||||
import { Button } from "./button";
|
||||
import Icon from "./icon";
|
||||
|
||||
export const BackButton = () => {
|
||||
const navigate = useNavigate();
|
||||
return (
|
||||
<button class="btn btn-square btn-ghost" onClick={() => navigate(-1)}>
|
||||
<span class="material-icons ">arrow_back_ios</span>
|
||||
</button>
|
||||
<Button
|
||||
variant="light"
|
||||
class="w-fit"
|
||||
onClick={() => navigate(-1)}
|
||||
startIcon={<Icon icon="ArrowLeft" />}
|
||||
></Button>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user