|
1 | 1 | import React, { useEffect, useState } from 'react'; |
| 2 | +import { createGlobalStyle } from 'styled-components'; |
2 | 3 | import styled from 'styled-components'; |
3 | 4 | import { useParams } from 'react-router-dom'; |
4 | 5 | import Profile from './Profile'; |
5 | 6 | import profilesList from '../../ProfilesList.json'; |
6 | 7 |
|
| 8 | +const GlobalFont = createGlobalStyle` |
| 9 | + @import url('https://fonts.googleapis.com/css2?family=Merriweather+Sans:wght@300&display=swap'); |
| 10 | + .custom-font { |
| 11 | + font-family: 'Merriweather Sans', sans-serif; |
| 12 | + } |
| 13 | +`; |
| 14 | + |
7 | 15 | const ProfilePage = () => { |
8 | 16 | const { name } = useParams(); |
9 | 17 | const [profileData, setProfileData] = useState(null); |
@@ -42,19 +50,22 @@ const ProfilePage = () => { |
42 | 50 | } |
43 | 51 |
|
44 | 52 | return ( |
45 | | - <div className="min-h-screen bg-[#0e1a34] pt-12 text-white"> |
46 | | - <div className="mx-2 md:mx-16"> |
47 | | - <Profile data={profileData} /> |
48 | | - </div> |
49 | | - <div className="mt-8 flex justify-center"> |
50 | | - <a href="https://www.devdisplay.org" target="_blank" rel="noopener noreferrer"> |
51 | | - <StyledButton> |
52 | | - <div className="blob1" /> |
53 | | - <div className="inner">Visit DevDisplay</div> |
54 | | - </StyledButton> |
55 | | - </a> |
| 53 | + <> |
| 54 | + <GlobalFont /> |
| 55 | + <div className="custom-font min-h-screen bg-[#0e1a34] pt-12 text-white"> |
| 56 | + <div className="mx-2 md:mx-16"> |
| 57 | + <Profile data={profileData} /> |
| 58 | + </div> |
| 59 | + <div className="mt-8 flex justify-center"> |
| 60 | + <a href="https://www.devdisplay.org" target="_blank" rel="noopener noreferrer"> |
| 61 | + <StyledButton> |
| 62 | + <div className="blob1" /> |
| 63 | + <div className="inner">Visit DevDisplay</div> |
| 64 | + </StyledButton> |
| 65 | + </a> |
| 66 | + </div> |
56 | 67 | </div> |
57 | | - </div> |
| 68 | + </> |
58 | 69 | ); |
59 | 70 | }; |
60 | 71 |
|
|
0 commit comments