Skip to content

Commit

Permalink
add react-techs-logos and social links
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasferreiralimax committed Oct 19, 2024
1 parent 7fcd23e commit c6bfd50
Show file tree
Hide file tree
Showing 7 changed files with 209 additions and 69 deletions.
178 changes: 119 additions & 59 deletions package-lock.json

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"react-dom": "^18.3.1",
"react-i18next": "^15.0.3",
"react-router-dom": "^6.27.0",
"react-scripts": "^5.0.1"
"react-scripts": "^5.0.1",
"react-techs-logos": "^0.1.22"
},
"scripts": {
"start": "react-scripts start",
Expand Down
36 changes: 36 additions & 0 deletions src/components/base/AppSocial/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import React from "react";
import ReactTechsLogos from "react-techs-logos";

import "./style.scss";
function AppSocial() {
return (
<div className="social-links" data-testid="app-social">
{/* <a
href="https://npmjs.com/package/slidecontent-react"
target="_blank"
rel="noreferrer"
className="tech-container"
>
<ReactTechsLogos name="npm" hiddenLabel />
</a> */}
<a
href="https://www.linkedin.com/in/lucasferreiralimax"
target="_blank"
rel="noreferrer"
className="tech-container"
>
<ReactTechsLogos name="linkedin" hiddenLabel />
</a>
<a
href="https://github.com/criar-art/slidecontent-react"
target="_blank"
rel="noreferrer"
className="tech-container"
>
<ReactTechsLogos name="github" hiddenLabel />
</a>
</div>
);
}

export default AppSocial;
24 changes: 24 additions & 0 deletions src/components/base/AppSocial/style.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
.social-links {
max-width: 210px;
display: flex;
margin: 1rem auto;
gap: .4rem;
.tech-container figure {
width: 90px;
height: 90px;

background: transparent;
border: 1px solid var(--vtl-background);
border-radius: 100px;
text-align: center;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
transition: .3s all;

svg {
height: 50px;
}
}
}
17 changes: 17 additions & 0 deletions src/components/base/AppSocial/test.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { render, screen } from "@testing-library/react";
import { BrowserRouter } from "react-router-dom";

import AppSocial from ".";

describe("Should render <AppSocial/>", () => {
beforeEach(() => {
render(
<BrowserRouter>
<AppSocial />
</BrowserRouter>
);
});
it("renders app-logo", () => {
expect(screen.getByTestId("app-social")).toBeInTheDocument();
});
});
4 changes: 3 additions & 1 deletion src/views/Home/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,14 @@ import motorcycle from '../../assets/motorcycle.jpg';

import SlideContent from '../../components/SlideContent/index.js';
import SlideItem from '../../components/SlideItem/index.js';
import AppSocial from '../../components/base/AppSocial/index.js';

function Home() {
const { t } = useTranslation();
return (
<section className='home' data-testid='view-home'>
<div className="example">
<AppSocial />
<div className="example first">
<h2 className="slide-title">
<svg width="60px" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">
<path d="M315.712 334.4a236.543 236.543 0 0029.136 18.192l14.784-28.384a204.034 204.034 0 01-25.168-15.744L315.712 334.4z"/>
Expand Down
16 changes: 8 additions & 8 deletions src/views/Home/style.scss
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&display=swap');
@import url("https://fonts.googleapis.com/css2?family=Great+Vibes&display=swap");

.example {
padding-bottom: 6rem;
padding-top: 2rem;
box-shadow: 0 15px 25px rgba(0, 0, 0, .06);

&:first-of-type {
margin-top: 2rem;
box-shadow: 0 15px 25px rgba(0, 0, 0, 0.06);
&.first {
padding-top: 0;
border-top: 1px solid #eee;
box-shadow: 0 15px 25px rgba(0, 0, 0, .06), 0 -5px 15px rgba(0, 0, 0, .02);
box-shadow:
0 15px 25px rgba(0, 0, 0, 0.06),
0 -5px 15px rgba(0, 0, 0, 0.02);
}
}

Expand All @@ -20,7 +20,7 @@ h3 {
justify-content: center;

svg {
margin-right: .5em;
margin-right: 0.5em;
}
}

Expand All @@ -41,7 +41,7 @@ h3 {

.favela {
h1 {
font-family: 'Great Vibes', cursive;
font-family: "Great Vibes", cursive;
}

img {
Expand Down

0 comments on commit c6bfd50

Please sign in to comment.