diff --git a/index.html b/index.html index e25aee2..1897d2a 100644 --- a/index.html +++ b/index.html @@ -3,13 +3,15 @@ Celebrating Christmas! - + - + + +
-
+

Loading...

diff --git a/json/quotes.json b/json/quotes.json deleted file mode 100644 index 8d1cf21..0000000 --- a/json/quotes.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "christmasQuotes": [ - { - "quote": "You can mess with a lot of things, but you can't mess with kids on Christmas", - "attribution": "Kevin McCallister, \"Home Alone 2: Lost in New York\"" - }, - { - "quote": "I never thought it was such a bad little tree. It’s not bad at all really. Maybe it just needs a little love.", - "attribution": "Charlie Brown, \"A Charlie Brown Christmas\"" - }, - { - "quote": "Christmas was on its way. Lovely, glorious, beautiful Christmas, upon, which the entire kid year revolved.", - "attribution": "Ralphie, \"A Christmas Story\"" - }, - { - "quote": "Just remember, the true spirit of Christmas lies in your heart.", - "attribution": "Santa, \"The Polar Express\"" - }, - { - "quote": "Seeing is believing, but sometimes the most real things in the world are the things we can’t see.", - "attribution": "Conductor, \"The Polar Express\"" - } - ] -} \ No newline at end of file diff --git a/pages/home.html b/pages/home.html index 06b921f..399f0a8 100644 --- a/pages/home.html +++ b/pages/home.html @@ -1,3 +1,10 @@

Merry Christmas! -

\ No newline at end of file +

+ +
+
+
+

,

+ +
\ No newline at end of file diff --git a/static/site.css b/static/css/site.css similarity index 74% rename from static/site.css rename to static/css/site.css index d736420..930bf49 100644 --- a/static/site.css +++ b/static/css/site.css @@ -9,7 +9,7 @@ html { margin: 0; padding: 0; background: #FF0000; - background: linear-gradient(180deg,rgba(255, 0, 0, 0.75) 0%, rgba(99, 2, 2, 1) 15%, rgba(2, 99, 2, 1) 85%, rgba(0, 255, 0, 0.75) 100%); + background: linear-gradient(180deg,rgba(75, 0, 0, 0.75) 0%, rgba(75, 2, 2, 1) 15%, rgba(2, 75, 2, 1) 85%, rgba(0, 75, 0, 0.75) 100%); scroll-behavior: smooth; } @@ -61,6 +61,36 @@ body { text-shadow: 0 0 15px rgba(99, 2, 2, 1); } +.cited-source { + margin: 32px 60px; +} + +@media (max-width: 1000px) { + .main { + margin: auto; + width: 80vw; + height: 70vh; + background: rgba(255,255,255,.25); + padding: 6px; + border-radius: 5px; + box-shadow: 0 0 25px rgba(0,0,0,0.5); + overflow-y: auto; + } +} + +@media (max-width: 700px) { + .main { + margin: auto; + width: 95vw; + height: 80vh; + background: rgba(255,255,255,.25); + padding: 6px; + border-radius: 5px; + box-shadow: 0 0 25px rgba(0,0,0,0.5); + overflow-y: auto; + } +} + /* ===== Scrollbar CSS ===== */ /* Firefox */ * { diff --git a/static/js/site.js b/static/js/site.js new file mode 100644 index 0000000..e9843eb --- /dev/null +++ b/static/js/site.js @@ -0,0 +1,12 @@ + +const quotesForPage = { + getQuoteData: async function() { + return (await axios.get('/static/json/quotes.json')).data; + }, + + getRandomQuoteAsync: async function() { + let quotes = (await quotesForPage.getQuoteData()).christmasQuotes; + let indexChoice = Math.floor(Math.random() * quotes.length); + return quotes[indexChoice]; + } +} \ No newline at end of file diff --git a/static/json/quotes.json b/static/json/quotes.json new file mode 100644 index 0000000..e72f075 --- /dev/null +++ b/static/json/quotes.json @@ -0,0 +1,44 @@ +{ + "christmasQuotes": [ + { + "quote": "God bless us, everyone!", + "attribution": "Tiny Tim", + "source": "A Christmas Carol" + }, + { + "quote": "You can mess with a lot of things, but you can't mess with kids on Christmas", + "attribution": "Kevin McCallister", + "source": "Home Alone 2: Lost in New York" + }, + { + "quote": "I never thought it was such a bad little tree. It’s not bad at all really. Maybe it just needs a little love.", + "attribution": "Charlie Brown", + "source": "A Charlie Brown Christmas" + }, + { + "quote": "Christmas was on its way. Lovely, glorious, beautiful Christmas, upon, which the entire kid year revolved.", + "attribution": "Ralphie", + "source": "A Christmas Story" + }, + { + "quote": "Just remember, the true spirit of Christmas lies in your heart.", + "attribution": "Santa", + "source": "The Polar Express" + }, + { + "quote": "Seeing is believing, but sometimes the most real things in the world are the things we can’t see.", + "attribution": "Conductor", + "source": "The Polar Express" + }, + { + "quote": "You're skipping Christmas! Isn't that against the law?", + "attribution": "Spike Frohmeyer", + "source": "Christmas with the Kranks" + }, + { + "quote": "Every time a bell rings, an angel gets his wings.", + "attribution": "Zuzu Bailey", + "source": "It's a Wonderful Life" + } + ] +} \ No newline at end of file