-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from Johnnyrc26/dev
Dev
- Loading branch information
Showing
48 changed files
with
831 additions
and
217 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
@tailwind components; | ||
|
||
@layer components{ | ||
.banner { | ||
@apply relative w-11/12 h-72 bg-cover bg-center rounded-2xl mb-8 flex items-center justify-center; | ||
} | ||
|
||
.slogan { | ||
@apply text-white text-8xl font-righteous text-center; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import React, { useState, useEffect } from 'react' | ||
import './Banner.css' | ||
|
||
const images = [ | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_66279ece42df1d426737bec4_5cc313f9c3eb99cf60eb67e8a94be42a.jpeg', | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_65aed40342df1d6d4415da44_19770b5e4884921f123bf319c2f1859e.jpeg', | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_58d274e608b7895965756924_bb1b47809dec7adc33b5fe0988b50a95.jpeg', | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_5d4c24e342df1d1dfe508d54_d138aabc030e02abed40f3db7535cafb.jpeg' | ||
|
||
] | ||
|
||
const Banner = () => { | ||
const [currentImage, setCurrentImage] = useState(images[0]); | ||
|
||
useEffect(() => { | ||
const interval = setInterval(() => { | ||
setCurrentImage((prevImage) => { | ||
const currentIndex = images.indexOf(prevImage); | ||
const nextIndex = (currentIndex + 1) % images.length; | ||
return images[nextIndex]; | ||
}) | ||
}, 4000) | ||
|
||
return () => clearInterval(interval) | ||
}, []) | ||
|
||
return ( | ||
<div className="banner" style={{ backgroundImage: `url(${currentImage})` }}> | ||
<div className='slogan'>Viaja, descubre, quédate</div> | ||
</div> | ||
) | ||
} | ||
|
||
export default Banner |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
@tailwind components; | ||
@import url('https://fonts.googleapis.com/css2?family=Righteous&display=swap'); | ||
|
||
@tailwind components; | ||
|
||
|
||
@layer components { | ||
.topbar { | ||
@apply relative w-full h-96 bg-cover bg-center | ||
} | ||
|
||
.brand { | ||
@apply absolute top-14 left-14 transform -translate-y-1/2 text-white text-6xl font-righteous | ||
} | ||
|
||
.searchBar{ | ||
@apply flex items-center justify-center pr-0 pl-0 pt-52 | ||
} | ||
|
||
.search-form{ | ||
@apply p-4 space-x-1 rounded-3xl | ||
} | ||
|
||
.search-form input, | ||
.search-form button { | ||
@apply px-4 py-2 border rounded-md; | ||
@apply focus:outline-none focus:ring-2 focus:ring-blue-500; | ||
} | ||
|
||
.search-form input[type="text"], | ||
.search-form input[type="number"] { | ||
@apply flex-1; | ||
} | ||
|
||
.search-form input[type="date"] { | ||
@apply w-44; /* Ajusta el ancho de los campos de fecha */ | ||
} | ||
|
||
.search-form button { | ||
@apply bg-blue-500 text-white hover:bg-blue-600; | ||
} | ||
|
||
.search-form button:hover { | ||
@apply bg-blue-600; | ||
} | ||
|
||
|
||
.nav{ | ||
@apply absolute pt-32 right-14 transform -translate-y-1/2 text-white text-xl font-normal | ||
} | ||
|
||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
import React, { useState, useEffect } from 'react'; | ||
import './TopBarHome.css'; // Asegúrate de crear este archivo para los estilos | ||
|
||
const images = [ | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_5772758682c805563ef06b95_c24d3d8ec63a80d22111689096b41776.jpeg', | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_5772758682c805563ef06bac_67ba4d3908e4d28fc33333ef14da39e0.jpeg', | ||
'https://cdn.laguiavalentinaquintero.com/poi/Poi_5772758682c805563ef06ee1_6f5d6aef416a08633de792b9d89ee589.jpeg', | ||
'https://cdn.laguia.grupoapok.com/poi/Poi_5772758682c805563ef06e36_b8b1ea83cf1a628a7d6520e6ba11eab1.jpeg' | ||
|
||
]; | ||
|
||
const TopBarHome = () => { | ||
const [currentImage, setCurrentImage] = useState(images[0]); | ||
const [city, setCity] = useState(''); | ||
const [dates, setDates] = useState({ start: '', end: '' }); | ||
const [people, setPeople] = useState(''); | ||
|
||
useEffect(() => { | ||
const interval = setInterval(() => { | ||
setCurrentImage((prevImage) => { | ||
const currentIndex = images.indexOf(prevImage); | ||
const nextIndex = (currentIndex + 1) % images.length; | ||
return images[nextIndex]; | ||
}) | ||
}, 5000) | ||
|
||
return () => clearInterval(interval) | ||
}, []); | ||
|
||
const handleSearch = (e) => { | ||
e.preventDefault(); | ||
console.log('Searching for:', { city, dates, people }); | ||
}; | ||
|
||
return ( | ||
<div className="topbar" style={{ backgroundImage: `url(${currentImage})` }}> | ||
<div className="brand">KAU</div> | ||
<div className="nav"> | ||
<a href="/register">Registrarse |</a> | ||
<a href="/login"> Iniciar sesión |</a> | ||
<a href="/about"> Conócenos</a> | ||
</div> | ||
<div className='searchBar'> | ||
<form className="search-form" onSubmit={handleSearch}> | ||
<input | ||
type="text" | ||
placeholder="Ciudad" | ||
value={city} | ||
onChange={(e) => setCity(e.target.value)} | ||
/> | ||
<input | ||
type="date" | ||
value={dates.start} | ||
onChange={(e) => setDates((prevDates) => ({ ...prevDates, start: e.target.value }))} | ||
/> | ||
<input | ||
type="date" | ||
value={dates.end} | ||
onChange={(e) => setDates((prevDates) => ({ ...prevDates, end: e.target.value }))} | ||
/> | ||
<input | ||
type="number" | ||
placeholder="Número de personas" | ||
value={people} | ||
onChange={(e) => setPeople(e.target.value)} | ||
/> | ||
<button type="submit">Buscar</button> | ||
</form> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default TopBarHome |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.