diff --git a/gatsby-config.js b/gatsby-config.js index 8163b567..20b0f4a2 100644 --- a/gatsby-config.js +++ b/gatsby-config.js @@ -37,24 +37,17 @@ module.exports = { apiURL: process.env.STRAPI_URL, queryLimit: 1000, collectionTypes: [ - `banners`, - `services`, - `edTeches`, - `ed-tech-submodules`, `article`, `blog-category`, - `landing-page` + `landing-page`, + `case`, + `icon` ], singleTypes: [ - `ed-tech-page`, `global-seo`, - `services-page`, `home`, `blog-page`, - `bitway-page`, - `contact-page`, `global-config`, - `jobs-page`, `layout`, ], }, diff --git a/gatsby-node.js b/gatsby-node.js index c3d0b141..8b9a5266 100644 --- a/gatsby-node.js +++ b/gatsby-node.js @@ -1,11 +1,26 @@ const path = require("path") exports.createSchemaCustomization = ({ actions }) => { - const schema = require("./src/schema/schema") + const blogSchema = require("./src/schema/blogSchema") + const caseSchema = require("./src/schema/caseSchema") + const globalSeoSchema = require("./src/schema/globalSeoSchema") + const homeSchema = require("./src/schema/homeSchema") + const iconSchema = require("./src/schema/iconSchema") + const landingSchema = require("./src/schema/landingSchema") + const layoutSchema = require("./src/schema/layoutSchema") + const generalSchema = require("./src/schema/generalSchema") const { createTypes } = actions - const typeDefs = schema.value // + luego se concatenan - + const typeDefs = + blogSchema.value + + blogSchema.value + + caseSchema.value + + globalSeoSchema.value + + homeSchema.value + + iconSchema.value + + landingSchema.value + + layoutSchema.value + + generalSchema.value createTypes(typeDefs) } diff --git a/public/page-data/index/page-data.json b/public/page-data/index/page-data.json index afd45c7a..3114acdb 100644 --- a/public/page-data/index/page-data.json +++ b/public/page-data/index/page-data.json @@ -2,4 +2,4 @@ "componentChunkName": "component---src-pages-index-js", "path": "/", "result": {"pageContext":{}}, - "staticQueryHashes": ["1128713364","1279924571","1292738615","1693928026","176670904","1868451474","1921816282","2499611023","2898073905","416013508","770242822","882490824"]} \ No newline at end of file + "staticQueryHashes": ["1128713364","1693928026","176670904","2898073905","3298386516","651390938"]} \ No newline at end of file diff --git a/src/components/BannerList/Banner.scss b/src/components/BannerList/Banner.scss index ca7a6b64..c6cdc0d1 100644 --- a/src/components/BannerList/Banner.scss +++ b/src/components/BannerList/Banner.scss @@ -5,24 +5,20 @@ p { text-align: justify; margin: 0 !important; - font-size: 16px; } img { width: 48px; } } &__title { - font-size: $second-large; - text-align: center; + font-weight: 700; + text-align: left; } } @media screen and (min-width: $breakpoint-xl) { .bannerList { .card_item { - p { - font-size: 20px; - } img { width: 70px; } diff --git a/src/components/BannerList/BannerLis.js b/src/components/BannerList/BannerLis.js index d5993b24..0d93afed 100644 --- a/src/components/BannerList/BannerLis.js +++ b/src/components/BannerList/BannerLis.js @@ -1,36 +1,35 @@ -import React from 'react'; -import './Banner.scss'; +import React from "react" +import "./Banner.scss" export default function BannerLis({ data }) { - const title = data?.title; - const image = data?.Card[0]?.icon?.url; - console.log(data) - console.log(image) - - const cards = data?.Card.map((item) => { - return ( -
-
- -
-
-

{item.title}

-

{item.description}

-
-
- ) - - }) + const title = data?.title + const image = data?.Card[0]?.icon?.url + const cards = data?.Card.map(item => { return ( -
-
{title}
-
{cards}
+
+
+
- +
+

{item.title}

+

{item.description}

+
+
) + }) + + return ( +
+
+

+ {title} +

+
{cards}
+
+
+ ) } diff --git a/src/components/BitwayPage/BitwayContainer.js b/src/components/BitwayPage/BitwayContainer.js deleted file mode 100755 index 5cf99426..00000000 --- a/src/components/BitwayPage/BitwayContainer.js +++ /dev/null @@ -1,87 +0,0 @@ -import * as React from "react" - -import Layout from "../../components/layout" -import { Seo } from "../index" -import useBitwayPage from "../../hooks/useBitwayPage" -import Gallery from "./Gallery/Gallery" -import Paragraph from "./Paragraph/Paragraph" -import "./BitwayContainer.scss" -import BannerActionCall from "../Banners/BannerActionCall" - - -const BitwayPage = () => { - const { - allStrapiBitwayPage: { nodes }, - } = useBitwayPage() - - const sections = nodes[0]?.sections - const bannerActionCall = nodes[0]?.actionCallBanner - const { pageTitle, pageDescription, pageKeywords } = nodes[0]?.SEO - - // vista desktop - // sort funciona con referencia, asi que se crea una nueva array - const sectionswide = [...sections] - // se ordenan las galerias primero - // se filtran las galerias y los parrafos - const gallery = sectionswide.filter(e => e.galleryImage) - const paragraph = sectionswide - .filter(e => e.body) - .map(e => ) - // y se renderizan - return ( - - {nodes[0]?.SEO && ( - - )} - {sections.length > 0 && ( - -
- {/* se renderiza por vistas */} - {/* vista mobile */} - {sections?.map((elem, index, array) => { - if (elem.galleryImage) { - if (array[index - 1]?.galleryImage) { - return null - } - if (array[index + 1]?.galleryImage) { - return ( - - ) - } else { - return ( - - ) - } - } else if (elem.body) { - return ( - - ) - } else { - return null - } - })} - {/* vista desktop */} - -
{paragraph}
-
- )} - {bannerActionCall && ( - - )} -
- ) -} - -export default BitwayPage diff --git a/src/components/BitwayPage/BitwayContainer.scss b/src/components/BitwayPage/BitwayContainer.scss deleted file mode 100644 index 8fdc7da0..00000000 --- a/src/components/BitwayPage/BitwayContainer.scss +++ /dev/null @@ -1,38 +0,0 @@ -@import "../../styles/global.scss"; - -.bitway-body { - display: grid; - grid-template-columns: 1fr 1fr; - grid-template-areas: "bitway-odd bitway-even"; - padding: 20px; - gap: 26px; - max-width: 100vw; - margin-bottom: 75px; - -} - -.bitway-body:nth-child(odd) { - grid-area: bitway-odd; -} - -.bitway-body:nth-child(even) { - grid-area: bitway-even; -} - -.bitway-mobile { - display: none; -} - -@media (max-width: 992px) { - .bitway-body { - grid-template-columns: 1fr; - padding: 20px; - grid-template-areas: "bitway-even" "bitway-odd"; - } - .bitway-desktop { - display: none; - } - .bitway-mobile { - display: grid; - } -} diff --git a/src/components/BitwayPage/Gallery/Gallery.js b/src/components/BitwayPage/Gallery/Gallery.js deleted file mode 100644 index 4ac31abb..00000000 --- a/src/components/BitwayPage/Gallery/Gallery.js +++ /dev/null @@ -1,72 +0,0 @@ -import React from "react" -import "./Gallery.scss" -import { getImage } from "gatsby-plugin-image" -import { BgImage } from "gbimage-bridge" - -const layouts = { - dos: { - gridTemplateAreas: '"gal0 gal0 gal1" "gal0 gal0 gal1"', - gridTemplateColumns: "2fr 25% 3fr", - }, - cuatro: { - gridTemplateAreas: '"gal0 gal1 gal1" "gal0 gal2 gal3" "gal0 gal2 gal3"', - gridTemplateColumns: "2fr 25% 3fr", - }, - cuatroinvertido: { - gridTemplateAreas: '"gal0 gal0 gal3" "gal1 gal2 gal3" "gal1 gal2 gal3"', - gridTemplateColumns: "3fr 25% 2fr", - }, -} - -const photos = { - dos: 2, - cuatro: 4, - cuatroinvertido: 4, -} - -const Gallery = ({ content, ...extra }) => { - return ( -
- {content.map(elem => ( -
- {fillGrid(elem.galleryImage, photos[elem.type]).map( - (image, index) => { - const prosImage = getImage(image?.image?.localFile) - return ( - - {image.text && ( -
- {image.text} -
- )} -
- ) - } - )} -
- ))} -
- ) -} - -const fillGrid = (images, total) => { - let newImagesArray = [] - while (newImagesArray.length < total) { - newImagesArray = [...newImagesArray, ...images] - } - return newImagesArray.slice(0, total) -} - -export default Gallery diff --git a/src/components/BitwayPage/Gallery/Gallery.scss b/src/components/BitwayPage/Gallery/Gallery.scss deleted file mode 100644 index d30356bb..00000000 --- a/src/components/BitwayPage/Gallery/Gallery.scss +++ /dev/null @@ -1,70 +0,0 @@ -.bitway-gallery-0 { - grid-area: gal0; -} -.bitway-gallery-1 { - grid-area: gal1; -} -.bitway-gallery-2 { - grid-area: gal2; -} -.bitway-gallery-3 { - grid-area: gal3; -} -.bitway-gallery-4 { - grid-area: gal4; -} -.bitway-gallery-5 { - grid-area: gal5; -} - -.bitway-gallery { - display: grid; - grid-template-rows: 400px; - gap: 10px; - overflow: hidden; -} - -.bitway-gallery-container { - display: grid; - grid-template-columns: 1fr; - gap: 20px; -} - -.bitway-gallery-item { - position: relative; - min-height: 400px; -} - -.bitway-gallery-item-inner { - width: 100%; - height: 100%; - display: flex; - justify-content: center; - align-items: center; - background: #1ECAD380; - color: white; - font-family: Roboto; - font-size: 35px; - font-style: normal; - font-weight: 700; - line-height: 51px; - letter-spacing: 0em; - text-align: center; -} - - -@media (max-width: 992px) { - .bitway-gallery { - grid-template-rows: 250px; - } - - .bitway-gallery-item-inner { - font-size: 20px; - } - - - .bitway-gallery-item { - min-height: 250px; - } - -} diff --git a/src/components/BitwayPage/Paragraph/Paragraph.js b/src/components/BitwayPage/Paragraph/Paragraph.js deleted file mode 100644 index c7bbe237..00000000 --- a/src/components/BitwayPage/Paragraph/Paragraph.js +++ /dev/null @@ -1,17 +0,0 @@ -import React from "react" -import "./Paragraph.scss" -import MarkdownView from "react-showdown" -const Paragraph = ({ text: { body }, ...extra }) => { - return ( -
- -
- ) -} - -export default Paragraph diff --git a/src/components/BitwayPage/Paragraph/Paragraph.scss b/src/components/BitwayPage/Paragraph/Paragraph.scss deleted file mode 100644 index 3ed9bde7..00000000 --- a/src/components/BitwayPage/Paragraph/Paragraph.scss +++ /dev/null @@ -1,116 +0,0 @@ -@import "../../../styles/global.scss"; -.bitway-paragraph { - color: $primary; - margin-bottom: 20px; - & p { - font-family: $primary-font; - font-size: 20px; - font-style: normal; - font-weight: 400; - line-height: 30px; - letter-spacing: 0em; - text-align: justify; - } - & > div > p { - font-family: $primary-font; - font-size: 20px; - font-style: normal; - font-weight: 400; - line-height: 30px; - letter-spacing: 0em; - text-align: justify; - // padding: 0 80px 20px; - & * { - font-size: 20px; - } - & a { - color: $blue; - } - } - & h1, - h2, - h3, - h4, - h5, - h6 { - text-align: center; - color: $blue; - font-family: $primary-font; - font-size: $large; - font-style: normal; - font-weight: 700; - line-height: 40px; - letter-spacing: 0em; - text-align: center; - margin: 40px 0 45px; - & span { - font-size: $large; - background-color: $blue; - padding: 0 10px; - margin: 0 0 0 5px; - transform: skew(-15deg); - display: inline-block; - & p { - font-size: $large; - font-weight: $bold; - margin: 0; - display: inline-block; - color: $primary-container; - transform: skew(15deg); - } - } - } -} - -@media (max-width: 992px) { - .bitway-paragraph { - & p { - font-family: $primary-font; - font-size: 15px; - font-style: normal; - font-weight: 400; - line-height: 26px; - letter-spacing: 0em; - text-align: justify; - } - & > div > p { - font-family: $primary-font; - font-size: 15px; - font-style: normal; - font-weight: 400; - line-height: 26px; - letter-spacing: 0em; - text-align: justify; - // padding: 0 20px 0px 0px; - & * { - font-size: 15px; - } - & a { - color: $blue; - } - } - } -} - -@media (min-width: $breakpoint-lg) { - .bitway-paragraph { - & h1, - h2, - h3, - h4, - h5, - h6 { - font-size: $extra-large; - & span { - padding: 15px 10px 5px; - & p { - font-size: $extra-large; - } - } - } - - & > div > p { - padding: 0 80px 20px; - } - } -} diff --git a/src/components/BlogPage/BlogArticle/BlogArticle.js b/src/components/BlogPage/BlogArticle/BlogArticle.js index d7b31d2d..985bdf21 100644 --- a/src/components/BlogPage/BlogArticle/BlogArticle.js +++ b/src/components/BlogPage/BlogArticle/BlogArticle.js @@ -14,13 +14,15 @@ const BlogArticle = ({ title, summary, image, slug, text }) => { className="article__image" />
-

{`${title} ...`}

+
{`${title} ...`}
{/* */}
- {text} + + +
diff --git a/src/components/BlogPage/BlogArticle/BlogArticle.scss b/src/components/BlogPage/BlogArticle/BlogArticle.scss index 829e7320..11012aaf 100644 --- a/src/components/BlogPage/BlogArticle/BlogArticle.scss +++ b/src/components/BlogPage/BlogArticle/BlogArticle.scss @@ -21,7 +21,7 @@ width: 100%; height: 150px; padding: 0 15px; - color: $primary; + color: $black; h1, h2, h3, @@ -29,11 +29,10 @@ h5, h6 { padding-left: 0; + font-size: 15px !important; margin-bottom: 15px; - font-size: $small; line-height: 1rem; - font-weight: $max-bold; - color: $blue; + color: $black; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; @@ -42,31 +41,35 @@ p { margin-bottom: 15px; - font-size: 12px; line-height: 24px; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; - - em { - font-size: 12px; - } } } &__link { - text-align: end; - a { - padding: 7px; margin-right: 0; font-size: 12px; font-weight: $max_bold; - text-decoration: none; - color: $blue; - border-bottom: 5px solid $yellow; cursor: pointer; + + button { + @include primaryBtn; + } + } + } +} + +@media (min-width: $breakpoint-md) { + .article { + &__description { + h6 { + margin-bottom: 2px; + line-height: 1.3rem; + } } } } @@ -89,11 +92,8 @@ height: 200px; padding: 0; - h3 { - margin-bottom: 1.5rem; - font-size: $large; + h6 { line-height: 1.6rem; - color: $blue; -webkit-line-clamp: 2; } diff --git a/src/components/BlogPage/BlogContainer.scss b/src/components/BlogPage/BlogContainer.scss index 069a03c1..3dcc8221 100644 --- a/src/components/BlogPage/BlogContainer.scss +++ b/src/components/BlogPage/BlogContainer.scss @@ -13,28 +13,25 @@ width: 100%; height: 190px; text-align: center; - border-bottom: 4px solid $blue; + border-bottom: 4px solid$alt; h3 { margin-bottom: 0; padding: 5px; - font-size: $medium; - line-height: $large; - font-weight: 700; - color: $blue; + color: $primary; + line-height: 40px; span { display: inline-block; - margin-top: 20px; - background-color: $blue; + margin-top: 10px; + background-color: $primary; overflow: hidden; transform: skew(-20deg); - margin-left: 10px; + margin-left: 15px; - p { - font-size: $medium; - padding: 10px; + h3 { margin-bottom: 0; + padding: 8px; color: $white; transform: skew(20deg); } @@ -49,17 +46,10 @@ .banner__container { h3 { - display: flex; - align-items: center; - font-size: $large; - + line-height: 50px; span { margin-top: 0; margin-left: 15px; - - p { - font-size: $large; - } } } } @@ -72,11 +62,11 @@ .banner__container { h3 { - font-size: $second-large; + display: flex; + align-items: center; span { - p { - padding: 20px; - font-size: $second-large; + h3 { + padding: 15px; } } } diff --git a/src/components/BlogPage/BlogGrid/BlogGrid.js b/src/components/BlogPage/BlogGrid/BlogGrid.js index 3cf55719..047c1b99 100644 --- a/src/components/BlogPage/BlogGrid/BlogGrid.js +++ b/src/components/BlogPage/BlogGrid/BlogGrid.js @@ -2,10 +2,10 @@ import React from 'react' import './BlogGrid.scss' import Pagination from '../../Pagination/Pagination' -const BlogGrid = ({title, children}) => { +const BlogGrid = ({ title, children }) => { return (
-

{title}

+
{title}
{/*
{children}
*/}
diff --git a/src/components/BlogPage/BlogGrid/BlogGrid.scss b/src/components/BlogPage/BlogGrid/BlogGrid.scss index 0e608819..d23011d8 100644 --- a/src/components/BlogPage/BlogGrid/BlogGrid.scss +++ b/src/components/BlogPage/BlogGrid/BlogGrid.scss @@ -1,33 +1,32 @@ @import "../../../styles/global.scss"; .grid { - &__container { - display: flex; - flex-direction: column; - justify-content: center; - padding: 40px 0; - border-bottom: 4px solid $blue; + &__container { + display: flex; + flex-direction: column; + justify-content: center; + padding: 40px 0; + border-bottom: 4px solid $alt; - h3 { - padding-left: 5px; - font-size: $medium; - color: $primary; - } + h3 { + padding-left: 5px; + font-size: $medium; + color: $blackBit; } + } } -@media (min-width: $breakpoint-xl) { - - .grid { - &__container { - h3 { - padding-left: 35px; - font-size: $large; - } - } +@media (min-width: $breakpoint-lg) { + .grid { + &__container { + h3 { + padding-left: 35px; + font-size: $large; + } + } - &__content { - display: grid; - grid-template-columns: 1fr 1fr 1fr; - } + &__content { + display: grid; + grid-template-columns: 1fr 1fr 1fr; } -} \ No newline at end of file + } +} diff --git a/src/components/CasesSection/CasesSection.js b/src/components/CasesSection/CasesSection.js new file mode 100644 index 00000000..02638167 --- /dev/null +++ b/src/components/CasesSection/CasesSection.js @@ -0,0 +1,39 @@ +import React from "react" +import "./CasesSection.scss" +import { FaRegThumbsUp, FaShareAlt, FaRegComment } from "react-icons/fa"; + +const CasesSection = ({ data }) => { + const { title, cases } = data + + const casesCards = cases.map((caso, idx) => { + + return ( +
+
+ A kitten +
+
+
+
{caso.title}
+

{caso.description}

+
+ +
+
+ + + +
+
+ ) + }) + + return ( +
+ {title &&

{title}

} + {casesCards.length > 0 &&
{casesCards}
} +
+ ) +} + +export default CasesSection diff --git a/src/components/CasesSection/CasesSection.scss b/src/components/CasesSection/CasesSection.scss new file mode 100644 index 00000000..2d166ed1 --- /dev/null +++ b/src/components/CasesSection/CasesSection.scss @@ -0,0 +1,60 @@ +@import "../../styles/global.scss"; + +.casesSection { + h2 { + text-align: center; + font-weight: 700; + } +} +.case { + --bs-gutter-x: 0 !important; + padding: 10px; + &__img { + height: 200px; + width: 100%; + object-fit: cover; + border-radius: 10px; + } + &__descr { + padding-left: 10px; + h5 { + font-weight: 700; + } + } + button { + @include primaryBtn; + margin-left: 10px; + } + &__socials { + display: flex; + justify-content: flex-start; + margin-top: 10px; + svg { + margin-right: 10px; + } + } +} + +@media screen and (min-width: $breakpoint-md) { + .case { + &__img { + height: 240px; + margin-bottom: 15px; + } + &__descr { + min-height: 120px; + max-height: 250px; + h5 { + margin-bottom: 10px; + } + } + &__socials { + justify-content: flex-end; + svg { + margin-left: 10px; + margin-right: 1px; + } + } + } +} + diff --git a/src/components/ContactPage/Contact.scss b/src/components/ContactPage/Contact.scss deleted file mode 100644 index d7a3acbc..00000000 --- a/src/components/ContactPage/Contact.scss +++ /dev/null @@ -1,85 +0,0 @@ -@import "../../styles/global.scss"; - -.contact { - display: flex; - flex-wrap: wrap; - &__group { - padding-top: 20px; - width: 85%; - margin: 0 auto; - } - &__title { - font-size: $large; - color: $blue; - font-weight: $max-bold; - margin-bottom: 0px; - padding: 70px 20px; - text-align: center; - h2 { - font-size: 30px; - margin-bottom: 0; - } - span{ - background-color: $blue; - display: inline-block; - transform: skew(-15deg); - height: 40px; - p { - color: $primary-container; - text-transform: uppercase; - padding: 5px 15px; - display: inline-block; - transform: skew(15deg); - font-size: 30px; - line-height: 30px; - } - } - } - &__image { - width: 100%; - height: 450px; - margin-top: 55px; - } -} - -@media screen and (min-width: 786px) { - .contact { - max-width: 1400px; - margin: 0 auto; - padding-bottom: 50px; - padding-top: 20px; - flex-direction: row-reverse; - justify-content: space-around; - &__group { - width: 43%; - } - &__title { - h2 { - font-size: 45px; - } - line-height: 1.1; - max-width: 500px; - margin: 0 auto; - span { - height: 50px; - p { - font-size: 45px; - line-height: 40px; - padding: 5px 40px; - } - } - } - &__image { - width: 43%; - height: 765px; - margin-left: 20px; - } - } - .contactForm { - &__input { - height: 75px; - padding: 40px 0; - } - } -} - diff --git a/src/components/ContactPage/ContactContainer.js b/src/components/ContactPage/ContactContainer.js deleted file mode 100644 index 66533a08..00000000 --- a/src/components/ContactPage/ContactContainer.js +++ /dev/null @@ -1,61 +0,0 @@ -import * as React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image"; -import MarkdownView from 'react-showdown'; -import HubspotForm from "react-hubspot-form" -import "./Contact.scss" -import { useContactPage } from "../../hooks/index" -import Layout from "../../components/layout" -import { Seo } from "../index" - -const Contact = () => { - - const contactData = useContactPage() - - - const { image, nameImage, title } = contactData?.allStrapiContactPage?.nodes[0] - const { formId, portalId } = contactData?.allStrapiContactPage?.nodes[0]?.contactForm || {} - const { pageTitle, pageDescription, pageKeywords } = contactData?.allStrapiContactPage?.nodes[0]?.pageMetadata || {} - - const contactImage = getImage(image?.localFile) - - return ( - - {contactData?.allStrapiContactPage?.nodes[0]?.pageMetadata && ( - - )} -
- {contactData.allStrapiContactPage.nodes[0] && ( -
- {title && ( -
- -
- )} - {formId && portalId && ( -
- Loading...
} - /> -
- )} -
- )} - {contactImage && ( - - )} - -
- ) -} - -export default Contact diff --git a/src/components/CustomSection/CustomSection.js b/src/components/CustomSection/CustomSection.js deleted file mode 100644 index e914a699..00000000 --- a/src/components/CustomSection/CustomSection.js +++ /dev/null @@ -1,96 +0,0 @@ -import React from "react" -import { - ServiceCards, - EdTechCards, - BannerBgImage, - BannerTop, - BannerLogo, - BannerISO, - BannerClientes, - PartnersSection, -} from "../index" -import "./CustomSection.scss" - -const CustomSection = ({ sections }) => { - - const section = sections.map((section, idx) => { - return ( -
- {(section?.enable && section?.services) !== null && - (section?.enable && section?.services) !== undefined ? ( - - ) : null} - {(section?.enable && section?.edteches) !== null && - (section?.enable && section?.edteches) !== undefined ? ( - - ) : null} - - {(section?.enable && section?.banner) !== null && - (section?.enable && section?.banner) !== undefined && - section?.banner.type === "bgImage" ? ( - - ) : null} - {(section?.enable && section?.banner) !== null && - (section?.enable && section?.banner) !== undefined && - section?.banner.type === "bgColor" ? ( - - ) : null} - {(section?.enable && section?.banner) !== null && - (section?.enable && section?.banner) !== undefined && - section?.banner.type === "homeLogo" ? ( - - ) : null} - {(section?.enable && section?.banner) !== null && - (section?.enable && section?.banner) !== undefined && - section?.banner.type === "iram" ? ( - - ) : null} - {(section?.enable && section?.banner) !== null && - (section?.enable && section?.banner) !== undefined && - section?.banner.type === "clientes" ? ( - - ) : null} - {section?.partners !== null ? ( - - ) : null - } -
- ) - }) - - return
{section}
-} - -export default CustomSection diff --git a/src/components/CustomSection/CustomSection.scss b/src/components/CustomSection/CustomSection.scss deleted file mode 100644 index 8b137891..00000000 --- a/src/components/CustomSection/CustomSection.scss +++ /dev/null @@ -1 +0,0 @@ - diff --git a/src/components/DualSection/DualSection.js b/src/components/DualSection/DualSection.js index b2828042..cde57e64 100644 --- a/src/components/DualSection/DualSection.js +++ b/src/components/DualSection/DualSection.js @@ -5,7 +5,7 @@ export default function DualSection({ data }) { const dualSectionParts = data?.dualSectionPart const listSectionParts = dualSectionParts.map((section) => -
+
-

{section.title}

+

{section.title}

{section.description}

- - + +
@@ -25,10 +25,13 @@ export default function DualSection({ data }) { ); return ( - +
{listSectionParts} +
+ + ) } diff --git a/src/components/DualSection/DualSection.scss b/src/components/DualSection/DualSection.scss index 7ced9781..ad127844 100644 --- a/src/components/DualSection/DualSection.scss +++ b/src/components/DualSection/DualSection.scss @@ -3,9 +3,21 @@ .dualSection { p { text-align: justify; + font-weight: 700; + } + h4 { + font-weight: 700; } &__image { width: 300px; } + button { + background: $light-grey; + color: white; + font-weight: 500; + border-radius: 3px; + border: none; + padding: 0.3em; + } } diff --git a/src/components/EdTechCards/EdTechCards.js b/src/components/EdTechCards/EdTechCards.js deleted file mode 100644 index 40451c08..00000000 --- a/src/components/EdTechCards/EdTechCards.js +++ /dev/null @@ -1,67 +0,0 @@ -import React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image" -import { Link } from "gatsby" -import showdown from "showdown" -import "./EdtechCards.scss" - -import { useTheme } from "../../context/themeContext" - -const EdTechCards = ({ title, edteches }) => { - const { theme } = useTheme() - - const titles = title - let converter = new showdown.Converter() - let post = titles - let html = converter.makeHtml(post) - - const ReplaceHtml = () => { - return { __html: html } - } - - const edtechCard = edteches - ?.map((edtech, idx) => ( -
-
-
- {" "} -
-
-

{edtech.homeTitle}

-

{edtech.homeIntro}

-
-
- - - Ver más - -
- )) - .slice(0, 3) - - return ( - <> -
-
-
-
-
- {edtechCard} -
-
-
-
- - ) -} -export default EdTechCards diff --git a/src/components/EdTechCards/EdtechCards.scss b/src/components/EdTechCards/EdtechCards.scss deleted file mode 100644 index b2a99799..00000000 --- a/src/components/EdTechCards/EdtechCards.scss +++ /dev/null @@ -1,170 +0,0 @@ -@import "../../styles/global.scss"; - -.EdtechCards { - background-color: $secondary-container; - width: 100%; - - padding: 33px 30px; - &__mainTitle { - display: flex; - flex-direction: column; - align-items: center; - flex-wrap: wrap; - - h1, - h2, - h3, - h4, - h5, - h6, - p, - span { - font-size: $large; - font-weight: $max-bold; - color: $white; - margin-bottom: 0px; - text-align: center; - } - - span { - /* -webkit-text-stroke: 2px $blue; */ - -webkit-text-fill-color: $yellow; - } - } - - &__card { - display: flex; - align-items: flex-end; - margin-right: 10px; - } - &__image { - align-self: flex-start; - padding-top: 5px; - display: flex; - justify-content: center; - } - &__textContainer { - display: flex; - flex-direction: column; - align-items: flex-start; - justify-content: flex-start; - padding-left: 10px; - } - &__title { - font-size: $medium; - font-weight: $max-bold; - color: $white; - margin-bottom: 5px; - } - &__intro { - font-size: $small; - font-weight: $normal; - color: $white; - - margin-bottom: 5px; - padding-bottom: 20px; - } - &__link { - color: $white; - font-size: $medium; - font-weight: $max-bold; - border-bottom: 4px solid $yellow; - margin-bottom: 0; - text-align: right; - - &:hover { - text-decoration: none; - color: $white; - } - } -} - -@media screen and (min-width: 992px) { - .EdtechCards { - padding: 33px 30px 65px 30px; - &__mainTitle { - display: flex; - flex-direction: column; - align-items: center; - flex-wrap: wrap; - - h1, - h2, - h3, - h4, - h5, - h6, - p, - span { - font-size: $extra-large; - text-align: left; - } - h1, - h2, - h3, - h4, - h5, - h6, - p { - width: 80%; - } - } - &__card { - border-bottom: 4px solid $yellow; - } - - &__link { - font-size: $medium; - padding-left: 0; - padding-right: 0; - text-align: left; - align-self: flex-end; - } - } -} - -@media screen and (min-width: 1400px) { - .EdtechCards { - padding: 65px 147px 65px 114px; - &__mainTitle { - align-items: center; - padding-left: 50px; - h1, - h2, - h3, - h4, - h5, - h6, - p span { - font-size: $extra-large; - text-align: left; - } - h1, - h2, - h3, - h4, - h5, - h6, - p { - width: 70%; - } - } - - &__title { - font-size: $large; - } - &__intro { - font-size: $medium; - padding-bottom: 40px; - } - &__link { - font-size: $large; - align-self: flex-end; - text-align: center; - &:hover { - text-decoration: none; - color: $white; - } - } - } -} diff --git a/src/components/EdTechPage/EdTechContainer.js b/src/components/EdTechPage/EdTechContainer.js deleted file mode 100644 index fcc0031d..00000000 --- a/src/components/EdTechPage/EdTechContainer.js +++ /dev/null @@ -1,47 +0,0 @@ -import * as React from "react" -import { useEdTech } from "../../hooks" -import { BannerTop, BannerActionCall, Seo } from "../index" -import Layout from "../layout" - -import Cards from "../Cards/Cards" -import "./EdtechContainer.scss" - -const EdTech = () => { - const data = useEdTech() - - const edTechs = data?.allStrapiEdteches?.nodes - - const content = edTechs.map(tech => ) - - const bannerTop = data?.allStrapiEdTechPage?.nodes[0].topBanner - const bannerActionCall = data?.allStrapiEdTechPage?.nodes[0].actionCallBanner - - const { - pageTitle, - pageDescription, - pageKeywords, - } = data?.allStrapiEdTechPage?.nodes[0].seo - - return ( - - {data?.allStrapiEdTechPage?.nodes[0].seo && ( - - )} - {bannerTop && ( - - )} - {content.length > 0 && ( -
{content}
- )} - {bannerActionCall && ( - - )} -
- ) -} - -export default EdTech diff --git a/src/components/EdTechPage/EdtechContainer.scss b/src/components/EdTechPage/EdtechContainer.scss deleted file mode 100644 index 31ca9ea7..00000000 --- a/src/components/EdTechPage/EdtechContainer.scss +++ /dev/null @@ -1,8 +0,0 @@ -@import "../../styles/global.scss"; - -.EdTech { - &__container { - background-color: $primary-container; - margin-bottom: 95px; - } -} \ No newline at end of file diff --git a/src/components/Hero/Hero.js b/src/components/Hero/Hero.js index 550b2ac8..49a4abb8 100644 --- a/src/components/Hero/Hero.js +++ b/src/components/Hero/Hero.js @@ -1,41 +1,53 @@ -import React from 'react'; -import './Hero.scss'; +import React from "react" +import "./Hero.scss" export default function Hero({ data }) { - const richText = data.title - const image = data.image.url - - const regexTitle = /(# )(.*)/g; + const title = data.title; + const richList = data.listAnimation; + const image = data.image.url; + console.log(richList, "lista") const regexList = /(- )(.*)/g; //Parametros en la funcion y validar el richText q acepte mas q h1 const processRichText = () => { - const processTitle = richText.match(regexTitle)[0].slice(2) - const processList = richText.match(regexList).map(e => e.slice(2)) + const processList = richList?.match(regexList)?.map(e => e.slice(2)); + return [processList]; - return [processTitle, processList] } - var [title, listOfWords] = processRichText() + + let [listOfWords] = processRichText(); return ( <> -
- - - -
-

{title}

-

-
    - {listOfWords.map(word =>
  • {word}
  • )} -
-

+
+
+
+ +
+
+

{title}

+ {listOfWords && ( +
+
    + {listOfWords.map(word =>
  • {word}
  • )}; +
+
+ )} + +
+ {data.button && ( + + )}
diff --git a/src/components/Hero/Hero.scss b/src/components/Hero/Hero.scss index ba7a571e..4c67d1f8 100644 --- a/src/components/Hero/Hero.scss +++ b/src/components/Hero/Hero.scss @@ -8,22 +8,22 @@ margin-top: 0; } 25% { - margin-top: -40px; + margin-top: -45px; } 40% { - margin-top: -40px; + margin-top: -45px; } 50% { - margin-top: -80px; + margin-top: -90px; } 65% { - margin-top: -80px; + margin-top: -90px; } 75% { - margin-top: -40px; + margin-top: -45px; } 85% { - margin-top: -40px; + margin-top: -45px; } 100% { margin-top: 0; @@ -38,22 +38,22 @@ margin-top: 0; } 25% { - margin-top: -40px; + margin-top: -45px; } 40% { - margin-top: -40px; + margin-top: -45px; } 50% { - margin-top: -80px; + margin-top: -90px; } 65% { - margin-top: -80px; + margin-top: -90px; } 75% { - margin-top: -40px; + margin-top: -45px; } 85% { - margin-top: -40px; + margin-top: -45px; } 100% { margin-top: 0; @@ -74,10 +74,10 @@ margin-top: -65px; } 50% { - margin-top: -120px; + margin-top: -130px; } 65% { - margin-top: -120px; + margin-top: -130px; } 75% { margin-top: -65px; @@ -121,78 +121,88 @@ } .hero { + /* background-image: url("../../images/Group.png"); + background-repeat: no-repeat; + background-position: center; + background-size: cover; + min-height: 700px; */ - &.container { - padding: 50px 0px; - width: 100%; - - .gatsby-image-wrapper { - display: block; + button { + @include primaryBtn; + margin-left: 150px; + } + + .gatsby-image-wrapper { + display: block; + } + + .content-text { + line-height: 45px; + height: 45px; + color: #333; + margin: 40px 0px; + + .visible { + overflow: hidden; + height: 45px; } - - .content-text { - line-height: 40px; - height: 40px; - color: #333; - margin-top: 40px; - width: 100%; - - .visible { - font-weight: 600; - overflow: hidden; - height: 40px; - width: 100%; - } - - h2 { - font-size: 30px; + + h1 { + margin: 0; + } + + ul { + margin-top: 0; + text-align: left; + list-style: none; + animation: 6s linear 0s normal none infinite change; + -webkit-animation: 6s linear 0s normal none infinite change; + -moz-animation: 6s linear 0s normal none infinite change; + -o-animation: 6s linear 0s normal none infinite change; + + li { + line-height: 45px; margin: 0; - text-align: center; - } - - ul { - margin-top: 0; - text-align: left; - list-style: none; - animation: 6s linear 0s normal none infinite change; - -webkit-animation: 6s linear 0s normal none infinite change; - -moz-animation: 6s linear 0s normal none infinite change; - -o-animation: 6s linear 0s normal none infinite change; - - li { - line-height: 40px; - margin: 0; - color: #1ecad3; - text-align: center; - font-size: 30px; - - &:first-child { - color: lime !important; - padding-bottom: 3px; - } - - &:last-child { - color: #ff0 !important; - } + color: #8afe71; + font-size: 40px; + padding-left: 20px; + font-weight: $max-bold; + + &:first-child { + color: #e8809a !important; + } + + &:last-child { + color: #d047fa !important; } } } - } + } } + //estilos de 768 para arriba @media screen and (min-width: $breakpoint-md) { - .container { + .hero { + img { + height: 580px; + width: 600px; + margin-top: 50px; + } + } +} + +@media screen and (min-width: $breakpoint-lg) { + .hero { .content-text { line-height: 65px; height: 65px; - margin: 0; + margin-left: 100px; - .visible{ - height: 65px; + h1 { + margin-left: 100px; } - - h2 { - font-size: $extra-large; + .visible { + height: 65px; } ul { animation: 6s linear 0s normal none infinite changeDesktop; @@ -201,10 +211,16 @@ -o-animation: 6s linear 0s normal none infinite changeDesktop; li { - font-size: $extra-large; + font-size: 69px; line-height: 65px; } } } + &__button { + margin-top: -20px; + } + &__image { + padding-left: 100px; + } } } diff --git a/src/components/HomePage/HomeContainer/HomeContainer.js b/src/components/HomePage/HomeContainer/HomeContainer.js index b9bd9bb2..323b55a8 100644 --- a/src/components/HomePage/HomeContainer/HomeContainer.js +++ b/src/components/HomePage/HomeContainer/HomeContainer.js @@ -22,13 +22,13 @@ const bodyComponents = { "home.dual-section": data => , } -const Home = () => { +const Home = ({ location }) => { const data = useHomePage() const { pageTitle, pageDescription, pageKeywords } = data?.allStrapiHome?.nodes[0]?.pageMetadata || {} return ( - + {data?.allStrapiHome?.nodes[0]?.pageMetadata && ( { + // falta definir los titulos para cada componente y arreglar los vinculos internos + const titleReference = { + "home.hero": () => component.title, + "components.banner-list": () => component.title, + "components.selected-grid": () => component.title, + "components.cases-section": () => component.title, + "home.quote": () => component.title, + "home.video-background": () => component.title, + "home.dual-section": () => + component.dualSectionPart.map(section => section.title).join(" - "), + } + return ( + (titleReference[component.strapi_component] && + titleReference[component.strapi_component]()) || + "Titulo no definido" + ) +} + +const AnimatedNavbar = ({ + homeComponents, + landingComponents, + navbarItems, + duration, +}) => { + const navbarConfig = [ + { + title: "Home", + slug: "", + dropdown: () => ( + component.strapi_component !== "home.transition" + ) + .map(component => ({ + name: getComponentTitle(component), + id: component.strapi_component + "-" + component.id, + }))} + /> + ), + }, + ...navbarItems.map(navItem => { + if (navItem.landing) { + return { + title: navItem.label, + slug: navItem.landing.slug, + dropdown: () => ( + landing.name === navItem.landing.name) + .body.map(component => ({ + name: getComponentTitle(component), + id: component.strapi_component + "-" + component.id, + slug: navItem.landing.slug, + }))} + /> + ), + } + } else if (navItem.url) { + return { + title: navItem.label, + slug: navItem.url, + dropdown: () => , + } + } + }), + { + title: "Blog", + slug: "blog", + dropdown: () => , + }, + ] + + const [activeIndex, setActiveIndex] = useState([]) + const [animationOut, setAnimationOut] = useState(null) + + const [animatingOutTimeout, setAnimatingOutTimeout] = useState(null) + + const resetDropdownState = i => { + setActiveIndex(typeof i === "number" ? [i] : []) + setAnimationOut(false) + + setAnimatingOutTimeout(null) + } + + const onMouseEnter = i => { + if (animatingOutTimeout) { + clearTimeout(animatingOutTimeout) + resetDropdownState(i) + return + } + if (activeIndex[activeIndex.length - 1] === i) return + + setActiveIndex(prev => prev.concat(i)) + setAnimationOut(false) + } + + const onMouseLeave = () => { + setAnimationOut(true) + setAnimatingOutTimeout(setTimeout(resetDropdownState, duration)) + } + + let CurrentDropdown + let PrevDropdown + let direction + + const currentIndex = activeIndex[activeIndex.length - 1] + const prevIndex = + activeIndex.length > 1 && activeIndex[activeIndex.length - 2] + + if (typeof currentIndex === "number") + CurrentDropdown = navbarConfig[currentIndex].dropdown + if (typeof prevIndex === "number") { + PrevDropdown = navbarConfig[prevIndex].dropdown + direction = currentIndex > prevIndex ? "right" : "left" + } + + return ( + + + {navbarConfig.map((n, index) => { + return ( + + {currentIndex === index && ( + + + {PrevDropdown && } + + )} + + ) + })} + + + ) +} + +export default AnimatedNavbar diff --git a/src/components/NavBar/AnimatedNavBar/DropdownContainer/Dropdown.js b/src/components/NavBar/AnimatedNavBar/DropdownContainer/Dropdown.js new file mode 100644 index 00000000..9dd947ce --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/DropdownContainer/Dropdown.js @@ -0,0 +1,28 @@ +import { Link } from "gatsby" +import React from "react" +import "./dropdown.scss" + +const Dropdown = ({ sections }) => { + return ( +
+
+
    + {sections && + sections.map(section => ( +

    + + {section.name} + +

    + ))} +
+
+
+ ) +} + +export default Dropdown diff --git a/src/components/NavBar/AnimatedNavBar/DropdownContainer/FadeContents.js b/src/components/NavBar/AnimatedNavBar/DropdownContainer/FadeContents.js new file mode 100644 index 00000000..e88496df --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/DropdownContainer/FadeContents.js @@ -0,0 +1,30 @@ +import React, { forwardRef } from "react" +import PropTypes from "prop-types" + +const FadeContents = forwardRef( + ({ children, animatingOut, direction }, ref) => ( + + ) +) + +const propTypes = { + duration: PropTypes.number, + direction: PropTypes.oneOf(["right", "left"]), + animatingOut: PropTypes.bool, + children: PropTypes.node, +} + +FadeContents.propTypes = propTypes + +export default FadeContents diff --git a/src/components/NavBar/AnimatedNavBar/DropdownContainer/dropdown.scss b/src/components/NavBar/AnimatedNavBar/DropdownContainer/dropdown.scss new file mode 100644 index 00000000..8194ea43 --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/DropdownContainer/dropdown.scss @@ -0,0 +1,110 @@ +.dropdown { + &_elem { + width: 18.5rem; + &-section { + padding: 28px; + position: relative; + z-index: 10; + } + &-link { + font-size: 18px; + margin-top: 0; + margin-bottom: 1rem; + &-inner{ + color: black; + } + } + } +} + +.promote_layer { + will-change: transform; +} + +.fade_content { + @extend .promote_layer; + animation-duration: 300ms; + animation-fill-mode: forwards; + top: 0; + left: 0; +} + +@keyframes fade-forward { + to { + transform: translateX(0px); + opacity: 1; + } +} + +@keyframes fade-backward { + to { + transform: translateX(0px); + opacity: 0; + } +} + +.dropdown_root { + transform-origin: 0 0; + @extend .promote_layer; + animation-duration: 300ms; + animation-fill-mode: forwards; + display: flex; + flex-direction: column; + align-items: center; + position: relative; + top: -20px; + &-background { + transform-origin: 0 0; + background-color: white; + border-radius: 4px; + overflow: hidden; + position: relative; + box-shadow: 0 50px 100px rgba(50, 50, 93, 0.1); + margin-top: 10px; + @extend .promote_layer; + &-alt { + background-color: #f1f4f8b0; + width: 300%; + height: 100%; + position: absolute; + top: 0; + left: -100%; + transform-origin: 0 0; + z-index: 0; + transition: transform 300ms; + } + } + &-inverted { + @extend .promote_layer; + top: 0; + left: 0; + &:first-of-type { + z-index: 1; + } + &:not(:first-of-type) { + z-index: -1; + } + } +} + +@keyframes dropdown_root-forward { + from { + transform: rotateX(-15deg); + opacity: 0; + } + to { + transform: rotateX(0); + opacity: 1; + } +} + +@keyframes dropdown_root-backward { + from { + transform: rotateX(0); + opacity: 1; + } + to { + transform: rotateX(-15deg); + opacity: 0; + } +} diff --git a/src/components/NavBar/AnimatedNavBar/DropdownContainer/index.js b/src/components/NavBar/AnimatedNavBar/DropdownContainer/index.js new file mode 100644 index 00000000..1244240b --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/DropdownContainer/index.js @@ -0,0 +1,125 @@ +import React, { Component, Children, createRef } from "react" +import PropTypes from "prop-types" +import { Flipped } from "react-flip-toolkit" +import FadeContents from "./FadeContents" + +const getFirstDropdownSectionHeight = el => { + if ( + !el || + !el.querySelector || + !el.querySelector("*[data-first-dropdown-section]") + ) + return 0 + return el.querySelector("*[data-first-dropdown-section]").offsetHeight +} + +const updateAltBackground = ({ + altBackground, + prevDropdown, + currentDropdown, +}) => { + const prevHeight = getFirstDropdownSectionHeight(prevDropdown) + const currentHeight = getFirstDropdownSectionHeight(currentDropdown) + + const immediateSetTranslateY = (el, translateY) => { + el.style.transform = `translateY(${translateY}px)` + el.style.transition = "transform 0s" + requestAnimationFrame(() => (el.style.transitionDuration = "")) + } + + if (prevHeight) { + // transition the grey ("alt") background from its previous height to its current height + immediateSetTranslateY(altBackground, prevHeight) + requestAnimationFrame(() => { + altBackground.style.transform = `translateY(${currentHeight}px)` + }) + } else { + // just immediately set the background to the appropriate height + // since we don't have a stored value + immediateSetTranslateY(altBackground, currentHeight) + } +} + +class DropdownContainer extends Component { + static propTypes = { + children: PropTypes.node.isRequired, + animatingOut: PropTypes.bool, + direction: PropTypes.oneOf(["left", "right"]), + duration: PropTypes.number, + } + + currentDropdownEl = createRef() + prevDropdownEl = createRef() + + componentDidMount() { + updateAltBackground({ + altBackground: this.altBackgroundEl, + prevDropdown: this.prevDropdownEl.current, + currentDropdown: this.currentDropdownEl.current, + duration: this.props.duration, + }) + } + + render() { + const { children, direction, animatingOut, duration } = this.props + const [currentDropdown, prevDropdown] = Children.toArray(children) + return ( +
+ +
+ + +
+ +
+
(this.altBackgroundEl = el)} + duration={duration} + /> + + {currentDropdown} + +
+ + + +
+ {prevDropdown && ( + + {prevDropdown} + + )} +
+
+
+
+
+ ) + } +} + +export default DropdownContainer diff --git a/src/components/NavBar/AnimatedNavBar/Navbar/NavbarItem.js b/src/components/NavBar/AnimatedNavBar/Navbar/NavbarItem.js new file mode 100644 index 00000000..aee1aba2 --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/Navbar/NavbarItem.js @@ -0,0 +1,26 @@ +import { Link } from "gatsby" +import React from "react" +import "./navbarItems.scss" + +const NavbarItem = ({ title, children, index, to, ...props }) => { + const onMouseEnter = () => { + props.onMouseEnter(index) + } + return ( +
  • + + {title} + +
    {children}
    +
  • + ) +} +export default NavbarItem diff --git a/src/components/NavBar/AnimatedNavBar/Navbar/index.js b/src/components/NavBar/AnimatedNavBar/Navbar/index.js new file mode 100644 index 00000000..92513b6d --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/Navbar/index.js @@ -0,0 +1,11 @@ +import React from "react" + +const Navbar = ({ children, onMouseLeave }) => { + return ( + + ) +} + +export default Navbar diff --git a/src/components/NavBar/AnimatedNavBar/Navbar/navbarItems.scss b/src/components/NavBar/AnimatedNavBar/Navbar/navbarItems.scss new file mode 100644 index 00000000..01b0f34c --- /dev/null +++ b/src/components/NavBar/AnimatedNavBar/Navbar/navbarItems.scss @@ -0,0 +1,39 @@ +.navbar { + &-el { + margin: auto; + } + &-list { + display: flex; + justify-content: center; + list-style: none; + margin: 0; + } + &_item { + position: relative; + &-title { + background: transparent; + border: 0; + font-size: 18px; + padding: 2rem 1.5rem 1.2rem 1.5rem; + color: #1F1D37; + display: flex; + justify-content: center; + transition: opacity 250ms; + cursor: pointer; + /* position above the dropdown, otherwise the dropdown will cover up the bottom sliver of the buttons */ + position: relative; + z-index: 2; + &:hover, + &:focus { + opacity: 0.7; + outline: none; + } + } + &-dropdown_container { + position: absolute; + left: 50%; + transform: translateX(-50%); + perspective: 1500px; + } + } +} diff --git a/src/components/NavBar/NavBar.scss b/src/components/NavBar/NavBar.scss index 4bd51d78..b606dfb4 100644 --- a/src/components/NavBar/NavBar.scss +++ b/src/components/NavBar/NavBar.scss @@ -1,7 +1,7 @@ @import "../../styles/global.scss"; .NavBar { - background-color: $nav-footer-container; + background-color: white; } .NavBar__Logo { margin: 16px 28px; @@ -25,8 +25,7 @@ .NavBar__Link { text-decoration: none; text-transform: uppercase; - color: #fff; - font-family: Roboto; + color: #1F1D37; font-size: 14px; font-style: normal; font-weight: 700; @@ -36,41 +35,77 @@ } .NavBar__Link:hover { text-decoration: none; - color: #1ecad3; + color: #3f6BE8; } .NavBar__Link--active { text-decoration: none; - color: #1ecad3; + color: #3f6BE8; } - +.NavBar_Side{ + display: flex; + flex-direction: row; + align-items: center; + justify-content: space-around; + &-contact { + box-shadow: 0px 2px 10px #3f6be880; + padding: .6em; + background-color: #3F6BE8; + color: white; + border: 1px solid #3F6BE8; + border-radius: 4px; + &:hover{ + background-color: white; + color: #3F6BE8; + } + } + p { + color: #1F1D37; + margin: 0 3em; + } +} @media screen and (min-width: 992px) { + .NavBar{ + display: flex; + flex-direction: row; + & > a { + flex-basis: 30%; + } + } .NavBar__Logo { width: 143px; margin-left: 58px; } .NavBar__Collapse { /* DESKTOP */ - justify-content: flex-end; + justify-content: space-around; + align-items: center; } .NavBar__List { margin-top: 0rem; } .NavBar__Item { margin-right: 2.5rem; + margin-top: .5em; + } + .NavBar_Side{ + justify-content: unset; } + } + .theme-toggle{ background: none; border: none; + height: 54px; + width: 54px; + position: relative; img { - margin: 0; - } - &-sun{ - filter: invert(100%); + color: white; + margin: 0 0 3px 0; } } \ No newline at end of file diff --git a/src/components/NavBar/Navbar.js b/src/components/NavBar/Navbar.js index 94777c38..61c1aa15 100644 --- a/src/components/NavBar/Navbar.js +++ b/src/components/NavBar/Navbar.js @@ -1,14 +1,24 @@ import React from "react" +import "./NavBar.scss" +import { Link } from "gatsby" import Navbar from "react-bootstrap/Navbar" -import { MenuLinks } from "../../constants" +import AnimatedNavbar from "./AnimatedNavBar/AnimatedNavbar" + +import { useNavbar } from "../../hooks/index" + +// default logo import logoLight from "../../images/tipologo-azul.png" -import { Link } from "gatsby" -import "./NavBar.scss" +import { useTheme } from "../../context/themeContext" +// theme images +import moon from "../../images/moon-solid.svg" +import sun from "../../images/sun.svg" const NavBar = () => { + const { theme, toggleTheme } = useTheme() + const navbarData = useNavbar() return ( <> - + { /> {/* Menu Links */} - + {navbarData && ( + + )} +
    + +

    ES

    + +
    diff --git a/src/components/Pagination/Pagination.scss b/src/components/Pagination/Pagination.scss index 230a597d..2140b7b6 100644 --- a/src/components/Pagination/Pagination.scss +++ b/src/components/Pagination/Pagination.scss @@ -18,7 +18,7 @@ } &__link { font-weight: $bold; - color: $blue; + color: $primary; padding: 0.2rem; &:hover { @@ -28,5 +28,5 @@ } } .active-page { - border-bottom: 5px $yellow solid; -} \ No newline at end of file + border-bottom: 5px $alt solid; +} diff --git a/src/components/PartnersSection/PartnersSection.js b/src/components/PartnersSection/PartnersSection.js deleted file mode 100644 index 60cca6b8..00000000 --- a/src/components/PartnersSection/PartnersSection.js +++ /dev/null @@ -1,29 +0,0 @@ -import "./PartnersSection.scss" -import React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image" -import { useTheme } from "../../context/themeContext" - -const PartnersSection = ({ title, partners }) => { - const { theme } = useTheme() - - const partnerList = partners.map(partner => { - const partnerImage = getImage(partner?.image?.localFile) - const imagenDM = getImage(partner?.imageDark?.localFile) - return ( -
    - -
    - ) - }) - return ( -
    -

    {title}

    -
    {partnerList}
    -
    - ) -} - -export default PartnersSection diff --git a/src/components/PartnersSection/PartnersSection.scss b/src/components/PartnersSection/PartnersSection.scss deleted file mode 100644 index 12138b92..00000000 --- a/src/components/PartnersSection/PartnersSection.scss +++ /dev/null @@ -1,50 +0,0 @@ -@import "../../styles/global.scss"; - -.partners { - background-color: $primary-container; - padding: 30px; - &__title { - color: $blue; - font-size: $large; - font-weight: $bold; - border-bottom: 4px solid $yellow; - padding-bottom: 15px; - text-align: center; - width: fit-content; - margin: 0 auto; - } - &__logos { - margin-top: 10px; - margin-bottom: 20px; - display: flex; - flex-direction: column; - align-items: center; - } - &__image { - margin-top: 15px; - max-width: 220px; - } -} - -@media screen and (min-width: $breakpoint-md) { - .partners { - padding: 70px; - &__logos { - margin: 30px 0; - flex-direction: row; - flex-wrap: wrap; - justify-content: center; - } - &__image { - margin: 10px 10px 0 10px; - } - } -} - -@media screen and (min-width: 992px) { - .partners { - &__title { - font-size: $extra-large; - } - } -} \ No newline at end of file diff --git a/src/components/ServiceCards/ServiceCards.js b/src/components/ServiceCards/ServiceCards.js deleted file mode 100644 index abd7def7..00000000 --- a/src/components/ServiceCards/ServiceCards.js +++ /dev/null @@ -1,57 +0,0 @@ -import React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image" -import { Link } from "gatsby" -import showdown from "showdown" -import "./ServiceCards.scss" -import { useTheme } from "../../context/themeContext" - -const ServiceCards = ({ title, services }) => { - const { theme } = useTheme() - - const titles = title - let converter = new showdown.Converter() - let post = titles - let html = converter.makeHtml(post) - - const ReplaceHtml = () => { - return { __html: html } - } - - const servicios = services?.map((service, idx) => ( -
    -
    - {" "} -
    -
    -

    {service.homeTitle}

    -

    {service.homeIntro}

    -
    - - - Ver más - -
    - )) - .slice(0, 3) - - return ( - <> -
    -
    -
    -
    -
    - {servicios} -
    -
    - - ) -} - -export default ServiceCards diff --git a/src/components/ServiceCards/ServiceCards.scss b/src/components/ServiceCards/ServiceCards.scss deleted file mode 100644 index 6c36837e..00000000 --- a/src/components/ServiceCards/ServiceCards.scss +++ /dev/null @@ -1,111 +0,0 @@ -@import "../../styles/global.scss"; - -.ServiceCards { - display: flex; - flex-direction: column; - align-items: center; - justify-content: space-between; - padding-bottom: 55px; - background-color: $primary-container; - &__container { - padding: 1.5rem; - } - - &__mainTitle { - text-align: center; - margin-top: 54px; - display: flex; - flex-wrap: wrap; - align-items: center; - max-width: 600px; - h1, - h2, - h3, - h4, - h5, - h6, - p, - span { - font-size: $large; - font-weight: $extra-bold; - color: $blue; - margin-bottom: 30px; - } - span { - -webkit-text-stroke: 2px $blue; - -webkit-text-fill-color: $primary-container; - } - } - &__card { - background-color: rgba(255, 255, 255, 0.075); - color: $primary; - @extend %border-shadowed; - padding: 30px 30px 16px; - margin: 0 35px 30px; - display: flex; - flex-direction: column; - align-items: center; - justify-content: space-between; - } - &__image { - margin-bottom: 27px; - } - &__textContainer { - display: flex; - flex-direction: column; - align-items: center; - justify-content: center; - } - &__title { - font-size: $medium; - font-weight: $max-bold; - text-align: center; - max-width: 200px; - margin-bottom: 10px; - } - &__intro { - font-size: $small; - font-weight: $normal; - text-align: center; - } - &__link { - color: $blue; - font-size: $medium; - font-weight: $max-bold; - border-bottom: 4px solid $yellow; - margin-bottom: 0; - &:hover { - text-decoration: none; - color: $blue; - } - } -} - -@media (min-width: $breakpoint-lg) { - .ServiceCards { - &__mainTitle { - h1, - h2, - h3, - h4, - h5, - h6, - p, - span { - font-size: $extra-large; - } - } - - &__intro { - font-size: $medium; - } - - &__link { - font-size: $large; - } - - &__title { - font-size: $large; - } - } -} diff --git a/src/components/ServicesPage/ServiceCard.js b/src/components/ServicesPage/ServiceCard.js deleted file mode 100644 index 2faf121e..00000000 --- a/src/components/ServicesPage/ServiceCard.js +++ /dev/null @@ -1,29 +0,0 @@ -import React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image" -import Markdown from "react-markdown" -import { useTheme } from "../../context/themeContext" - -const ServiceCard = ({ service }) => { - const { theme } = useTheme() - - const icon = getImage(service?.icon?.localFile) - const iconDark = getImage(service?.iconDarkMode?.localFile) - - return ( -
    -
    -
    - -
    -
    -
    -
    {service.title}
    -
    - {service.description} -
    -
    -
    - ) -} - -export default ServiceCard diff --git a/src/components/ServicesPage/ServicesSection.js b/src/components/ServicesPage/ServicesSection.js deleted file mode 100644 index 5142552f..00000000 --- a/src/components/ServicesPage/ServicesSection.js +++ /dev/null @@ -1,48 +0,0 @@ -import React from "react" -import { useServices, useServicePage } from "../../hooks" -import Layout from "../layout" -import { BannerTop, BannerActionCall, ServiceCard, Seo } from "../index" - -import "./ServicesSection.scss" - -const ServicesSection = () => { - const servicesData = useServices() - - const servicesPageData = useServicePage() - - const servicesList = servicesData?.allStrapiServices?.nodes - - const servicesToDisplay = servicesList?.map(service => ( - - )) - - const bannerTop = servicesPageData?.strapiServicesPage?.topBanner - const bannerActionCall = servicesPageData?.strapiServicesPage?.actionCallBanner - - const { - pageDescription, - pageKeywords, - pageTitle, - } = servicesData?.allStrapiServicesPage?.nodes[0]?.seo - - return ( - - {servicesData?.allStrapiServicesPage?.nodes[0]?.seo && ( - - )} - {bannerTop && } - {servicesToDisplay.length > 0 && ( -
    -
    {servicesToDisplay}
    -
    - )} - {bannerActionCall && } -
    - ) -} - -export default ServicesSection diff --git a/src/components/ServicesPage/ServicesSection.scss b/src/components/ServicesPage/ServicesSection.scss deleted file mode 100644 index 3ebe085b..00000000 --- a/src/components/ServicesPage/ServicesSection.scss +++ /dev/null @@ -1,50 +0,0 @@ -@import "../../styles/global.scss"; - -.servicesSection { - background-color: $primary-container; - padding-top: 70px; -} - -.serviceCard { - &__description { - p { - color: $primary; - font-size: $small; - text-align: justify; - margin-bottom: 10px; - } - } - &__icon { - margin: 30px auto; - width: 100px; - } - &__title { - color: $primary; - font-weight: $bold; - font-size: $medium; - margin-bottom: 25px; - } - &__block { - @extend %border-shadowed; - background-color: rgba(255, 255, 255, 0.055); - padding: 40px; - margin-bottom: 45px; - } -} - -@media (min-width: $breakpoint-md) { - .serviceCard { - &__description { - p { - font-size: $medium; - } - } - &__title { - font-size: $large; - } - &__icon { - margin: 30px auto 0; - width: 100px; - } - } -} diff --git a/src/components/SubModulesEdTech/SubModulesEdTech.js b/src/components/SubModulesEdTech/SubModulesEdTech.js deleted file mode 100644 index 468dd6c6..00000000 --- a/src/components/SubModulesEdTech/SubModulesEdTech.js +++ /dev/null @@ -1,43 +0,0 @@ -import React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image" -import { useEdTechSubmodules } from "../../hooks/index" -import { SubModuleItems } from "../index" -import "./SubmodulesEdTech.scss" -import { useTheme } from "../../context/themeContext" - -const SubModulesEdTech = ({ items, variant }) => { - const data = useEdTechSubmodules() - const { theme } = useTheme() - const submodules = data?.submodules?.nodes - - const custom = submodules.find(art => art.strapiId === items.id) - const { submodule, submoduleItem, title } = custom - const { description, logo, logoDarkMode, id } = submodule - - const logoLight = getImage(logo?.localFile) - const logoDark = getImage(logoDarkMode?.localFile) - - // const logoSubmodule = logo && logoDarkMode ( - // - // ) - - const classVariant = variant && `${variant}` - - return ( -
    -
    - -
    -
    -

    {submodule.title}

    -

    {description}

    -
    - -
    - ) -} - -export default SubModulesEdTech diff --git a/src/components/SubModulesEdTech/SubmodulesEdTech.scss b/src/components/SubModulesEdTech/SubmodulesEdTech.scss deleted file mode 100644 index ecdea6bc..00000000 --- a/src/components/SubModulesEdTech/SubmodulesEdTech.scss +++ /dev/null @@ -1,56 +0,0 @@ -@import "../../styles/global.scss"; - -.Submodules { - border-top: solid 4px #1ecad3; - padding: 30px 0 10px 0; - - &__text { - padding-left: 0; - h4 { - margin-bottom: 0; - } - p { - text-align: justify; - margin-top: 20px; - } - } - &__image { - padding-left: 5px; - padding-right: 5px; - } -} - - -@media screen and (min-width: $breakpoint-md) { - .Submodules { - &__image { - padding-left: 30px; - } - } -} - -@media screen and (min-width: 992px) { - .Submodules { - padding: 65px 0 50px 0; - &:first-child { - margin-top: 65px; - } - &:last-child { - border-bottom: solid 4px #1ecad3; - } - - &__text { - h4 { - font-size: $large; - line-height: 25px; - } - p { - font-size: $medium; - } - } - &__image { - transform: translateX(20%); - - } - } -} diff --git a/src/components/SubmoduleItems/SubModuleItem.scss b/src/components/SubmoduleItems/SubModuleItem.scss deleted file mode 100644 index 1bc5b4bd..00000000 --- a/src/components/SubmoduleItems/SubModuleItem.scss +++ /dev/null @@ -1,54 +0,0 @@ -@import "../../styles/global.scss"; - -.SubmoduleItem { - padding: 30px 0 10px 10px; - - &__text { - padding-left: 0; - h4 { - margin-bottom: 0; - } - p { - text-align: justify; - margin-top: 20px; - } - } - &__image { - padding-left: 5px; - padding-right: 5px; - - img { - width: 50px; - height: 50px; - } - } -} - -@media screen and (min-width: $breakpoint-md) { - .SubmoduleItem { - &__image { - padding-left: 20px; - } - } -} - -@media screen and (min-width: 992px) { - .SubmoduleItem { - &__image { - padding-left: 5px; - padding-right: 5px; - display: flex; - justify-content: center; - - img { - width: 60px; - height: 60px; - } - } - &__text { - h4 { - font-size: $medium; - } - } - } -} diff --git a/src/components/SubmoduleItems/SubmoduleItems.js b/src/components/SubmoduleItems/SubmoduleItems.js deleted file mode 100644 index c70e8b63..00000000 --- a/src/components/SubmoduleItems/SubmoduleItems.js +++ /dev/null @@ -1,30 +0,0 @@ -import React from "react" -import { getImage, GatsbyImage } from "gatsby-plugin-image" -import "./SubModuleItem.scss" -import { useTheme } from "../../context/themeContext" - -const SubModuleItems = ({ items }) => { - const { theme } = useTheme() - - const submoduleItem = items?.map(item => ( -
    -
    - -
    -
    -

    {item.title}

    -

    {item.content}

    -
    -
    - )) - - return
    {submoduleItem}
    -} -export default SubModuleItems diff --git a/src/components/Title/Title.js b/src/components/Title/Title.js deleted file mode 100644 index a5d57804..00000000 --- a/src/components/Title/Title.js +++ /dev/null @@ -1,17 +0,0 @@ -import React from 'react' - -const Title = (text, fragment) => { - return ( -

    - {text} - {fragment && ( - - {fragment} - - )} - -

    - ) -} - -export default Title diff --git a/src/components/animatedTransitionContinous/AnimatedTransitionContinous.js b/src/components/animatedTransitionContinous/AnimatedTransitionContinous.js index 4ee0dc82..78fae5da 100644 --- a/src/components/animatedTransitionContinous/AnimatedTransitionContinous.js +++ b/src/components/animatedTransitionContinous/AnimatedTransitionContinous.js @@ -1,11 +1,11 @@ -import React from "react"; -import "./animatedTransitionContinous.scss"; +import React from "react" +import "./animatedTransitionContinous.scss" const AnimatedTransitionContinous = ({ children }) => { - let longerText = ""; + let longerText = "" while (longerText.length < 200) { - longerText = children + " - " + longerText; + longerText = children + " - " + longerText } return ( @@ -16,7 +16,7 @@ const AnimatedTransitionContinous = ({ children }) => {
    - ); -}; + ) +} -export default AnimatedTransitionContinous; +export default AnimatedTransitionContinous diff --git a/src/components/expandGrid/ExpandGrid.js b/src/components/expandGrid/ExpandGrid.js index 8606d84c..b3d709ad 100644 --- a/src/components/expandGrid/ExpandGrid.js +++ b/src/components/expandGrid/ExpandGrid.js @@ -1,16 +1,19 @@ -import React, { Component, useRef, useState } from "react" +import React, { useRef, useState } from "react" import { Flipper, Flipped } from "react-flip-toolkit" +import MarkdownView from "react-showdown" import "./expandGrid.scss" const ExpandGrid = ({ data }) => { return ( -
    -
    -

    {data.title}

    -

    {data.subtitle}

    - -
    -
    +
    +
    +
    +

    {data.title}

    +
    {data.subtitle}
    + +
    +
    +
    ) } @@ -35,11 +38,7 @@ const ListItem = ({ index, onClick, data }) => { shouldFlip={shouldFlip(index)} delayUntil={createCardFlipId(index)} > - +
    @@ -48,11 +47,9 @@ const ListItem = ({ index, onClick, data }) => { ) } -const ExpandedListItem = ({ index, onClick, data }) => { +const ExpandedListItem = ({ index, onClick, data, scrollToRef }) => { const scrollRef = useRef(null) - const scrollToRef = ref => window.scrollTo(0, ref.current.offsetTop - 40) - return ( { el.classList.add("animated-in") }, 400) }} - onExit={() => scrollToRef(scrollRef)} >
    { stagger="card-image" delayUntil={createCardFlipId(index)} > - +
    -

    {data.text}

    +
    @@ -100,9 +92,16 @@ const ExpandedListItem = ({ index, onClick, data }) => { const AnimatedList = ({ items }) => { const [focused, setFocused] = useState(null) + const scrollRef = useRef(null) const onClick = index => { setFocused(focused === index ? null : index) + if (focused !== null) { + scrollToRef(scrollRef) + } } + + const scrollToRef = ref => window.scrollTo(0, ref.current.offsetTop - 40) + return ( { }, }} decisionData={focused} + > -
      +
        {items.map((item, index) => { return ( <> @@ -124,6 +124,7 @@ const AnimatedList = ({ items }) => { index={focused} onClick={onClick} data={item} + scrollToRef={scrollToRef} /> ) : ( { +const Layout = ({ children, options = {}, location }) => { const defaultOptions = { hasHeader: true, hasFooter: true, @@ -29,6 +29,17 @@ const Layout = ({ children, options = {} }) => { ) : null ) ) + + React.useEffect(() => { + const hash = location?.state?.component + console.log(hash) + let el = hash && document.getElementById(hash) + console.log(el) + if (el) { + el.scrollIntoView({ behavior: "smooth" }) + } + }, [location?.state?.component]) + return ( {scripts} diff --git a/src/components/layout.scss b/src/components/layout.scss index c9fb3389..d05d6baa 100644 --- a/src/components/layout.scss +++ b/src/components/layout.scss @@ -1,5 +1,4 @@ @import "../styles/global.scss"; -@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"); html { -ms-text-size-adjust: 100%; -webkit-text-size-adjust: 100%; @@ -12,7 +11,6 @@ body { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; color: #2a2c2e; - font-family: "Roboto", sans-serif; font-weight: normal; word-wrap: break-word; font-kerning: normal; @@ -83,19 +81,14 @@ h1 { padding-top: 0; margin-bottom: 1.45rem; color: inherit; - font-family: "Roboto", sans-serif; font-weight: bold; text-rendering: optimizeLegibility; - font-size: 2.25rem; line-height: 1.1; } mark { background-color: #ff0; color: #000; } -small { - font-size: 80%; -} sub, sup { font-size: 75%; @@ -119,7 +112,6 @@ img { padding-left: 0; padding-right: 0; padding-top: 0; - margin-bottom: 1.45rem; } svg:not(:root) { overflow: hidden; @@ -128,7 +120,6 @@ code, kbd, pre, samp { - font-family: "Roboto", sans-serif; font-size: 1em; } figure { @@ -261,10 +252,8 @@ h2 { padding-top: 0; margin-bottom: 1.45rem; color: inherit; - font-family: "Roboto", sans-serif; font-weight: bold; text-rendering: optimizeLegibility; - font-size: 1.62671rem; line-height: 1.1; } h3 { @@ -277,10 +266,8 @@ h3 { padding-top: 0; margin-bottom: 1.45rem; color: inherit; - font-family: "Roboto", sans-serif; font-weight: bold; text-rendering: optimizeLegibility; - font-size: 1.38316rem; line-height: 1.1; } h4 { @@ -293,10 +280,8 @@ h4 { padding-top: 0; margin-bottom: 1.45rem; color: inherit; - font-family: "Roboto", sans-serif; font-weight: bold; text-rendering: optimizeLegibility; - font-size: 1rem; line-height: 1.1; } h5 { @@ -307,12 +292,9 @@ h5 { padding-left: 0; padding-right: 0; padding-top: 0; - margin-bottom: 1.45rem; color: inherit; - font-family: "Roboto", sans-serif; font-weight: bold; text-rendering: optimizeLegibility; - font-size: 0.85028rem; line-height: 1.1; } h6 { @@ -325,10 +307,8 @@ h6 { padding-top: 0; margin-bottom: 1.45rem; color: inherit; - font-family: "Roboto", sans-serif; font-weight: bold; text-rendering: optimizeLegibility; - font-size: 0.78405rem; line-height: 1.1; } hgroup { @@ -417,7 +397,6 @@ table { padding-right: 0; padding-top: 0; margin-bottom: 1.45rem; - font-size: 1rem; line-height: 1.45rem; border-collapse: collapse; width: 100%; @@ -563,7 +542,6 @@ tt, code { background-color: hsla(0, 0%, 0%, 0.04); border-radius: 3px; - font-family: "Roboto", sans-serif; padding: 0; padding-top: 0.2em; padding-bottom: 0.2em; diff --git a/src/components/quote/Quote.js b/src/components/quote/Quote.js index 7a63ed47..daf5ad3d 100644 --- a/src/components/quote/Quote.js +++ b/src/components/quote/Quote.js @@ -2,9 +2,10 @@ import "./quote.scss" import React from "react" -const Quote = ({ data: { description, title, variant, profile, image } }) => { +const Quote = ({ data: { description, title, variant, profile, image, strapi_component, id } }) => { return ( -
        +
        +
        {
        -

        {title}

        +

        {title}

        {description}

        @@ -26,6 +27,7 @@ const Quote = ({ data: { description, title, variant, profile, image } }) => { />
        +
    ) } diff --git a/src/components/quote/quote.scss b/src/components/quote/quote.scss index 7100cda9..3f195b88 100644 --- a/src/components/quote/quote.scss +++ b/src/components/quote/quote.scss @@ -2,9 +2,7 @@ .quote { display: grid; - padding: 0 4em; gap: 3em; - margin-bottom: 3em; &-body { grid-area: quote-body; @@ -16,15 +14,16 @@ } &-person { + padding-top: 1em; grid-area: quote-person; display: flex; flex-direction: column; &-title { - font-size: 3em; - margin-bottom: 0.3em; + margin-bottom: 1.5em; + font-weight: 700; } &-text { - font-size: 1em; + font-weight: 700; } @keyframes move-shadow { 0% { diff --git a/src/components/videoBackground/VideoBackground.js b/src/components/videoBackground/VideoBackground.js index 1bb67f07..010f9190 100644 --- a/src/components/videoBackground/VideoBackground.js +++ b/src/components/videoBackground/VideoBackground.js @@ -1,6 +1,8 @@ import React, { useEffect, useRef, useState } from "react" import "./videoBackground.scss" -const VideoBackground = ({ data: { video, description, button } }) => { +const VideoBackground = ({ + data: { video, description, button, strapi_component, id }, +}) => { const [isVideoPause, setIsVideoPause] = useState(false) const videoRef = useRef(null) @@ -13,43 +15,46 @@ const VideoBackground = ({ data: { video, description, button } }) => { setIsVideoPause(prev => !prev) } - useEffect(() => { - - const isVideoPauseLocal = typeof window !== 'undefined' ? localStorage.getItem('videoPaused') : undefined + const isVideoPauseLocal = + typeof window !== "undefined" + ? localStorage.getItem("videoPaused") + : undefined if (isVideoPauseLocal === "true") { - console.log(isVideoPauseLocal) - console.log("video pausado localmente") videoRef.current.pause() setIsVideoPause(isVideoPauseLocal) } }, []) useEffect(() => { - localStorage.setItem('videoPaused', isVideoPause) + localStorage.setItem("videoPaused", isVideoPause) }, [isVideoPause]) - return ( -
    -
    +
    +
    +
    +
    ) } diff --git a/src/components/videoBackground/videoBackground.scss b/src/components/videoBackground/videoBackground.scss index aa61f43a..a402db93 100644 --- a/src/components/videoBackground/videoBackground.scss +++ b/src/components/videoBackground/videoBackground.scss @@ -1,9 +1,12 @@ +@import "../../styles/global.scss"; + .videoBackground { - width: 100%; - height: 90vh; + // width: calc(100% - 6em); + height: 80vh; position: relative; z-index: 3; display: flex; + // margin: 3em; video { top: 0; position: absolute; @@ -12,8 +15,8 @@ object-fit: cover; z-index: -1; cursor: pointer; + // border-radius: 20px; } - &-card { z-index: 4; align-self: flex-end; @@ -22,16 +25,28 @@ backdrop-filter: blur(14px); color: white; border-radius: 5px; - background: #ffffff4f; + background: #e8e8e8c5; box-shadow: 0px 0px 3px #00000044; margin: 1em; - padding: 1em; + padding: 2em; + h4 { + color: $grey; + } button { - background: none; + background: $grey; border: 1px solid white; color: white; + font-weight: 500; border-radius: 3px; - padding: 0.3em; + padding: .6em 3em; + } + } +} + +@media screen and (min-width: $breakpoint-md) { + .videoBackground { + video { + border-radius: 20px; } } } diff --git a/src/constants/MenuLinks/MenuLinks.js b/src/constants/MenuLinks/MenuLinks.js deleted file mode 100644 index 753a6d4d..00000000 --- a/src/constants/MenuLinks/MenuLinks.js +++ /dev/null @@ -1,57 +0,0 @@ -import React from "react" -import { Link } from "gatsby" -import Nav from "react-bootstrap/Nav" -import { useTheme } from "../../context/themeContext" - -import moon from "../../images/moon-solid.svg" -import sun from "../../images/sun-icon-1.png" - -const MENU_LINKS = [ - { id: 1, text: "home", url: "/" }, - { id: 2, text: "servicios", url: "/servicios" }, -] - -const MenuLinks = ({ styleClass }) => { - const { theme, toggleTheme } = useTheme() - - return ( - - ) -} - -export default MenuLinks diff --git a/src/constants/index.js b/src/constants/index.js index bfaf145d..8b137891 100644 --- a/src/constants/index.js +++ b/src/constants/index.js @@ -1,4 +1 @@ -import MenuLinks from "./MenuLinks/MenuLinks" - -export { MenuLinks } diff --git a/src/hooks/index.js b/src/hooks/index.js index a1422cfa..4fc6a2d4 100644 --- a/src/hooks/index.js +++ b/src/hooks/index.js @@ -1,25 +1,13 @@ -import useServices from "./useServices" -import useBanner from "./useBanner" -import useEdTech from "./useEdTech" -import useEdTechSubmodules from "./useEdTechSubmodules" import useGlobalSeo from "./useGlobalSeo" import useHomePage from "./useHomePage" -import useContactPage from "./useContactPage" import useBlog from './useBlog' -import useJobsPage from "./useJobsPage" -import useServicePage from "./useServicePage" import useFooter from './useFooter'; +import useNavbar from './useNavbar'; export { - useServices, - useBanner, - useEdTech, - useEdTechSubmodules, useGlobalSeo, useHomePage, - useContactPage, useBlog, - useJobsPage, - useServicePage, - useFooter + useFooter, + useNavbar } diff --git a/src/hooks/useBanner.js b/src/hooks/useBanner.js deleted file mode 100644 index 5d015993..00000000 --- a/src/hooks/useBanner.js +++ /dev/null @@ -1,60 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useBanner = () => { - const query = useStaticQuery(graphql` - { - allStrapiBanners { - nodes { - title - strapiId - page - type - image { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - imageDarkMode { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - logoDarkMode { - localFile { - childImageSharp { - gatsbyImageData( - quality: 100 - formats: [AUTO, WEBP] - placeholder: BLURRED - ) - } - } - } - logo { - localFile { - childImageSharp { - gatsbyImageData( - quality: 100 - formats: [AUTO, WEBP] - placeholder: BLURRED - ) - } - } - } - link { - name - pathTo - } - summary - } - } - } - `) - return query -} - -export default useBanner diff --git a/src/hooks/useBitwayPage.js b/src/hooks/useBitwayPage.js deleted file mode 100755 index c203a9c3..00000000 --- a/src/hooks/useBitwayPage.js +++ /dev/null @@ -1,64 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby"; - -const useBitwayPage = () => { - const query = useStaticQuery(graphql` - { - allStrapiBitwayPage { - nodes { - SEO { - pageDescription - pageTitle - pageKeywords - } - actionCallBanner { - title - image { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - imageDarkMode { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - link { - name - pathTo - } - } - sections { - body - id - type - galleryImage { - caption - text - id - image { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - imageDark { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - } - } - } - } - } - `); - return query; -}; -export default useBitwayPage; diff --git a/src/hooks/useContactPage.js b/src/hooks/useContactPage.js deleted file mode 100644 index 8a996a93..00000000 --- a/src/hooks/useContactPage.js +++ /dev/null @@ -1,32 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useContactPage = () => { - const query = useStaticQuery(graphql` - { - allStrapiContactPage { - nodes { - pageMetadata { - pageDescription - pageKeywords - pageTitle - } - image { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - title - contactForm { - portalId - formId - } - } - } - } - `) - return query -} - -export default useContactPage diff --git a/src/hooks/useEdTech.js b/src/hooks/useEdTech.js deleted file mode 100644 index f8540b25..00000000 --- a/src/hooks/useEdTech.js +++ /dev/null @@ -1,91 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useEdTech = () => { - const query = useStaticQuery(graphql` - { - allStrapiEdTechPage { - nodes { - topBanner { - title - summary - bgImageDarkMode { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - bgImage { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - } - actionCallBanner { - title - link { - name - pathTo - } - imageDarkMode { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - image { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - } - } - } - allStrapiEdteches(sort: { fields: id, order: ASC }) { - nodes { - id - title - content - icon { - localFile { - childImageSharp { - gatsbyImageData(height: 100, quality: 100) - } - } - } - iconDarkMode { - localFile { - childImageSharp { - gatsbyImageData(height: 100, quality: 100) - } - } - } - edTechSubmodules { - ed_tech_submodules { - id - title - edTechType - } - } - } - } - allStrapiEdTechPage { - nodes { - seo: SEO { - pageDescription - pageKeywords - pageTitle - } - } - } - } - `) - return query -} - -export default useEdTech diff --git a/src/hooks/useEdTechSubmodules.js b/src/hooks/useEdTechSubmodules.js deleted file mode 100644 index 28d062a2..00000000 --- a/src/hooks/useEdTechSubmodules.js +++ /dev/null @@ -1,56 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useEdTechSubmodules = () => { - const query = useStaticQuery(graphql` - { - submodules: allStrapiEdTechSubmodules { - nodes { - id - strapiId - title - edTechType - submodule { - description - title - logo { - localFile { - childImageSharp { - gatsbyImageData(width: 60, quality: 100) - } - } - } - logoDarkMode { - localFile { - childImageSharp { - gatsbyImageData(width: 60, quality: 100) - } - } - } - } - submoduleItem { - title - id - content - icon { - localFile { - childImageSharp { - gatsbyImageData(width: 60, quality: 100) - } - } - } - iconDarkMode { - localFile { - childImageSharp { - gatsbyImageData(width: 60, quality: 100) - } - } - } - } - } - } - } - `) - return query -} - -export default useEdTechSubmodules diff --git a/src/hooks/useJobsPage.js b/src/hooks/useJobsPage.js deleted file mode 100644 index be3bd342..00000000 --- a/src/hooks/useJobsPage.js +++ /dev/null @@ -1,20 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useJobsPage = () => { - const query = useStaticQuery(graphql` - { - strapiJobsPage { - title - pageMetadata { - pageDescription - pageKeywords - pageTitle - } - } - } - - `) - return query -} - -export default useJobsPage diff --git a/src/hooks/useNavbar.js b/src/hooks/useNavbar.js new file mode 100644 index 00000000..3b3b5bf2 --- /dev/null +++ b/src/hooks/useNavbar.js @@ -0,0 +1,45 @@ +import { useStaticQuery, graphql } from "gatsby" + +const useNavbar = () => { + return useStaticQuery(graphql` + { + allStrapiLayout { + nodes { + navbar { + navbarItem { + url + label + landing { + slug + name + } + dropdown + id + } + logo { + localFile { + childImageSharp { + gatsbyImageData + } + } + } + } + } + } + allStrapiLandingPage { + nodes { + body + name + } + } + allStrapiHome { + nodes { + body + } + } + } + + `) +} + +export default useNavbar diff --git a/src/hooks/useServicePage.js b/src/hooks/useServicePage.js deleted file mode 100644 index 7ac3ad33..00000000 --- a/src/hooks/useServicePage.js +++ /dev/null @@ -1,58 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useServicePage = () => { - const query = useStaticQuery(graphql` - { - strapiServicesPage { - topBanner { - title - summary - bgImageDarkMode { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - bgImage { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - } - actionCallBanner { - title - link { - name - pathTo - } - imageDarkMode { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - image { - localFile { - childImageSharp { - gatsbyImageData - } - } - } - } - pageMetadata { - pageDescription - pageKeywords - pageTitle - } - - } - } - `) - return query -} - -export default useServicePage diff --git a/src/hooks/useServices.js b/src/hooks/useServices.js deleted file mode 100644 index 8ad460d7..00000000 --- a/src/hooks/useServices.js +++ /dev/null @@ -1,41 +0,0 @@ -import { useStaticQuery, graphql } from "gatsby" - -const useServices = () => { - const query = useStaticQuery(graphql` - { - allStrapiServicesPage { - nodes { - seo: pageMetadata { - pageDescription - pageKeywords - pageTitle - } - } - } - allStrapiServices(filter: { visible: { eq: true } }) { - nodes { - description - title - id - icon { - localFile { - childImageSharp { - gatsbyImageData(width: 150, quality: 100) - } - } - } - iconDarkMode { - localFile { - childImageSharp { - gatsbyImageData(width: 150, quality: 100) - } - } - } - } - } - } - `) - return query -} - -export default useServices diff --git a/src/images/Group.png b/src/images/Group.png new file mode 100644 index 00000000..f4eab2e5 Binary files /dev/null and b/src/images/Group.png differ diff --git a/src/images/moon-solid.svg b/src/images/moon-solid.svg index e687fb82..f12006da 100644 --- a/src/images/moon-solid.svg +++ b/src/images/moon-solid.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/src/images/sun.svg b/src/images/sun.svg new file mode 100644 index 00000000..da13b76c --- /dev/null +++ b/src/images/sun.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/pages/bitway.js b/src/pages/bitway.js deleted file mode 100644 index 015407ee..00000000 --- a/src/pages/bitway.js +++ /dev/null @@ -1,6 +0,0 @@ -import React from "react" -import BitwayPage from "../components/BitwayPage/BitwayContainer" - -const Bitway = () => - -export default Bitway diff --git a/src/pages/contacto.js b/src/pages/contacto.js deleted file mode 100644 index 4ff712a5..00000000 --- a/src/pages/contacto.js +++ /dev/null @@ -1,6 +0,0 @@ -import React from "react" -import ContactPage from "../components/ContactPage/ContactContainer" - -const Contact = () => - -export default Contact diff --git a/src/pages/edtech.js b/src/pages/edtech.js deleted file mode 100644 index 76be041a..00000000 --- a/src/pages/edtech.js +++ /dev/null @@ -1,6 +0,0 @@ -import React from "react" -import EdTechPage from "../components/EdTechPage/EdTechContainer" - -const EdTech = () => - -export default EdTech diff --git a/src/pages/index.js b/src/pages/index.js index 66798168..4e7bf076 100644 --- a/src/pages/index.js +++ b/src/pages/index.js @@ -2,6 +2,6 @@ import * as React from "react" import "bootstrap/dist/css/bootstrap.min.css" import Home from "./../components/HomePage/HomeContainer/HomeContainer" -const IndexPage = () => +const IndexPage = ({location}) => export default IndexPage diff --git a/src/pages/jobs.js b/src/pages/jobs.js deleted file mode 100644 index 54baac6b..00000000 --- a/src/pages/jobs.js +++ /dev/null @@ -1,6 +0,0 @@ -import React from "react" -import {JobsPage} from "../components" - -const Jobs = () => - -export default Jobs \ No newline at end of file diff --git a/src/pages/servicios.js b/src/pages/servicios.js deleted file mode 100644 index d0711517..00000000 --- a/src/pages/servicios.js +++ /dev/null @@ -1,6 +0,0 @@ -import React from "react" -import ServicesSection from "../components/ServicesPage/ServicesSection" - -const Services = () => - -export default Services diff --git a/src/schema/blogSchema.js b/src/schema/blogSchema.js new file mode 100644 index 00000000..6c8558f1 --- /dev/null +++ b/src/schema/blogSchema.js @@ -0,0 +1,473 @@ +const blogSchema = ` +type StrapiBlogCategory implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + name: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + articles: [StrapiBlogCategoryArticles] + strapiId: Int + article: [StrapiBlogCategoryArticle] + } + + type StrapiBlogCategoryArticle { + id: Int + title: String + description: String + summary: String + slug: String + blog_category: Int + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + author: [StrapiBlogCategoryArticleAuthor] + image: LocalFile + } + + type StrapiBlogCategoryArticleAuthor { + id: Int + name: String + summary: String + subTitle: String + image: LocalFile + } + + type StrapiBlogCategoryArticleAuthorImage { + id: Int + name: String + width: Int + height: Int + formats: StrapiBlogCategoryArticleAuthorImageFormats + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiBlogCategoryArticleAuthorImageFormats { + thumbnail: StrapiBlogCategoryArticleAuthorImageFormatsThumbnail + large: StrapiBlogCategoryArticleAuthorImageFormatsLarge + medium: StrapiBlogCategoryArticleAuthorImageFormatsMedium + small: StrapiBlogCategoryArticleAuthorImageFormatsSmall + } + + type StrapiBlogCategoryArticleAuthorImageFormatsThumbnail { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleAuthorImageFormatsLarge { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleAuthorImageFormatsMedium { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleAuthorImageFormatsSmall { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleImage { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + formats: StrapiBlogCategoryArticleImageFormats + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiBlogCategoryArticleImageFormats { + thumbnail: StrapiBlogCategoryArticleImageFormatsThumbnail + large: StrapiBlogCategoryArticleImageFormatsLarge + medium: StrapiBlogCategoryArticleImageFormatsMedium + small: StrapiBlogCategoryArticleImageFormatsSmall + } + + type StrapiBlogCategoryArticleImageFormatsThumbnail { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleImageFormatsLarge { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleImageFormatsMedium { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticleImageFormatsSmall { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiBlogCategoryArticles { + id: Int + title: String + description: String + summary: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + image: LocalFile + slug: String + } + + type StrapiArticle implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + title: String + description: String + summary: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + image: LocalFile + blog_categories: [StrapiArticleBlog_categories] + strapiId: Int + slug: String + blog_category: StrapiArticleBlog_category + author: [StrapiArticleAuthor] + } + + type StrapiArticleBlog_category { + id: Int + name: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + } + + type StrapiArticleAuthor { + id: Int + name: String + summary: String + subTitle: String + image: LocalFile + } + + type StrapiArticleAuthorImage { + id: Int + name: String + width: Int + height: Int + formats: StrapiArticleAuthorImageFormats + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiArticleAuthorImageFormats { + thumbnail: StrapiArticleAuthorImageFormatsThumbnail + large: StrapiArticleAuthorImageFormatsLarge + medium: StrapiArticleAuthorImageFormatsMedium + small: StrapiArticleAuthorImageFormatsSmall + } + + type StrapiArticleAuthorImageFormatsThumbnail { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiArticleAuthorImageFormatsLarge { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiArticleAuthorImageFormatsMedium { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiArticleAuthorImageFormatsSmall { + name: String + hash: String + ext: String + mime: String + width: Int + height: Int + size: Float + url: String + } + + type StrapiArticleBlog_categories { + id: Int + name: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + } + + type StrapiBlogPage implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + pageMetadata: StrapiBlogPagePageMetadata + strapiId: Int + title: String + actionCallBanner: StrapiBlogPageActionCallBanner + } + + type StrapiBlogPageActionCallBanner { + id: Int + title: String + link: StrapiBlogPageActionCallBannerLink + image: LocalFile + imageDarkMode: LocalFile + } + + type StrapiBlogPageActionCallBannerLink { + id: Int + name: String + pathTo: String + } + + type StrapiBlogPagePageMetadata { + id: Int + pageTitle: String + pageDescription: String + pageKeywords: String + } + +` + +module.exports = { + value: blogSchema, +} diff --git a/src/schema/caseSchema.js b/src/schema/caseSchema.js new file mode 100644 index 00000000..d165fdc5 --- /dev/null +++ b/src/schema/caseSchema.js @@ -0,0 +1,267 @@ +const caseSchema = ` + +type StrapiCase implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + title: String + description: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + button: StrapiCaseButton + quote: StrapiCaseQuote + image: StrapiCaseImage + strapiId: Int + } + + type StrapiCaseButton { + id: Int + content: String + url: String + landing_page: StrapiCaseButtonLanding_page + } + + type StrapiCaseButtonLanding_page { + id: Int + name: String + slug: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + } + + type StrapiCaseQuote { + id: Int + title: String + description: String + variant: String + profile: StrapiCaseQuoteProfile + image: StrapiCaseQuoteImage + } + + type StrapiCaseQuoteProfile { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + formats: StrapiCaseQuoteProfileFormats + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + + # Returns the difference between this date and the current time. Defaults to "milliseconds" but you can also pass in as the measurement "years", "months", "weeks", "days", "hours", "minutes", and "seconds". + difference: String + + # Configures the locale Moment.js will use to format the date. + locale: String + ): Date + localFile: File + } + + type StrapiCaseQuoteProfileFormats { + thumbnail: StrapiCaseQuoteProfileFormatsThumbnail + } + + type StrapiCaseQuoteProfileFormatsThumbnail { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } + + type StrapiCaseQuoteImage { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + formats: StrapiCaseQuoteImageFormats + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + + # Returns the difference between this date and the current time. Defaults to "milliseconds" but you can also pass in as the measurement "years", "months", "weeks", "days", "hours", "minutes", and "seconds". + difference: String + + # Configures the locale Moment.js will use to format the date. + locale: String + ): Date + localFile: File + } + + type StrapiCaseQuoteImageFormats { + small: StrapiCaseQuoteImageFormatsSmall + thumbnail: StrapiCaseQuoteImageFormatsThumbnail + } + + type StrapiCaseQuoteImageFormatsSmall { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } + + type StrapiCaseQuoteImageFormatsThumbnail { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } + + type StrapiCaseImage { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + formats: StrapiCaseImageFormats + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + + # Configures the locale Moment.js will use to format the date. + locale: String + ): Date + localFile: File + } + + type StrapiCaseImageFormats { + small: StrapiCaseImageFormatsSmall + thumbnail: StrapiCaseImageFormatsThumbnail + large: StrapiCaseImageFormatsLarge + medium: StrapiCaseImageFormatsMedium + } + + type StrapiCaseImageFormatsSmall { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } + + type StrapiCaseImageFormatsThumbnail { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } + + type StrapiCaseImageFormatsLarge { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } + + type StrapiCaseImageFormatsMedium { + ext: String + url: String + hash: String + mime: String + name: String + size: Float + width: Int + height: Int + } +` + +module.exports = { + value: caseSchema, +} diff --git a/src/schema/generalSchema.js b/src/schema/generalSchema.js new file mode 100644 index 00000000..107bed9b --- /dev/null +++ b/src/schema/generalSchema.js @@ -0,0 +1,34 @@ +const generalSchema = ` +type LocalFile { + localFile: File + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + formats: StrapiBlogCategoryArticleAuthorImageFormats + } +` + +module.exports = { + value: generalSchema, +} diff --git a/src/schema/globalSeoSchema.js b/src/schema/globalSeoSchema.js new file mode 100644 index 00000000..074c4805 --- /dev/null +++ b/src/schema/globalSeoSchema.js @@ -0,0 +1,76 @@ +const globalSeoSchema = ` +type StrapiGlobalSeo implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + siteURL: String + robots: Boolean + author: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + siteMetadata: StrapiGlobalSeoSiteMetadata + strapiId: Int + } + + type StrapiGlobalSeoSiteMetadata { + id: Int + pageTitle: String + pageDescription: String + pageKeywords: String + } + + +type StrapiGlobalConfig implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + script: [StrapiGlobalConfigScript] + strapiId: Int + } + + type StrapiGlobalConfigScript { + id: Int + name: String + enable: Boolean + src: String + } +` +module.exports = { + value: globalSeoSchema, + } diff --git a/src/schema/homeSchema.js b/src/schema/homeSchema.js new file mode 100644 index 00000000..639f9557 --- /dev/null +++ b/src/schema/homeSchema.js @@ -0,0 +1,41 @@ +const homeSchema = ` + +type StrapiHome implements Node { + body: JSON + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + pageMetadata: StrapiHomePageMetadata + strapiId: Int + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + } + + type StrapiHomePageMetadata { + id: Int + pageTitle: String + pageDescription: String + pageKeywords: String + } + +` +module.exports = { + value: homeSchema, +} diff --git a/src/schema/iconSchema.js b/src/schema/iconSchema.js new file mode 100644 index 00000000..8c8f66d1 --- /dev/null +++ b/src/schema/iconSchema.js @@ -0,0 +1,67 @@ +const iconScheme = ` + +type StrapiIcon implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + name: String + code: String + type: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + + # Returns the difference between this date and the current time. Defaults to "milliseconds" but you can also pass in as the measurement "years", "months", "weeks", "days", "hours", "minutes", and "seconds". + difference: String + + # Configures the locale Moment.js will use to format the date. + locale: String + ): Date + icon: StrapiIconIcon + strapiId: Int + } + + type StrapiIconIcon { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } +` +module.exports = { + value: iconScheme, +} diff --git a/src/schema/landingSchema.js b/src/schema/landingSchema.js new file mode 100644 index 00000000..e472e4f3 --- /dev/null +++ b/src/schema/landingSchema.js @@ -0,0 +1,41 @@ +const landingSchema = ` +type StrapiLandingPage implements Node { + body: JSON + name: String + slug: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + strapiId: Int + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + seo: StrapiLandingPageSeo + } + + type StrapiLandingPageSeo { + id: Int + pageTitle: String + pageDescription: String + pageKeywords: String + } +` +module.exports = { + value: landingSchema, +} diff --git a/src/schema/layoutSchema.js b/src/schema/layoutSchema.js new file mode 100644 index 00000000..9e82bfae --- /dev/null +++ b/src/schema/layoutSchema.js @@ -0,0 +1,358 @@ +const layoutSchema = ` +type StrapiLayoutFooter { + id: Int + subscription: StrapiLayoutFooterSubscription + navegation: StrapiLayoutFooterNavegation + socialMedia: StrapiLayoutFooterSocialMedia + location: StrapiLayoutFooterLocation + contact: StrapiLayoutFooterContact + internalLink: StrapiLayoutFooterInternalLink + navbar: StrapiLayoutNavbar + logo: LocalFile + } + + type StrapiLayoutNavbar { + id: Int + navbarItem: [StrapiLayoutNavbarNavbarItem] + logo: StrapiLayoutNavbarLogo + } + + type StrapiLayoutNavbarNavbarItem { + id: Int + label: String + landing: StrapiLayoutNavbarNavbarItemLanding + url: String + visible: Boolean + dropdown: Boolean + } + + type StrapiLayoutNavbarNavbarItemLanding { + id: Int + name: String + slug: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + } + + type StrapiLayoutNavbarLogo { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiLayoutFooterSubscription { + id: Int + title: String + } + + type StrapiLayoutFooterNavegation { + id: Int + title: String + pageLink: [StrapiLayoutFooterNavegationPageLink] + } + + type StrapiLayoutFooterNavegationPageLink { + id: Int + name: String + pathTo: String + } + + type StrapiLayoutFooterSocialMedia { + id: Int + socialMedia: [StrapiLayoutFooterSocialMediaSocialMedia] + } + + type StrapiLayoutFooterSocialMediaSocialMedia { + id: Int + url: String + name: String + icon: StrapiLayoutFooterSocialMediaSocialMediaIcon + order: Int + } + + type StrapiLayoutFooterSocialMediaSocialMediaIcon { + id: Int + name: String + code: String + type: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + icon: StrapiLayoutFooterSocialMediaSocialMediaIconIcon + } + + type StrapiLayoutFooterSocialMediaSocialMediaIconIcon { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiLayoutFooterLocation { + id: Int + title: String + iconText: [StrapiLayoutFooterLocationIconText] + } + + type StrapiLayoutFooterLocationIconText { + id: Int + name: String + icon: StrapiLayoutFooterLocationIconTextIcon + } + + type StrapiLayoutFooterLocationIconTextIcon { + id: Int + name: String + code: String + type: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + icon: StrapiLayoutFooterLocationIconTextIconIcon + } + + type StrapiLayoutFooterLocationIconTextIconIcon { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at(fromNow: Boolean, difference: String, locale: String): Date + localFile: File + } + + type StrapiLayoutFooterContact { + id: Int + title: String + iconText: [StrapiLayoutFooterContactIconText] + } + + type StrapiLayoutFooterContactIconText { + id: Int + name: String + icon: StrapiLayoutFooterContactIconTextIcon + } + + type StrapiLayoutFooterContactIconTextIcon { + id: Int + name: String + code: String + type: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + icon: StrapiLayoutFooterContactIconTextIconIcon + } + + type StrapiLayoutFooterContactIconTextIconIcon { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiLayoutFooterInternalLink { + id: Int + name: String + pathTo: String + } + + type StrapiLayoutFooterLogo { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File + } + + type StrapiLayout implements Node { + id: ID! + parent: Node + children: [Node!]! + internal: Internal! + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + + # Returns the difference between this date and the current time. Defaults to "milliseconds" but you can also pass in as the measurement "years", "months", "weeks", "days", "hours", "minutes", and "seconds". + difference: String + locale: String + ): Date + footer: StrapiLayoutFooter + navbar: StrapiLayoutNavbar + strapiId: Int + } +` +module.exports = { + value: layoutSchema, +} diff --git a/src/schema/schema.js b/src/schema/schema.js index 072051c7..7527055e 100644 --- a/src/schema/schema.js +++ b/src/schema/schema.js @@ -1241,9 +1241,78 @@ type StrapiLayoutFooter { location: StrapiLayoutFooterLocation contact: StrapiLayoutFooterContact internalLink: StrapiLayoutFooterInternalLink + navbar: StrapiLayoutNavbar logo: LocalFile } + +type StrapiLayoutNavbar { + id: Int + navbarItem: [StrapiLayoutNavbarNavbarItem] + logo: StrapiLayoutNavbarLogo +} + +type StrapiLayoutNavbarNavbarItem { + id: Int + label: String + landing: StrapiLayoutNavbarNavbarItemLanding + url: String + visible: Boolean + dropdown: Boolean +} + +type StrapiLayoutNavbarNavbarItemLanding { + id: Int + name: String + slug: String + published_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date +} + +type StrapiLayoutNavbarLogo { + id: Int + name: String + alternativeText: String + caption: String + width: Int + height: Int + hash: String + ext: String + mime: String + size: Float + url: String + provider: String + created_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + updated_at( + formatString: String + fromNow: Boolean + difference: String + locale: String + ): Date + localFile: File +} + type StrapiLayoutFooterSubscription { id: Int title: String diff --git a/src/styles/global.scss b/src/styles/global.scss index 27f62369..8941cddb 100644 --- a/src/styles/global.scss +++ b/src/styles/global.scss @@ -1,6 +1,8 @@ /* Fonts */ -@import url("https://fonts.googleapis.com/css2?family=Roboto&display=swap"); -$primary-font: "Roboto", sans-serif; +@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap"); +@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"); +$primary-font: "Poppins", sans-serif; +$secondary-font: "Roboto", sans-serif; $medium: 20px; $nav-footer-container: var(--nav-footer-container); @@ -46,8 +48,12 @@ $white: #ffffff; $yellow: #ffe927; $blue: #1ecad3; $grey-light: #f5f5f5; - - +//new colors +$grey: #545468; +$light-grey: #c4c4c4; +$primary: #3f6be8; +$alt: #67f293; +$blackBit: #242424; /* Sizes */ $small: 15px; @@ -56,6 +62,122 @@ $large: 25px; $second-large: 40px; $extra-large: 45px; +//buttons +@mixin primaryBtn { + padding: 5px 15px; + font-weight: 500; + border: none; + background-color: $primary; + color: white; + border-radius: 5px; + &:hover { + background-color: #b2c4f6; + color: #3c6ed0; + box-shadow: 0px 3px 10px rgba(138, 254, 113, 0.5); + } + &:active { + background-color: #2a50bc; + color: white; + } + @media screen and (min-width: $breakpoint-lg) { + padding: 8px 30px; + } +} + +// new sizes +$breakpoint-sm: 576px; +$breakpoint-md: 768px; +$breakpoint-lg: 992px; +$breakpoint-xl: 1200px; +$breakpoint-xxl: 1400px; + +body { + font-size: 16px; + font-family: $secondary-font; + p { + em { + font-size: 16px; + font-family: $secondary-font; + } + font-size: 16px; + font-family: $secondary-font; + } + button { + font-size: 14px; + font-family: $primary-font; + } + h1 { + font-size: 40px; + font-family: $primary-font; + } + h2 { + font-size: 36px; + font-family: $primary-font; + } + h3 { + span { + font-size: 32px; + font-family: $primary-font; + } + font-size: 32px; + font-family: $primary-font; + } + h4 { + font-size: 28px; + font-family: $primary-font; + } + h5 { + font-size: 24px; + font-family: $primary-font; + } + h6 { + font-size: 18px; + font-family: $primary-font; + } + small { + font-size: 16px; + } +} + +@media screen and (min-width: $breakpoint-lg) { + body { + font-size: 18px; + p { + em { + font-size: 18px; + } + font-size: 18px; + } + h1 { + font-size: 69px; + } + h2 { + font-size: 53px; + } + h3 { + span { + font-size: 39px; + } + font-size: 39px; + } + h4 { + font-size: 31px; + } + h5 { + font-size: 25px; + } + h6 { + font-size: 20px; + } + small { + font-size: 16px; + } + button { + font-size: 16px; + } + } +} + /* Weights */ $normal: 400; $standard: 500; @@ -71,13 +193,7 @@ $bottom-yellow: 4px solid $yellow; border-radius: 18px; } -$breakpoint-sm: 576px; -$breakpoint-md: 768px; -$breakpoint-lg: 992px; -$breakpoint-xl: 1200px; -$breakpoint-xxl: 1400px; - -.notFoundPage{ +.notFoundPage { height: calc(100vh - 240px - 96px); display: flex; flex-direction: column; @@ -86,4 +202,4 @@ $breakpoint-xxl: 1400px; & h1 { font-size: 3em; } -} \ No newline at end of file +} diff --git a/src/templates/LandingPage.js b/src/templates/LandingPage.js index 8ea9938e..9ff371d5 100644 --- a/src/templates/LandingPage.js +++ b/src/templates/LandingPage.js @@ -1,16 +1,15 @@ import React from "react" import { graphql } from "gatsby" import Layout from "../components/layout" -import { Seo } from "../components/index.js" +import { Seo, CasesSection } from "../components/index.js" // componentes del body import Hero from "../components/Hero/Hero" import BannerList from '../components/BannerList/BannerLis'; import ExpandGrid from "../components/expandGrid/ExpandGrid" -const LandingPage = ({ data }) => { +const LandingPage = ({ data, location }) => { const pageData = data?.allStrapiLandingPage?.nodes[0] - const content = pageData.body.map((component, idx) => { const hero = component.strapi_component === "home.hero" ? @@ -25,12 +24,17 @@ const LandingPage = ({ data }) => { : null + const casesSection = component.strapi_component === "components.cases-section" ? + : + null + return (
    <> {component.strapi_component === "home.hero" && hero} {component.strapi_component === "components.banner-list" && bannerList} {component.strapi_component === "components.selected-grid" && expandGrid} + {component.strapi_component === "components.cases-section" && casesSection}
    ) @@ -38,7 +42,7 @@ const LandingPage = ({ data }) => { }) return ( - + {content}