From 8170d5bc0544fbc02155b8b57751cd1dec33dd69 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 6 Apr 2021 10:57:50 +0000 Subject: initial public commit --- views/account/account.ejs | 44 +++++++++++++++++++++++++++ views/account/changepass.ejs | 25 +++++++++++++++ views/account/editBio.ejs | 27 ++++++++++++++++ views/account/saved.ejs | 33 ++++++++++++++++++++ views/category/cats.ejs | 38 +++++++++++++++++++++++ views/index.ejs | 30 ++++++++++++++++++ views/login.ejs | 26 ++++++++++++++++ views/partials/bio.ejs | 19 ++++++++++++ views/partials/categories.ejs | 8 +++++ views/partials/footer.ejs | 3 ++ views/partials/header.ejs | 25 +++++++++++++++ views/partials/magicBio.ejs | 21 +++++++++++++ views/partials/magicCats.ejs | 8 +++++ views/partials/magicPops.ejs | 14 +++++++++ views/partials/magicSets.ejs | 15 +++++++++ views/partials/nav.ejs | 59 +++++++++++++++++++++++++++++++++++ views/partials/popular.ejs | 14 +++++++++ views/partials/search.ejs | 18 +++++++++++ views/partials/settings.ejs | 15 +++++++++ views/recipe/create.ejs | 51 +++++++++++++++++++++++++++++++ views/recipe/createStep.ejs | 29 ++++++++++++++++++ views/recipe/edit.ejs | 71 +++++++++++++++++++++++++++++++++++++++++++ views/recipe/editSteps.ejs | 29 ++++++++++++++++++ views/recipe/show.ejs | 55 +++++++++++++++++++++++++++++++++ views/recipe/upload.ejs | 26 ++++++++++++++++ views/register.ejs | 32 +++++++++++++++++++ views/search.ejs | 38 +++++++++++++++++++++++ 27 files changed, 773 insertions(+) create mode 100644 views/account/account.ejs create mode 100644 views/account/changepass.ejs create mode 100644 views/account/editBio.ejs create mode 100644 views/account/saved.ejs create mode 100644 views/category/cats.ejs create mode 100644 views/index.ejs create mode 100644 views/login.ejs create mode 100644 views/partials/bio.ejs create mode 100644 views/partials/categories.ejs create mode 100644 views/partials/footer.ejs create mode 100644 views/partials/header.ejs create mode 100644 views/partials/magicBio.ejs create mode 100644 views/partials/magicCats.ejs create mode 100644 views/partials/magicPops.ejs create mode 100644 views/partials/magicSets.ejs create mode 100644 views/partials/nav.ejs create mode 100644 views/partials/popular.ejs create mode 100644 views/partials/search.ejs create mode 100644 views/partials/settings.ejs create mode 100644 views/recipe/create.ejs create mode 100644 views/recipe/createStep.ejs create mode 100644 views/recipe/edit.ejs create mode 100644 views/recipe/editSteps.ejs create mode 100644 views/recipe/show.ejs create mode 100644 views/recipe/upload.ejs create mode 100644 views/register.ejs create mode 100644 views/search.ejs (limited to 'views') diff --git a/views/account/account.ejs b/views/account/account.ejs new file mode 100644 index 0000000..3c4e4ea --- /dev/null +++ b/views/account/account.ejs @@ -0,0 +1,44 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <% if(usr) { %> + <% if(usr._id.equals(account.author.id)) { %> + <%- include('../partials/settings') %> + <% } else { %> + <%- include('../partials/categories') %> + <% } %> + <% } else { %> + <%- include('../partials/categories') %> + <% } %> +
+
+ <% recipes.map(s => { %> +
+ recipe + <%= s.title %> + <% if(usr) { %> + <% if(usr._id.equals(s.author.id)) { %> +
+
+ +
+
+ +
+
+ <% } %> + <% } %> +
+ <% }) %> +
+
+ <%- include('../partials/bio') %> +
+<% if(usr) { %> + <%- include('../partials/magicSets') %> +<% } else { %> + <%- include('../partials/magicCats') %> +<% } %> +<%- include('../partials/magicBio') %> +<%- include('../partials/footer') %> diff --git a/views/account/changepass.ejs b/views/account/changepass.ejs new file mode 100644 index 0000000..25dc1fe --- /dev/null +++ b/views/account/changepass.ejs @@ -0,0 +1,25 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/settings') %> +
+
+

Edit Bio

+
+
+ + + + + +
+
+
+
+ <%- include('../partials/bio') %> +
+ +<%- include('../partials/magicSets') %> +<%- include('../partials/magicBio') %> +<%- include('../partials/footer') %> diff --git a/views/account/editBio.ejs b/views/account/editBio.ejs new file mode 100644 index 0000000..fb0a95b --- /dev/null +++ b/views/account/editBio.ejs @@ -0,0 +1,27 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/settings') %> +
+
+

Edit Bio

+
+
+ + + + + + + +
+
+
+
+ <%- include('../partials/bio') %> +
+ +<%- include('../partials/magicSets') %> +<%- include('../partials/magicBio') %> +<%- include('../partials/footer') %> diff --git a/views/account/saved.ejs b/views/account/saved.ejs new file mode 100644 index 0000000..2e4c864 --- /dev/null +++ b/views/account/saved.ejs @@ -0,0 +1,33 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/settings') %> +
+
+ <% recipes.map(s => { %> +
+ recipe + <%= s.title %> + <% if(usr) { %> + <% if(usr._id.equals(s.author.id)) { %> +
+
+ +
+
+ +
+
+ <% } %> + <% } %> +
+ <% }) %> +
+
+ <%- include('../partials/bio') %> +
+ +<%- include('../partials/magicSets') %> +<%- include('../partials/magicBio') %> +<%- include('../partials/footer') %> diff --git a/views/category/cats.ejs b/views/category/cats.ejs new file mode 100644 index 0000000..694a03b --- /dev/null +++ b/views/category/cats.ejs @@ -0,0 +1,38 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> +<%- include('../partials/search') %> + +
+ <%- include('../partials/categories') %> +
+
+ <% recipes.filter(r => { %> + <% if(r.category.toLowerCase() === query) { %> +
+ recipe + <%= r.title %> + <% if(usr) { %> + <% if(usr._id.equals(r.author.id)) { %> +
+
+ +
+
+ +
+
+ <% } %> + <% } %> +
+ <% } %> + <% }) %> + + +
+
+ <%- include('../partials/popular') %> +
+ +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/index.ejs b/views/index.ejs new file mode 100644 index 0000000..d66a90b --- /dev/null +++ b/views/index.ejs @@ -0,0 +1,30 @@ +<%- include('partials/header') %> +<%- include('partials/nav') %> +<%- include('partials/search') %> + +
+ <%- include('partials/categories') %> +
+
+

Welcome to the International Kitchen

+

A web application to find and share recipes with friends without the hassles of things likes adds and trackers.

+
+

Instructions

+

Simply create an account and start sharing your recipes. Please avoid using stock photos. Every recipe has a photo, category, list of ingredients and instruction steps. You can choose any category you want or make your own.

+

If you experience any problems or bugs email me at gferrand@vagrantz.xyz

+
+

Donate

+

This app is free and has no adds. If you enjoy using this app consider donating to help support this project (:

+
+ + + +
+
+
+
+ <%- include('partials/popular') %> +
+<%- include('partials/magicCats') %> +<%- include('partials/magicPops') %> +<%- include('partials/footer') %> diff --git a/views/login.ejs b/views/login.ejs new file mode 100644 index 0000000..4415a64 --- /dev/null +++ b/views/login.ejs @@ -0,0 +1,26 @@ +<%- include('partials/header') %> +<%- include('partials/nav') %> +<%- include('partials/search') %> + +
+ <%- include('partials/categories') %> +
+
+

Login

+
+
+ + + + + +
+
+
+
+ <%- include('partials/popular') %> +
+ +<%- include('partials/magicCats') %> +<%- include('partials/magicPops') %> +<%- include('partials/footer') %> diff --git a/views/partials/bio.ejs b/views/partials/bio.ejs new file mode 100644 index 0000000..198aa27 --- /dev/null +++ b/views/partials/bio.ejs @@ -0,0 +1,19 @@ +
+
+

<%= account.bio.name %>

+
    +
  • +

    Email:

    +

    <%= account.author.username %>

    +
  • +
  • +

    Website:

    +

    <%= account.bio.website %>

    +
  • +
  • +

    About:

    +

    <%= account.bio.about %>

    +
  • +
+
+
\ No newline at end of file diff --git a/views/partials/categories.ejs b/views/partials/categories.ejs new file mode 100644 index 0000000..638b2bb --- /dev/null +++ b/views/partials/categories.ejs @@ -0,0 +1,8 @@ +
+

Categories

+ +
\ No newline at end of file diff --git a/views/partials/footer.ejs b/views/partials/footer.ejs new file mode 100644 index 0000000..89a9ee1 --- /dev/null +++ b/views/partials/footer.ejs @@ -0,0 +1,3 @@ + + + diff --git a/views/partials/header.ejs b/views/partials/header.ejs new file mode 100644 index 0000000..13a6cf0 --- /dev/null +++ b/views/partials/header.ejs @@ -0,0 +1,25 @@ + + + + + + Recipes + + + + + +<% if(error && error.length > 0) { %> + + + +<% } %> +<% if(success && success.length > 0) { %> +
+ +
+<% } %> diff --git a/views/partials/magicBio.ejs b/views/partials/magicBio.ejs new file mode 100644 index 0000000..4d448a1 --- /dev/null +++ b/views/partials/magicBio.ejs @@ -0,0 +1,21 @@ +
+
+

<%= account.bio.name %>

+
    + <% if(usr) { %> +
  • +

    Email:

    +

    <%= account.author.username %>

    +
  • + <% } %> +
  • +

    Website:

    +

    <%= account.bio.website %>

    +
  • +
  • +

    About:

    +

    <%= account.bio.about %>

    +
  • +
+
+
diff --git a/views/partials/magicCats.ejs b/views/partials/magicCats.ejs new file mode 100644 index 0000000..fb49d05 --- /dev/null +++ b/views/partials/magicCats.ejs @@ -0,0 +1,8 @@ +
+

Categories

+
    + <% cats.map(c => { %> +
  • <%= c %>
  • + <% }) %> +
+
diff --git a/views/partials/magicPops.ejs b/views/partials/magicPops.ejs new file mode 100644 index 0000000..3583b7b --- /dev/null +++ b/views/partials/magicPops.ejs @@ -0,0 +1,14 @@ +
+

Popular

+
+ <% popular.map(p => { %> + + <% }) %> +
+
diff --git a/views/partials/magicSets.ejs b/views/partials/magicSets.ejs new file mode 100644 index 0000000..b61d3bb --- /dev/null +++ b/views/partials/magicSets.ejs @@ -0,0 +1,15 @@ +
+

Settings

+ +
diff --git a/views/partials/nav.ejs b/views/partials/nav.ejs new file mode 100644 index 0000000..838d228 --- /dev/null +++ b/views/partials/nav.ejs @@ -0,0 +1,59 @@ + \ No newline at end of file diff --git a/views/partials/popular.ejs b/views/partials/popular.ejs new file mode 100644 index 0000000..af83f34 --- /dev/null +++ b/views/partials/popular.ejs @@ -0,0 +1,14 @@ +
+

Popular

+
+ <% popular.map(p => { %> + + <% }) %> +
+
diff --git a/views/partials/search.ejs b/views/partials/search.ejs new file mode 100644 index 0000000..f838b4c --- /dev/null +++ b/views/partials/search.ejs @@ -0,0 +1,18 @@ + + + \ No newline at end of file diff --git a/views/partials/settings.ejs b/views/partials/settings.ejs new file mode 100644 index 0000000..08ac1cd --- /dev/null +++ b/views/partials/settings.ejs @@ -0,0 +1,15 @@ +
+

Settings

+ +
\ No newline at end of file diff --git a/views/recipe/create.ejs b/views/recipe/create.ejs new file mode 100644 index 0000000..a6921a8 --- /dev/null +++ b/views/recipe/create.ejs @@ -0,0 +1,51 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/categories') %> +
+
+

Create Recipe

+
+ + + + + + Upload image + <% if(files) { %> + + <% } %> + + + + + +
+ +
+ + +
+
+ +
+
+
+ <%- include('../partials/popular') %> +
+ + + + +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/recipe/createStep.ejs b/views/recipe/createStep.ejs new file mode 100644 index 0000000..99812f4 --- /dev/null +++ b/views/recipe/createStep.ejs @@ -0,0 +1,29 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/categories') %> +
+
+

Create Recipe Step

+
+ + + + + +
+
+
+ <%- include('../partials/popular') %> +
+ + + +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/recipe/edit.ejs b/views/recipe/edit.ejs new file mode 100644 index 0000000..d72b3e4 --- /dev/null +++ b/views/recipe/edit.ejs @@ -0,0 +1,71 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/categories') %> +
+
+

Edit Recipe Details and Ingredients

+
+ + + + Upload image + <% if(files) { %> + + <% } %> + + + + + +
+ +
+ +
+
+
+

Instructions (<%= recipe.steps.length %> steps)

+ <% recipe.steps.map(s => { %> +
+
+
Step <%= s.number %>:
+

<%= s.step %>

+
+
+
+ +
+
+ +
+
+
+ <% }) %> +
+
+ +
+
+ <%- include('../partials/popular') %> +
+ + + +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/recipe/editSteps.ejs b/views/recipe/editSteps.ejs new file mode 100644 index 0000000..1df2a68 --- /dev/null +++ b/views/recipe/editSteps.ejs @@ -0,0 +1,29 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/categories') %> +
+
+

Edit Recipe Steps

+
+ + + + + +
+
+
+ <%- include('../partials/popular') %> +
+ + + +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/recipe/show.ejs b/views/recipe/show.ejs new file mode 100644 index 0000000..9fcc771 --- /dev/null +++ b/views/recipe/show.ejs @@ -0,0 +1,55 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/categories') %> +
+

<%= recipe.title %>, + by + <%= recAuthor.bio.name %> +

+
+
+ recipe + <% if(usr) { %> + <% if(account.favorites.includes(recipe._id)) { %> +
+ +
+ <% } else { %> +
+ +
+ <% } %> + <% } %> +
+
+
Ingredients:
+
    + <% ingridients.map(i => { %> +
  • <%= i %>
  • + <% }) %> +
+
+
+

+ + <%= recipe.category %> + +

+
+

Instructions (<%= recipe.steps.length %> steps)

+ <% recipe.steps.map(s => { %> +
+
Step <%= s.number %>:
+

<%= s.step %>

+
+ <% }) %> +
+
+ <%- include('../partials/popular') %> +
+ +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/recipe/upload.ejs b/views/recipe/upload.ejs new file mode 100644 index 0000000..e8a9c81 --- /dev/null +++ b/views/recipe/upload.ejs @@ -0,0 +1,26 @@ +<%- include('../partials/header') %> +<%- include('../partials/nav') %> + +
+ <%- include('../partials/categories') %> +
+
+

Upload Recipe Image

+
+ + +
+
+
+ <%- include('../partials/popular') %> +
+ + + +<%- include('../partials/magicCats') %> +<%- include('../partials/magicPops') %> +<%- include('../partials/footer') %> diff --git a/views/register.ejs b/views/register.ejs new file mode 100644 index 0000000..1dbc13e --- /dev/null +++ b/views/register.ejs @@ -0,0 +1,32 @@ +<%- include('partials/header') %> +<%- include('partials/nav') %> +<%- include('partials/search') %> + +
+ <%- include('partials/categories') %> +
+
+

Register

+
+
+ + + + + + + + + + + +
+
+
+
+ <%- include('partials/popular') %> +
+ +<%- include('partials/magicCats') %> +<%- include('partials/magicPops') %> +<%- include('partials/footer') %> diff --git a/views/search.ejs b/views/search.ejs new file mode 100644 index 0000000..3bf35be --- /dev/null +++ b/views/search.ejs @@ -0,0 +1,38 @@ +<%- include('partials/header') %> +<%- include('partials/nav') %> +<%- include('partials/search') %> + +
+ <%- include('partials/categories') %> +
+
+ <% recipes.filter(r => { %> + <% if(r.title.toLowerCase().includes(query.toLowerCase())) { %> +
+ recipe + <%= r.title %> + <% if(usr) {%> + <% if(usr._id.equals(r.author.id)) { %> +
+
+ +
+
+ +
+
+ <% } %> + <% } %> +
+ <% } else { %> + + <% } %> + <% }) %> +
+
+ <%- include('partials/popular') %> +
+ +<%- include('partials/magicCats') %> +<%- include('partials/magicPops') %> +<%- include('partials/footer') %> -- cgit v1.2.3