Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Tavan's Recipe Library #28

Open
wants to merge 26 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
a4dd0d4
test
Mar 5, 2025
647b4ab
connecting script to html and checking console.log
Mar 5, 2025
c2b8401
adding filter and sort buttons
Mar 10, 2025
76e978c
added cards with recipes
Mar 10, 2025
2577b75
linking HTML filet to CSS file
Mar 10, 2025
16047de
adding code to arrange the layout
Mar 10, 2025
d6fb9af
addind more code to layout. Adding media queries in order for the con…
Mar 10, 2025
36c6e72
adding JS array of objects
Mar 10, 2025
3178a5f
adding funktion to display
Mar 10, 2025
7db04a7
adding minutes to cooking time to display this on the website otherwi…
Mar 10, 2025
8c750d5
adding eventlisteners for filters so that website filters the cuisine…
Mar 10, 2025
34bcf48
adding eventlisteners so that the website sorts between the recipes d…
Mar 10, 2025
f7f96b5
making minor changes to the arrays of objects such as changing the na…
Mar 10, 2025
1016cb1
changing and adding code to filter and sort buttons.
Mar 11, 2025
0c5d298
adding random button and selected state
Mar 11, 2025
d9876a3
added button and no-match message
Mar 11, 2025
72b340d
made some changes to the buttons and added code to make the filtering…
Mar 17, 2025
d0efac5
changing file name to check if page is not found is removed on netlify
Mar 17, 2025
10ef10e
changing file names in the documents
Mar 17, 2025
0994738
made a slight change in border- color to recipe cards
Mar 17, 2025
e13a6bb
made minor changes to media queries to make the conent fit mobile screen
Mar 18, 2025
d06a04e
added HTML, CSS and Javascript quota-message
Mar 23, 2025
bee0880
changed the names of screens to tablet and desktop
Mar 23, 2025
176a5e1
changed the '' to for consistency
Mar 23, 2025
4687a18
added no matching recipe
Mar 23, 2025
3b514f7
changed API Key
Mar 23, 2025
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
Binary file added .DS_Store
Binary file not shown.
Binary file added Images/.DS_Store
Binary file not shown.
Binary file added Images/French-moules- frites.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 Images/Greek-salad.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 Images/Greek-traditional-salad.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 Images/Italian-frutti-di-mare.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 Images/Italian-truffle-spaghetti.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 Images/Spanish-crudo.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 Images/Spanish-tapas.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 Images/Spanish-vegetable-stew.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
# js-project-recipe-library

()
176 changes: 176 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,176 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Home</title>
<link rel="stylesheet" href="style.css">
</head>
<body>
<h1>Recipe Library</h1>

<div class="filter-buttons">
<h2>Filter</h2>
<button class="filter-btn selected">All</button>
<button class="filter-btn">Italian</button>
<button class="filter-btn">Mexican</button>
<button class="filter-btn">American</button>
<button class="filter-btn">European</button>
<button class="filter-btn">Asian</button>
</div>

<div class="sort-buttons">
<h2>Sort</h2>
<button class="sort-btn">Ascending</button>
<button class="sort-btn">Descending</button>
</div>

<div class="random-button">
<h2>Want a random recipe?</h2>
<button class="random-btn">Surprise Me!</button>
</div>

<div id="quota-message" class="hidden">
<p>You've exceeded the API quota limit for the day. Please try again later.</p>
</div>


<!-- This section is commented out
<div class="no-match">
<h2>Sorry, we have no recipes to show for now.</h2>
</div>

<div class="recipe-container">

<div class="recipe-card">
<img
src="./Images/Italian-frutti-di-mare.jpg"
alt="frutti di mare dish"
>
<h2>Frutti di Mare</h2>
<hr>
<h3>Cuisine: Italian</h3>
<h3>Cooking time: 30 minutes</h3>
<hr>
<p>Ingredients:</p>
<ul>
<li>400g Pasta</li>
<li>500g Black mussels</li>
<li>200 shrimp (peeled)</li>
<li>2 Tomatoes</li>
<li>3 tbs Olive Oil</li>
<li>1 glove Basil leaves (for garnish)</li>
</ul>
</div>

<div class="recipe-card">
<img
src="./Images/Italian-truffle-spaghetti.jpg"
alt="bucatini with black truffle dish"
>
<h2>Bucatini with Black Truffle</h2>
<hr>
<h3>Cuisine: Italian</h3>
<h3>Cooking time: 30 minutes</h3>
<hr>
<p>Ingredients:</p>
<ul>
<li>400g Pasta</li>
<li>1 Black truffle (thinly sliced)</li>
<li>4 anchovy fillets (minced)</li>
<li>2 gloves galic (minced)</li>
<li>3 tbs Olive oil</li>
<li>Salt (pinch)</li>
</ul>
</div>

<div class="recipe-card">
<img
src="./Images/Spanish-tapas.jpg"
alt="tapas with clams and shrimps dish"
>
<h2>Tapas with Shrimp</h2>
<hr>
<h3>Cuisine type: Spanish</h3>
<h3>Cooking time: 25 minutes</h3>
<hr>
<p>Ingredients:</p>
<ul>
<li>1 Baguette</li>
<li>2 dozen shrimps</li>
<li>Fresh cilantro (minced)</li>
<li>2 red bell pepper (minced)</li>
<li>3 tbs Olive Oil</li>
<li>Salt (pinch)</li>
</ul>
</div>

<div class="recipe-card">
<img
src="./Images/Spanish-vegetable-stew.jpg"
alt="vegetable stew dish"
>
<h2>Vegetable Stew</h2>
<hr>
<h3>Cuisine: Spanish</h3>
<h3>Cooking time: 40 minutes</h3>
<hr>
<p>Ingredients:</p>
<ul>
<li>6 potatoes</li>
<li>500g Flat green bean</li>
<li>1/2 White Cabbage</li>
<li>200ml Vegetable Broth</li>
<li>3 tbs Olive Oil</li>
<li>Salt (pinch)</li>
</ul>
</div>

<div class="recipe-card">
<img
src="./Images/Greek-traditional-salad.jpg"
alt="greek salad dish"
>
<h2>Greek Salad</h2>
<hr>
<h3>Cuisine: Greek</h3>
<h3>Cooking time: 20 minutes</h3>
<hr>
<p>Ingredients:</p>
<ul>
<li>2 Tomatoes</li>
<li>1/2 Cucumber</li>
<li>150g Feta cheese</li>
<li>1 Red onion</li>
<li>300g Black olives</li>
<li>3tbs Olive oil</li>
</ul>
</div>

<div class="recipe-card">
<img
src="./Images/Greek-salad.jpg"
alt="greek salad dish"
>
<h2>Greek Salad with Pomegranate</h2>
<hr>
<h3>Cuisine: Greek</h3>
<h3>Cooking time: 20 minutes</h3>
<hr>
<p>Ingredients:</p>
<ul>
<li>2 Tomatoes</li>
<li>1/2 Cucumbee</li>
<li>1 Red onion</li>
<li>1/4 Red cabbage</li>
<li>1 Pomegranate</li>
<li>200g Corn</li>
</ul>
</div>

</div>
This section is commented out -->

<script src="./script.js"></script>
</body>
</html>
Loading