| { | { | ||||
| "name": "frontend", | "name": "frontend", | ||||
| "version": "1.1.0", | |||||
| "version": "1.1.1", | |||||
| "private": true, | "private": true, | ||||
| "dependencies": { | "dependencies": { | ||||
| "@faceless-ui/slider": "^1.1.14", | "@faceless-ui/slider": "^1.1.14", |
| function App() { | function App() { | ||||
| //tabs for contact form | //tabs for contact form | ||||
| const [tab, setTab] = useState(true); | |||||
| const [tabTitle, setTabTitle] = useState('Tell Us About Your Idea!'); | |||||
| const link = useNavigate(); | const link = useNavigate(); | ||||
| //scroll to Contact segment | //scroll to Contact segment | ||||
| function scrollToView(event) { | function scrollToView(event) { | ||||
| event.preventDefault(); | event.preventDefault(); | ||||
| if (forwardedRef) { | if (forwardedRef) { | ||||
| forwardedRef.current.scrollIntoView({ behavior: 'smooth' }); | |||||
| //console.log(forwardedRef.current.offsetTop); | |||||
| window.scrollTo({ behavior: 'smooth', top: forwardedRef.current.offsetTop }) | |||||
| } else { | } else { | ||||
| link('/contact'); | link('/contact'); | ||||
| } | } | ||||
| ></Navigation> | ></Navigation> | ||||
| <Suspense fallback={<Loader />}> | <Suspense fallback={<Loader />}> | ||||
| <Routes> | <Routes> | ||||
| <Route exact path="/" element={<Home />}/> | |||||
| <Route exact path="/" element={<Home forwardedRef={forwardedRef} />}/> | |||||
| <Route exact path="/workwithus" element={<WorkWithUs />}/> | <Route exact path="/workwithus" element={<WorkWithUs />}/> | ||||
| <Route exact path="/portfolio" element={<Portfolio />}/> | <Route exact path="/portfolio" element={<Portfolio />}/> | ||||
| <Route exact path="/process" element={<ProcessPage />}/> | <Route exact path="/process" element={<ProcessPage />}/> |
| import Wrapper from '../../layout/Wrapper'; | import Wrapper from '../../layout/Wrapper'; | ||||
| import menuIcon from './../../assets/icons/menu.svg'; | import menuIcon from './../../assets/icons/menu.svg'; | ||||
| export default function Navigation({ links, scrollToView, activeLinks }) { | |||||
| export default function Navigation({ links, scrollToView, activeLinks, forwardedRef }) { | |||||
| const location = useLocation(); | const location = useLocation(); | ||||
| const home = useNavigate(); | const home = useNavigate(); | ||||
| function handleLogo() { | function handleLogo() { |
| @tailwind components; | @tailwind components; | ||||
| @tailwind utilities; | @tailwind utilities; | ||||
| html { | |||||
| scroll-behavior: smooth; | |||||
| } | |||||
| html, body { | html, body { | ||||
| scrollbar-face-color: rgb(210,210,210); /* Firefox 63 compatibility */ | scrollbar-face-color: rgb(210,210,210); /* Firefox 63 compatibility */ |
| const api_url = process.env.REACT_APP_API_URL; | const api_url = process.env.REACT_APP_API_URL; | ||||
| //const query = ''; | |||||
| const strapiPopulate = [ | const strapiPopulate = [ | ||||
| 'Heading', | 'Heading', | ||||
| return stringQuery; | return stringQuery; | ||||
| }; | }; | ||||
| export default function Home({ forwardedRef }) { | |||||
| export default function Home({forwardedRef}) { | |||||
| const [cnt, setCnt] = useState(''); | const [cnt, setCnt] = useState(''); | ||||
| const [landingData, setLandingData] = useState(null); | const [landingData, setLandingData] = useState(null); | ||||
| const [cardData, setCardData] = useState(null); | const [cardData, setCardData] = useState(null); | ||||
| </PageLayout> | </PageLayout> | ||||
| ); | ); | ||||
| } | } | ||||
| } | |||||
| } |