Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

48 changes: 48 additions & 0 deletions src/week1/day0/expenses.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>

<body>
<header>
<h1>Excercise 1 - Expenses</h1>
</header>
<section>
<table>
<thead>
<th>Expense</th>
<th>Month</th>
<th>Year</th>
<th>Ammount</th>
</thead>
<tbody>
<tr>
<td>Water service</td>
<td>July</td>
<td>2018</td>
<td>$500</td>
</tr>
<tr>
<td>Electricity</td>
<td>July</td>
<td>2018</td>
<td>$1000</td>
</tr>
<tr>
<td>Gas</td>
<td>June</td>
<td>2018</td>
<td>$800</td>
</tr>

</tbody>
</table>
</section>
</body>

</html>
31 changes: 31 additions & 0 deletions src/week1/day0/img-vid-sound.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>

<body>
<header>
<h1>Excercise 1 - Image, video & sound</h1>
</header>
<section>
<h2>Image</h2>
<img src="./res/example-image.jpg" alt="Image">
<h2>Sound</h2>
<audio controls>
<source src="./res/example-sound.mp3" type="audio/mp3">
</audio>

<h2>Video</h2>
<video controls>
<source src="./res/example-video.mp4" type="video/mp4">
</video>

</section>
</body>

</html>
Binary file added src/week1/day0/res/example-image.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/week1/day0/res/example-sound.mp3
Binary file not shown.
Binary file added src/week1/day0/res/example-video.mp4
Binary file not shown.
60 changes: 60 additions & 0 deletions src/week1/day0/signup.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>

<body>
<header>
<h1>Excercise 1 - Sign Up form</h1>
</header>
<section>
<form action="">
<!-- First name -->
<div>
<label for="first-name">First name</label>
<input type="text" name="first-name" id="first-name" required>
</div>
<!-- Last name -->
<div>
<label for="last-name">Last name</label>
<input type="text" name="last-name" id="last-name" required>
</div>
<!-- E-mail -->
<div>
<label for="email">E-mail</label>
<input type="email" name="email" id="email" required>
</div>
<!-- Birthday -->
<div>
<label for="bday">Birthday</label>
<input type="date" name="bday" id="bday">
</div>
<!-- Favourite sport -->
<div>
<label for="sport">Favourite sport</label>
<select name="sport" id="sport">
<option value="football">Football</option>
<option value="basketball">Basketball</option>
<option value="tennis">Tennis</option>
</select>
</div>
<!-- User's bio -->
<div>
<label for="bio">User's bio</label>
<textarea name="bio" id="bio" cols="30" rows="10"></textarea>
</div>
<!-- Buttons -->
<div>
<button type="submit">Submit</button>
<button type="reset">Reset</button>
</div>
</form>
</section>
</body>

</html>
26 changes: 26 additions & 0 deletions src/week1/day0/todo-list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Document</title>
</head>

<body>
<header>
<h1>My todo list</h1>
</header>
<section>
<ul>
<li>Todo 1</li>
<li>Todo 2</li>
<li>Todo 3</li>
<li>Todo 4</li>
<li>Todo 5</li>
</ul>
</section>
</body>

</html>
94 changes: 88 additions & 6 deletions src/week2/day3/indexEvents.html
Original file line number Diff line number Diff line change
@@ -1,11 +1,93 @@
<!-- Take this file and open it on a browser, then open the console
inside developer tools -->
<script>
(function(){
"use strict";
})()
</script>


<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>JS Events</title>
</head>

<body>
<button id="hello">Say "Hello!"</button>
<button id="name">Say "Hello!" with user's name</button>
<button id="doubleClk">Double-click me!</button>
<button id="ghost">I do nothing, but disappear on hover</button>
<ul>
<li>Clicked: <span id="clicked"></span></li>
<li>Double-clicked: <span id="dblclicked"></span></li>
</ul>

<h4>Mouse Position</h4>
X: <span id="posX"></span>
Y: <span id="posY"></span>

<script>
(function () {
"use strict";

// Buttons listeners

var helloButton = document.querySelector("#hello");
helloButton.addEventListener("click", event => {
alert("Hello, user!");
});

var helloNameButton = document.querySelector("#name");
helloNameButton.addEventListener("click", event => {
var name = prompt("What's your name?", "");
alert(`Hello, ${name}`);
});

var doubleClkButton = document.querySelector("#doubleClk");
doubleClkButton.addEventListener("dblclick", event => {
alert("Double clicked! 💪");
})

var ghostButton = document.querySelector("#ghost");
ghostButton.addEventListener("mouseenter", event => {
ghostButton.style.opacity = 0;
});
ghostButton.addEventListener("mouseleave", event => {
ghostButton.style.opacity = 1;
});

// Body listeners

document.body.addEventListener("click", event => {
if (event.target.nodeName == "BUTTON") {
document.getElementById("clicked").textContent = event.target.textContent;
}
});
document.body.addEventListener("dblclick", event => {
if (event.target.nodeName == "BUTTON") {
document.getElementById("dblclicked").textContent = event.target.textContent;
}
});

window.addEventListener("mousemove", event => {
var x = event.clientX;
var y = event.clientY;

var posX = document.querySelector("#posX");
var posY = document.querySelector("#posY");

posX.textContent = x;
posY.textContent = y;
});



})()
</script>

</body>

</html>
<!-- Now it's your turn to make some changes
- Draw some buttons, make your way between the click events and let me know they are pressed
- What other events are you familiar with? Show it
Expand All @@ -15,4 +97,4 @@
**** keep me informed of the pointer's ****
**** position, make it show on screen ****
****************************************************
-->
-->
2 changes: 1 addition & 1 deletion src/week2/day4-5/expressDemo.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const express = ;
//const express = ;
const app = express();
const port = 3000;

Expand Down
3 changes: 3 additions & 0 deletions src/week2/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 13 additions & 0 deletions src/week4/mars-boot/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Editor configuration, see http://editorconfig.org
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
max_line_length = off
trim_trailing_whitespace = false
39 changes: 39 additions & 0 deletions src/week4/mars-boot/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
/dist
/tmp
/out-tsc

# dependencies
/node_modules

# IDEs and editors
/.idea
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json

# misc
/.sass-cache
/connect.lock
/coverage
/libpeerconnection.log
npm-debug.log
yarn-error.log
testem.log
/typings

# System Files
.DS_Store
Thumbs.db
27 changes: 27 additions & 0 deletions src/week4/mars-boot/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# MarsBoot

This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 6.2.2.

## Development server

Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.

## Code scaffolding

Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.

## Build

Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.

## Running unit tests

Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).

## Running end-to-end tests

Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).

## Further help

To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).
Loading