import { Box } from "@chakra-ui/core"
import { motion } from "framer-motion"
const MotionBox = motion.custom(Box)
function Example() {
return (
<MotionBox
boxSize="40px"
bg="red.300"
drag="x"
dragConstraints={{ left: -100, right: 100 }}
whileHover={{ scale: 1.1 }}
whileTap={{ scale: 0.9 }}
/>
)
}