Skip to content
Snippets Groups Projects
Commit fb89e233 authored by brunoravera's avatar brunoravera
Browse files

WIP

parent a7240565
No related branches found
No related tags found
No related merge requests found
import { Divider, HStack, Icon, IconButton, Text } from '@chakra-ui/react'
import { Box, Divider, HStack, Icon, IconButton, Text } from '@chakra-ui/react'
import { Link, back, routes, useLocation } from '@redwoodjs/router'
import React from 'react'
import { FaArrowLeft } from 'react-icons/fa'
export const Topbar: React.FC = () => {
const asd = useLocation()
console.log({ asd })
const { pathname } = useLocation()
const handleOnBack = () => {
back()
}
return (
<>
<HStack h="10" w="full" justifyContent="space-between">
<IconButton
aria-label="back"
variant="unstyled"
onClick={handleOnBack}
icon={<Icon as={FaArrowLeft} />}
/>
<HStack h="10" w="full" justifyContent="space-between" pr="4">
{pathname !== '/' ? (
<IconButton
aria-label="back"
variant="unstyled"
onClick={handleOnBack}
icon={<Icon as={FaArrowLeft} />}
/>
) : (
<Box />
)}
<Link to={routes.patterns()}>
<Text textAlign="right">Patrones</Text>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment