This repository was archived by the owner on Jul 11, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 39
(Code-Dev).Esther Manrique, Veronica Bernardino, Dianyela Maldonado. #28
Open
DianyelaMaldonado
wants to merge
88
commits into
Laboratoria:master
Choose a base branch
from
DianyelaMaldonado:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
88 commits
Select commit
Hold shift + click to select a range
e006b7e
Cambios Esther
EstherManrique 6d9b8aa
guardando cambios dian
DianyelaMaldonado f63b0aa
Cambios Vero
verobega 9921c3c
Merge pull request #1 from DianyelaMaldonado/Esther-HU_1-T-2
EstherManrique 7739b35
Merge branch 'dianyela/-development' into Vero-H.U.1-T1
DianyelaMaldonado bfddeab
Merge pull request #2 from DianyelaMaldonado/Vero-H.U.1-T1
verobega 6bb4790
Merge branch 'dianyela/-development' into dian--HU_1--T3
verobega 6896d5f
Merge pull request #3 from DianyelaMaldonado/dian--HU_1--T3
DianyelaMaldonado ab9b8fc
changes were made in index.html nav was added with the content of tas…
DianyelaMaldonado 1772a99
Merge branch 'dian--HU_1--T3' of https://github.com/DianyelaMaldonado…
DianyelaMaldonado 18f7b94
merge everything
DianyelaMaldonado 66e8682
Merge pull request #4 from DianyelaMaldonado/dian--HU_1--T3
DianyelaMaldonado 7505222
Add complements colors at style.css and index.html
EstherManrique 0244826
Merge pull request #5 from DianyelaMaldonado/feature/newcolors
EstherManrique a249a5f
Add style at first mobile ok.
EstherManrique 5dabe31
Finished prototype at index.html and css.
EstherManrique 0a6cb77
Merge pull request #6 from DianyelaMaldonado/feature/newcolors
EstherManrique 8977edd
Added in index.js and added their respective id in index, html; Proof…
DianyelaMaldonado 37186e1
Merge branch 'dianyela/-development' into feature/prueba-register-fir…
DianyelaMaldonado d05cee9
Merge pull request #7 from DianyelaMaldonado/feature/prueba-register-…
DianyelaMaldonado 6565cc6
add files loginandexit.js register.js in to folder view, information …
DianyelaMaldonado 90fb702
Merge pull request #8 from DianyelaMaldonado/feature/prueba-register-…
DianyelaMaldonado c09422a
Add proof of concept unfinished
DianyelaMaldonado 1362a03
add more trials about SPA
DianyelaMaldonado f820e44
More changes about spa. All ok
DianyelaMaldonado 5ba2f14
changes were added in index.html index.js and style.css, the mobile n…
DianyelaMaldonado 4111c69
In index.js changes were added, the iteration that says you do not ha…
DianyelaMaldonado ac839fb
In index.html and style.css
DianyelaMaldonado e483196
In index.html he views on both desktop and mobile have been added in …
DianyelaMaldonado 763127c
Add changes index.html
DianyelaMaldonado 5d33905
They adjusted in index.js change regarding functionality. The desktop…
DianyelaMaldonado c27fd23
SPA and MVC ok
EstherManrique fbf95bc
localStorage function is ready at posts
verobega 3338740
added images
verobega 23977fa
Added the functionality to post an image in index.js. Comment functio…
DianyelaMaldonado a941c49
add in style.css new style to image post user
DianyelaMaldonado 07d7d88
add SPA's changes
DianyelaMaldonado d0e55cb
add changes in index.html index.js style.css new pictures add changes…
DianyelaMaldonado 2eab38d
Obtaining Persistence Data ok
DianyelaMaldonado 33443d3
added post's trials
verobega d2b2012
readPosts function works
verobega 9817c0e
added editPost function
verobega b0735ff
add render of view forum changes in index.html index.js and fuorum.js
DianyelaMaldonado ec7a1e5
add changes render view forum people
DianyelaMaldonado 184ec2b
Save Our life
EstherManrique 5919c2b
MVC and SPA ok
EstherManrique 15d7661
Add Changes Modules 010520
EstherManrique 1c0087a
Finished Project
EstherManrique 41963f4
Merge pull request #9 from DianyelaMaldonado/Ramita-Esther-29-04-20
EstherManrique 940b146
Last Version 1.0
EstherManrique d1f3e5c
Merge pull request #10 from DianyelaMaldonado/Ramita-Esther-29-04-20
EstherManrique 6c96d0c
Merge pull request #11 from DianyelaMaldonado/dianyela/-development
DianyelaMaldonado 0a5d73a
Add changes about almost finished
EstherManrique 49ffc44
Almost finished app 1.1
EstherManrique 4c177c3
Update Readme.md
DianyelaMaldonado a366f84
Update Readme.md
DianyelaMaldonado 3c92a1e
Update Readme.md
DianyelaMaldonado dd865ea
Update Readme.md
DianyelaMaldonado 38b401c
Update Readme.md
DianyelaMaldonado b6f9bd7
Update Readme.md
DianyelaMaldonado 7ee5f9d
Update Readme.md
DianyelaMaldonado 507cb0a
Update Readme.md
verobega ba54323
Update Readme.md
verobega c98e02f
Update Readme.md
verobega 0f40d83
Update Readme.md
verobega eb621c7
Update Readme.md
verobega 03b1601
Update Readme.md
verobega e6f9cbb
Update Readme.md
verobega 93a2f56
add changes about images
DianyelaMaldonado 18989ec
Add files via upload
verobega 86e4dc1
Update Readme.md
verobega fe3acba
Update Readme.md
verobega af5b8a7
Update Readme.md
verobega 561c871
Add files via upload
verobega f953a8f
Update Readme.md
verobega e3ce50e
Update Readme.md
verobega 565152b
changes about test
DianyelaMaldonado 3aedb9a
add changes in styles of comments of forum page
DianyelaMaldonado e7d8396
Update Readme.md
DianyelaMaldonado 7808ab7
add changes in styles responsive
DianyelaMaldonado b66c1ca
Merge branch 'dianyela/-development' into feature/copy-version-presen…
DianyelaMaldonado 855d314
Merge pull request #12 from DianyelaMaldonado/feature/copy-version-pr…
DianyelaMaldonado 72a6c86
Merge branch 'master' into feature/fixes-in-styles-new-dm
DianyelaMaldonado 7540bba
add changes in some styles
DianyelaMaldonado d6c94c6
Merge pull request #13 from DianyelaMaldonado/feature/fixes-in-styles…
DianyelaMaldonado 2b42911
Merge branch 'master' into feature/fixes-in-styles-new-dm
DianyelaMaldonado c34c6de
Merge pull request #14 from DianyelaMaldonado/feature/fixes-in-styles…
DianyelaMaldonado cd8782e
Merge pull request #15 from DianyelaMaldonado/dianyela/-development
DianyelaMaldonado File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or 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 |
|---|---|---|
|
|
@@ -33,4 +33,4 @@ | |
| "stylelint": "^10.1.0", | ||
| "stylelint-config-recommended": "^2.2.0" | ||
| } | ||
| } | ||
| } | ||
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.
This file contains hidden or 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,15 @@ | ||
| // Your web app's Firebase configuration | ||
| var firebaseConfig = { | ||
| apiKey: "AIzaSyCkfImtzIXqG7KbK3b6Tu3MABA91hPqdFA", | ||
| authDomain: "social-network-pruebas.firebaseapp.com", | ||
| databaseURL: "https://social-network-pruebas.firebaseio.com", | ||
| projectId: "social-network-pruebas", | ||
| storageBucket: "social-network-pruebas.appspot.com", | ||
| messagingSenderId: "327573056555", | ||
| appId: "1:327573056555:web:38bda7ccadbd1fb70c0e6e", | ||
| measurementId: "G-ZLRFD83MS0" | ||
| }; | ||
| // Initialize Firebase | ||
| firebase.initializeApp(firebaseConfig); | ||
| firebase.analytics(); | ||
| var db = firebase.firestore() |
This file was deleted.
Oops, something went wrong.
This file contains hidden or 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,38 @@ | ||
| import { viewProfile } from '../view/profile.js'; | ||
| import { out } from './logout.js'; | ||
| import { editionOfProfile } from '../view/editprofile.js'; | ||
| import { viewForum } from '../view/fuorum.js'; | ||
| import { publicPost, addNewPost } from './publicpoust.js'; | ||
| import { readPosts } from './readposts.js'; | ||
| import { editProfileUser } from './editprofile.js'; | ||
|
|
||
| function clickMenus(obtainingPersistenceData) { | ||
| let nameMenus = document.querySelectorAll('ul.clickMenu li a'); | ||
| nameMenus.forEach(function(viewMenus) { | ||
| viewMenus.addEventListener('click', function(clickedMenu) { | ||
| clickedMenu.preventDefault(); | ||
| let userClickMenu = clickedMenu.target.dataset.nav; | ||
| if (userClickMenu == "/Foro") { | ||
| viewForum(obtainingPersistenceData) | ||
| .then(function() { | ||
| publicPost(obtainingPersistenceData); | ||
| readPosts(); | ||
| }); | ||
| window.history.pushState('Foro', 'Foro', '/Foro'); | ||
| } else if (userClickMenu == "/Perfil") { | ||
| viewProfile(obtainingPersistenceData); | ||
| window.history.pushState('perfil', 'Perfil', '/Perfil'); | ||
| } else if (userClickMenu == "/editarPerfil") { | ||
| editionOfProfile(obtainingPersistenceData) | ||
| .then(function() { | ||
| editProfileUser(obtainingPersistenceData); | ||
| }); | ||
| window.history.pushState('Editar Perfil', 'Editar Perfil', '/EditarPerfil'); | ||
| } else if (userClickMenu == "/cerrarSesion") { | ||
| out(); | ||
| }; | ||
| }); | ||
| }); | ||
| }; | ||
|
|
||
| export { clickMenus } | ||
This file contains hidden or 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,94 @@ | ||
| import { clickMenus } from './clickmenus.js'; | ||
| import { viewForum } from '../view/fuorum.js'; | ||
| import { publicPost, addNewPost } from './publicpoust.js'; | ||
| import { readPosts } from './readposts.js'; | ||
|
|
||
|
|
||
| function editProfileUser(user) { | ||
| let savesChanges = document.getElementById('saveChangesButton'); | ||
| let profilePictureInput = document.getElementById('newProfilePhoto'); //aquí pongo en id del input donde voy dar click para entrar a carpeta que muestra imágenes | ||
| let imageUrl = ''; //la variable está vacia,porque solamente cuando el usuario mande una imagen y la imagen sea subida a firebase, tendremos solo así el link. En caso de que el usuario ponga una imagen se llenará. | ||
|
|
||
| profilePictureInput.onchange = changeProfilePhoto => { | ||
| console.log(changeProfilePhoto); | ||
|
|
||
| let file = changeProfilePhoto.target.files[0]; | ||
| firebase.storage().ref("devpost").child(file.name).put(file) //le digo a firebase que voy a ocupar su servicio de storage haciendo referencia a la carpeta devpost y que voy a declarar un hijito como mi file que ya declaramos arriba .name ahí entramos a la propiedad name de file, y luego le decimos quiero poner que es PUT este archivo(file) y es tal cual todo el objeto del archivo | ||
| .then(snap => { ///cuando ya sea exitoso snap es el que me va a retornar la respuesta del storage de firebase | ||
| return snap.ref.getDownloadURL() //retorname el ref y la url de descarga de mi imagen que acabo de subir a tu servicio, esta url la recibe la siguiente promesa como link | ||
| }) | ||
| .then(link => { //entonces..Si todo exitoso: | ||
| console.log(link) | ||
| imageUrl = link; //devuelveme la url de esta imagen que subiste | ||
| let img = document.getElementById('userPhoto'); //recueparmos la imagen con su id | ||
| img.src = imageUrl; //y le decimos que su srrc va ser igual a esa imagen y ya se ve el preview en el circulito | ||
| }); | ||
| }; | ||
|
|
||
| savesChanges.onclick = function() { | ||
|
|
||
| let callName = document.querySelector('#changeName'); | ||
| let callProfession = document.querySelector('#changeProfession'); | ||
|
|
||
| let editDataProfile = { | ||
| user: callName.value, | ||
| job: callProfession.value, | ||
| img: imageUrl, | ||
| uid: user.uid, | ||
| }; | ||
|
|
||
| addInformationProfileEdit(editDataProfile) | ||
| .then(function() { | ||
| // Get the existing data | ||
| let existing = localStorage.getItem('userdata'); | ||
| // If no existing data, create an array | ||
| // Otherwise, convert the localStorage string to an array | ||
| existing = existing ? JSON.parse(existing) : {}; //un objeto vacio en el caso de que no haya para yo llenarlo | ||
| // Add new data to localStorage Array | ||
| existing['displayName'] = editDataProfile.user; | ||
| existing['job'] = editDataProfile.job; | ||
| existing['photoURL'] = editDataProfile.img; | ||
| // Save back to localStorage | ||
| localStorage.setItem('userdata', JSON.stringify(existing)); | ||
| return existing; | ||
| }) | ||
| .then(function(existing) { //esto es la promesa | ||
| console.log('este es el bueno', existing); | ||
|
|
||
| alert('se guardaron los datos') //este es el resultado de la promesa | ||
| viewForum(existing) | ||
| .then(function() { | ||
| publicPost(existing); | ||
| readPosts(); | ||
| }) | ||
| .then(function() { | ||
| clickMenus(existing); | ||
| updatePostPic(user.uid, imageUrl); | ||
| }) | ||
| }) | ||
| .catch(err => { | ||
| console.log(err) //esto es el error cuando la respuesta es negativa | ||
| }); | ||
| }; | ||
|
|
||
| }; | ||
|
|
||
| function addInformationProfileEdit(editDataProfile) { | ||
| console.log(editDataProfile); | ||
| return firebase.database().ref('users/' + editDataProfile.uid).set(editDataProfile); | ||
| } | ||
|
|
||
| function updatePostPic(uid, photo) { | ||
| return db.collection("pruebas_020520").where("uid", "==", uid) | ||
| .get() | ||
| .then(function(resultAllPost) { | ||
| resultAllPost.forEach(function(post) { | ||
| db.collection("pruebas_020520").doc(post.id).update({ | ||
| photo: photo, | ||
| }); | ||
| }); | ||
| }); | ||
|
|
||
| }; | ||
|
|
||
| export { editProfileUser } |
This file contains hidden or 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,37 @@ | ||
| import { clickMenus } from './clickmenus.js'; | ||
| import { viewForum } from '../view/fuorum.js'; | ||
| import { publicPost, addNewPost } from './publicpoust.js'; | ||
|
|
||
|
|
||
| //Login with Facebook | ||
| function facebookButton() { | ||
| let provider = new firebase.auth.FacebookAuthProvider(); | ||
| let movilIcon = document.getElementById('movilIcon'); | ||
|
|
||
| firebase.auth().signInWithPopup(provider) | ||
| .then(function(data) { | ||
| // This gives you a Facebook Access Token. You can use it to access the Facebook API. | ||
| let token = data.credential.accessToken; | ||
| // The signed-in user info. | ||
| let user = data.user; | ||
| clickMenus(user); | ||
| viewForum(user) | ||
| .then(function() { | ||
| publicPost(); | ||
| }) | ||
| .then(function() { | ||
| localStorage.setItem('userdata', JSON.stringify(user)); | ||
| }) | ||
| movilIcon.classList.add('shown'); | ||
| document.getElementById('hideAndShow').style.display = 'block'; | ||
| }) | ||
| .catch(function(error) { | ||
| console.log(error); | ||
| let errorCode = error.code; | ||
| let errorMessage = error.message; | ||
| let email = error.email; | ||
| let credential = error.credential; | ||
| }); | ||
| }; | ||
|
|
||
| export { facebookButton } |
This file contains hidden or 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,37 @@ | ||
| import { clickMenus } from './clickmenus.js'; | ||
| import { viewForum } from '../view/fuorum.js'; | ||
| import { publicPost, addNewPost } from './publicpoust.js'; | ||
|
|
||
|
|
||
| //Login with Google Acount | ||
| function googleButton() { | ||
| let provider = new firebase.auth.GoogleAuthProvider(); | ||
| let movilIcon = document.getElementById('movilIcon'); | ||
|
|
||
| firebase.auth().signInWithPopup(provider) | ||
| .then(function(data) { | ||
| // This gives you a Google Access Token. You can use it to access the Google API. | ||
| let token = data.credential.accessToken; | ||
| // The signed-in user info. | ||
| let user = data.user; | ||
| clickMenus(user); | ||
| viewForum(user) | ||
| .then(function() { | ||
| publicPost(); | ||
| }) | ||
| .then(function() { | ||
| localStorage.setItem('userdata', JSON.stringify(user)); | ||
| }); | ||
| document.getElementById('hideAndShow').style.display = 'block'; | ||
| movilIcon.classList.add('shown'); | ||
|
|
||
| }) | ||
| .catch(function(error) { | ||
| let errorCode = error.code; | ||
| let errorMessage = error.message; | ||
| let email = error.email; | ||
| let credential = error.credential; | ||
| }); | ||
| } | ||
|
|
||
| export { googleButton } |
This file contains hidden or 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,35 @@ | ||
| //Page one Login | ||
| import { viewForum } from '../view/fuorum.js'; | ||
| import { readPosts } from './readposts.js'; | ||
| import { clickMenus } from './clickmenus.js'; | ||
| import { publicPost, addNewPost } from './publicpoust.js'; | ||
|
|
||
| function loginPageOne() { | ||
| let email = document.getElementById('email').value; | ||
| let pass = document.getElementById('pass').value; | ||
| let movilIcon = document.getElementById('movilIcon'); | ||
| firebase.auth().signInWithEmailAndPassword(email, pass,) | ||
| .then((data) => { | ||
| clickMenus(data.user); | ||
| viewForum(data.user) | ||
| .then(function() { | ||
| publicPost(data.user); | ||
| readPosts(); | ||
| }) | ||
| .then(function() { | ||
| localStorage.setItem('userdata', JSON.stringify(data.user)); | ||
| }); | ||
|
|
||
| document.getElementById('hideAndShow').style.display = 'block'; | ||
| movilIcon.classList.add('shown'); | ||
| }) | ||
| .catch(function(error) { | ||
| alert('Los datos ingresados no son correctos'); | ||
| let errorCode = error.code; | ||
| let errorMessage = error.message; | ||
| alert(errorMessage); | ||
| }); | ||
| let cred = firebase.auth.EmailAuthProvider.credential(email, pass); | ||
| } | ||
|
|
||
| export { loginPageOne } |
This file contains hidden or 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,68 @@ | ||
| //Log out | ||
| import { viewLogin } from '../view/login.js'; | ||
| import { loginPageOne } from './loginpageone.js'; | ||
| import { viewRegister } from '../view/register.js'; | ||
| import { register } from './register.js'; | ||
| import { googleButton } from './logingoogle.js'; | ||
| import { facebookButton } from './loginfacebook.js'; | ||
|
|
||
| function out() { | ||
| console.log('revisando out'); | ||
|
|
||
| firebase.auth().signOut() | ||
| .then(function() { | ||
| document.getElementById('movilIcon').classList.toggle('shown'); | ||
| document.getElementById('hideAndShow').style.display = 'none'; | ||
| }) | ||
| .then(function() { | ||
| viewLogin() | ||
| .then(function() { | ||
| localStorage.setItem('userdata', null); | ||
| }) | ||
| .then(function() { | ||
| let buttonLogin = document.querySelector('#doLogin'); | ||
| buttonLogin.addEventListener('click', function(e) { | ||
| e.preventDefault(); | ||
| loginPageOne(); | ||
| movilIcon.classList.add('shown'); | ||
| }); | ||
| }) | ||
| .then(function() { | ||
| let buttonGoogle = document.querySelector('#loginGoogle'); | ||
| buttonGoogle.addEventListener('click', function(e) { | ||
| e.preventDefault(); | ||
| googleButton(); | ||
| }); | ||
| }) | ||
| .then(function() { | ||
| let buttonFacebook = document.querySelector('#loginFacebook'); | ||
| buttonFacebook.addEventListener('click', function(e) { | ||
| e.preventDefault(); | ||
| facebookButton(); | ||
| document.getElementById('hideAndShow').style.display = 'block'; | ||
| movilIcon.classList.add('shown'); | ||
| }); | ||
| }) | ||
| .then(function() { | ||
| let ntAccount = document.querySelector('#reg'); | ||
| ntAccount.addEventListener('click', function(e) { | ||
| e.preventDefault(); | ||
| viewRegister() | ||
| .then(function() { | ||
| let buttonReg = document.querySelector('#doRegister'); | ||
| buttonReg.addEventListener('click', function(e) { | ||
| e.preventDefault(); | ||
| register(); | ||
| }); | ||
| }); | ||
| }); | ||
| }); | ||
|
|
||
| window.history.pushState('cerrar sesion', 'cerrar sesion', '/'); | ||
| }) | ||
| .catch(function(error) { | ||
| console.log(error); | ||
| }); | ||
| }; | ||
|
|
||
| export { out } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Qué pasó aqui con la identación?