From 6350514be21e173f8e02a55ebf7319e89dc41dd4 Mon Sep 17 00:00:00 2001 From: Elisabeth-Matulian Date: Fri, 13 Mar 2026 07:26:14 +0000 Subject: [PATCH 1/2] implement quote generator app --- Sprint-3/quote-generator/index.html | 5 +++-- Sprint-3/quote-generator/script.js | 12 ++++++++++++ 2 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 Sprint-3/quote-generator/script.js diff --git a/Sprint-3/quote-generator/index.html b/Sprint-3/quote-generator/index.html index 30b434bcf..9393ae415 100644 --- a/Sprint-3/quote-generator/index.html +++ b/Sprint-3/quote-generator/index.html @@ -3,11 +3,12 @@ - Title here + Quote generator app + -

hello there

+

Quote Generator

diff --git a/Sprint-3/quote-generator/script.js b/Sprint-3/quote-generator/script.js new file mode 100644 index 000000000..54f1da792 --- /dev/null +++ b/Sprint-3/quote-generator/script.js @@ -0,0 +1,12 @@ + +const quote = document.querySelector('#quote'); +const author = document.querySelector('#author'); +callQuote(); + +const newCodeButton = document.querySelector('#new-quote'); +function callQuote() { + let randomQuote = pickFromArray(quotes); + quote.innerText = randomQuote.quote; + author.innerText = randomQuote.author; +} +newCodeButton.addEventListener('click', callQuote) \ No newline at end of file From 128266684ad7bd882c4625ce5a364c09f345afb7 Mon Sep 17 00:00:00 2001 From: Elisabeth-Matulian Date: Fri, 13 Mar 2026 08:08:41 +0000 Subject: [PATCH 2/2] add styles --- Sprint-3/quote-generator/index.html | 10 ++++++---- Sprint-3/quote-generator/style.css | 24 ++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 4 deletions(-) diff --git a/Sprint-3/quote-generator/index.html b/Sprint-3/quote-generator/index.html index 9393ae415..8cb68f4d2 100644 --- a/Sprint-3/quote-generator/index.html +++ b/Sprint-3/quote-generator/index.html @@ -6,11 +6,13 @@ Quote generator app + -

Quote Generator

-

-

- +
+

+

+ +
diff --git a/Sprint-3/quote-generator/style.css b/Sprint-3/quote-generator/style.css index 63cedf2d2..18663ee9d 100644 --- a/Sprint-3/quote-generator/style.css +++ b/Sprint-3/quote-generator/style.css @@ -1 +1,25 @@ /** Write your CSS in here **/ +body { + display: flex; + flex-direction: row; + justify-content: center; + padding: 10%; + background-color:rgba(35, 81, 56, 0.361); +} + +#quote-box { + background-color:rgba(255, 255, 255, 0.918); + border-style: solid; + padding: 10%; +} +#author { + text-align: right; +} +#new-quote { + display: block; + margin-left: auto; + margin-top: 20px; + padding: 10px; + background-color: rgba(35, 81, 56, 0.361); + border-style: solid; +} \ No newline at end of file