diff --git a/cse134-hw1/README.md b/cse134-hw1/README.md new file mode 100644 index 0000000..e3887c4 --- /dev/null +++ b/cse134-hw1/README.md @@ -0,0 +1,3 @@ +# CSE134B-SS20-HW1 +# Name: +# PID: \ No newline at end of file diff --git a/cse134-hw1/fonts/Literata/static/Literata-Bold.ttf b/cse134-hw1/fonts/Literata/static/Literata-Bold.ttf new file mode 100644 index 0000000..94064af Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-Bold.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-BoldItalic.ttf b/cse134-hw1/fonts/Literata/static/Literata-BoldItalic.ttf new file mode 100644 index 0000000..b31391c Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-BoldItalic.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-Italic.ttf b/cse134-hw1/fonts/Literata/static/Literata-Italic.ttf new file mode 100644 index 0000000..d3020fb Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-Italic.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-Medium.ttf b/cse134-hw1/fonts/Literata/static/Literata-Medium.ttf new file mode 100644 index 0000000..0858988 Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-Medium.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-MediumItalic.ttf b/cse134-hw1/fonts/Literata/static/Literata-MediumItalic.ttf new file mode 100644 index 0000000..9eefad6 Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-MediumItalic.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-Regular.ttf b/cse134-hw1/fonts/Literata/static/Literata-Regular.ttf new file mode 100644 index 0000000..81f5c52 Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-Regular.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-SemiBold.ttf b/cse134-hw1/fonts/Literata/static/Literata-SemiBold.ttf new file mode 100644 index 0000000..8ee8949 Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-SemiBold.ttf differ diff --git a/cse134-hw1/fonts/Literata/static/Literata-SemiBoldItalic.ttf b/cse134-hw1/fonts/Literata/static/Literata-SemiBoldItalic.ttf new file mode 100644 index 0000000..5d92c4b Binary files /dev/null and b/cse134-hw1/fonts/Literata/static/Literata-SemiBoldItalic.ttf differ diff --git a/cse134-hw1/images/bear.png b/cse134-hw1/images/bear.png new file mode 100644 index 0000000..17d995e Binary files /dev/null and b/cse134-hw1/images/bear.png differ diff --git a/cse134-hw1/images/bg_homepage.jpg b/cse134-hw1/images/bg_homepage.jpg new file mode 100644 index 0000000..a7f12af Binary files /dev/null and b/cse134-hw1/images/bg_homepage.jpg differ diff --git a/cse134-hw1/images/favicon.ico b/cse134-hw1/images/favicon.ico new file mode 100644 index 0000000..dcef2dc Binary files /dev/null and b/cse134-hw1/images/favicon.ico differ diff --git a/cse134-hw1/images/triton.jpg b/cse134-hw1/images/triton.jpg new file mode 100644 index 0000000..0616a40 Binary files /dev/null and b/cse134-hw1/images/triton.jpg differ diff --git a/cse134-hw1/images/ucsd.gif b/cse134-hw1/images/ucsd.gif new file mode 100644 index 0000000..be1b67a Binary files /dev/null and b/cse134-hw1/images/ucsd.gif differ diff --git a/cse134-hw1/index.html b/cse134-hw1/index.html new file mode 100644 index 0000000..71fa2f3 --- /dev/null +++ b/cse134-hw1/index.html @@ -0,0 +1,101 @@ + + + + + + + + + + CSE 134B Homework 1 Website + + + + + + +
+

CSE 134B Homework 1 Website

+ +
+ + + +
+ + +
+ + + +
+
+ +
+

UCSD Images

+
+ Warren Bear + Triton + UCSD +
+ + +
+

UCSD Promo Video

+ +
+
+ +
+
+ + + + + + + \ No newline at end of file diff --git a/cse134-hw1/scripts/main-es5.js b/cse134-hw1/scripts/main-es5.js new file mode 100644 index 0000000..8b88e1e --- /dev/null +++ b/cse134-hw1/scripts/main-es5.js @@ -0,0 +1,19 @@ +/* main-es5.js */ + +// look this up :) +'use strict'; + +function updateName() { + var name = document.getElementById('name-input').value; + document.getElementById('author-info').innerHTML = 'Author: ' + name; + } + + function updateMajor() { + var name = document.getElementById('major-input').value; + document.getElementById('major-info').innerHTML = 'Major: ' + name; + } + +function update(){ + updateName(); + updateMajor(); + } \ No newline at end of file diff --git a/cse134-hw1/scripts/main.js b/cse134-hw1/scripts/main.js new file mode 100644 index 0000000..9f581be --- /dev/null +++ b/cse134-hw1/scripts/main.js @@ -0,0 +1,24 @@ +/* main.js */ + +// no need to 'use strict' as it is implied in modules +// look up 'use strict' :) + +let $ = (selector) => document.querySelector(selector); + + +function _updateName() { + const name = $('#name-input').value; + $('#name-info').innerHTML = `Author: ${name}`; +} + +function _updateMajor() { + const major = $('#major-input').value; + $('#major-info').innerHTML = `Major: ${major}`; +} + +function update(){ + _updateName(); + _updateMajor(); +} + +export {update}; \ No newline at end of file diff --git a/cse134-hw1/styles/main.css b/cse134-hw1/styles/main.css new file mode 100644 index 0000000..f0aac7e --- /dev/null +++ b/cse134-hw1/styles/main.css @@ -0,0 +1,74 @@ +/* main.css */ + +html, +body { + background-color: lightblue; +} +@font-face { + font-family: "Literata"; + font-style: normal; + font-weight: 400; + src: url("../fonts/Literata/static/Literata-Regular.ttf") format("truetype"); +} +@font-face { + font-family: "Literata"; + font-style: bold; + font-weight: 400; + src: url("../fonts/Literata/static/Literata-Bold.ttf") format("truetype"); +} +@font-face { + font-family: "Literata"; + font-style: italic; + font-weight: 400; + src: url("../fonts/Literata/static/Literata-Italic.ttf") format("truetype"); +} + +/****** header ******/ +header { + background-image: url("../images/bg_homepage.jpg"); + background-color: #fcfcdc; + text-align: center; + padding: 20px 0; + font-family: "Literata", serif; + color: white; +} + +header hr { + width: 30%; +} + +/****** main content ******/ +img{ + margin: 10px; +} + +main { + text-align: center; +} + +ul { + background-color: white; + border: 8px double black; + border-radius: 4px; + margin: 0 auto; + padding: 20px; + text-align: left; + width: 200px; +} + +ul li { + margin: 5px; +} + +a:link { color: #3366BB; } +a:visited { color: #663366 } +a:visited:hover { color: #0b0080; } +a:hover { color: gray; } +a:active { background-color: yellow; border: 4px solid red;} + + +/****** footer ******/ +footer { + font-size: small; + text-align: center; +} \ No newline at end of file diff --git a/cse134-hw1/videos/videoplayback.mp4 b/cse134-hw1/videos/videoplayback.mp4 new file mode 100644 index 0000000..c43ec82 Binary files /dev/null and b/cse134-hw1/videos/videoplayback.mp4 differ