Skip to content

Topic1#2

Open
Facundo97Maldonado wants to merge 11 commits intomasterfrom
Topic1
Open

Topic1#2
Facundo97Maldonado wants to merge 11 commits intomasterfrom
Topic1

Conversation

@Facundo97Maldonado
Copy link
Owner

No description provided.

@@ -0,0 +1,28 @@
.x1{
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Estos estilos no los veo aplicados en ningún lado

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Estos nombres de clases son horripilantes xD

<link rel="stylesheet" type="text/css" href="myStylesheet.css">
</head>
<body>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Angular? estimo que esto esta de más

<!--JAVASCRIPT -->
<!-- Function to change the text of a button when you drag the mouse over him -->
<script>
function changeText(id){
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Es solo un tema de nombre id es en realidad el elemento del DOM que representa el botton. Probablemente "target" o "element" serian nombre mas adecuados

section.style.opacity = val;
requestAnimationFrame(fade);
}
})();
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

La construcción de fade() es conocida como IIFE y sirve para llamar a una función inmediatamente luego de la definición.

http://benalman.com/news/2010/11/immediately-invoked-function-expression/
https://en.wikipedia.org/wiki/Immediately-invoked_function_expression

Dado que fade es llamada cuando se llama a fadeIn en la práctica es lo mismo usar una IIFE o poner el cuerpo de la misma dentro de fadeIn

})();
}

fadeIn(section);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Para fadeIn si podrías usar una construcción de IIFE ya que es la única llamada de la misma y sucede justo después de su definición


<!-- Function to set specific content to the section when is clicked. Exercise 6-->
<script>
function loadXMLDoc() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No encuentro donde estas invocando esta funcion

@Facundo97Maldonado
Copy link
Owner Author

Facundo97Maldonado commented Apr 27, 2017 via email

@Facundo97Maldonado
Copy link
Owner Author

Facundo97Maldonado commented Apr 27, 2017 via email

section.style.opacity = -10; //time after page loads to display the content
section.style.display = display || "block";
(function fade() {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

La idea acá es no hacer la animación a mano si no usar javascript para registrar un handler, eventos del browser para saber cuándo cargó y CSS3 para la transición

};
eventRequestReusable(config).then(resolve,reject); //Here is where the configuration object is entered
function resolve(xhttp) {
let response = JSON.parse(event.target.response);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

de dónde sale event?? funciona, pero no veo por qué

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants