diff --git a/src/client/_styles/index.scss b/src/client/_styles/index.scss index 7c85c57..83d6c25 100644 --- a/src/client/_styles/index.scss +++ b/src/client/_styles/index.scss @@ -97,15 +97,36 @@ body { height: fit-content; } +.button-1 { + padding: 2px var(--small-gap); + font-weight: bold; + background-color: var(--primary); + border-radius: var(--border-radius); + color: var(--text-opposite); + cursor: pointer; + height: fit-content; +} + +.button-2 { + color: var(--text); + border: 2px solid var(--primary); + border-radius: var(--border-radius); + padding: 2px var(--small-gap); + cursor: pointer; + display: flex; + align-items: center; + gap: var(--small-gap); + height: fit-content; +} + .close-button { display: flex; align-items: center; background-color: var(--light-error); - padding: 2px 8px; + padding: 2px var(--small-gap); border-radius: var(--border-radius); color: var(--text-opposite); cursor: pointer; - font-size: 12px; } .dropdown-button { @@ -177,6 +198,19 @@ body { outline: none; } +.modal-info-item { + color: var(--dark-text); + border: 2px solid var(--dark-3); + padding: 2px var(--small-gap); + border-radius: var(--border-radius); + cursor: pointer; + display: flex; + align-items: center; + gap: var(--small-gap); + height: fit-content; + width: fit-content; +} + // defined items end header { diff --git a/src/client/_templates/header.html b/src/client/_templates/header.html index f6d9283..5c975a9 100644 --- a/src/client/_templates/header.html +++ b/src/client/_templates/header.html @@ -4,16 +4,16 @@
-

Plate Pilot

+

Plate Pilot

Sign In
diff --git a/src/client/addplate/_styles/index.scss b/src/client/addplate/_styles/index.scss index a410c27..ae1ebbc 100644 --- a/src/client/addplate/_styles/index.scss +++ b/src/client/addplate/_styles/index.scss @@ -4,8 +4,6 @@ .addplate { display: flex; - flex-direction: row; - justify-content: center; width: 100%; padding: var(--gap); @@ -13,8 +11,7 @@ height: 100%; .container { - width: 98%; - + width: 100%; height: 100%; display: flex; @@ -27,7 +24,7 @@ .content-wrapper { width: 100%; - + max-width: 1100px; background-color: var(--surface); border: 2px solid var(--dark-2); @@ -152,12 +149,12 @@ display: flex; gap: var(--gap); flex-wrap: wrap; + flex-direction: column; - .column-wrapper { + .row-wrapper { display: flex; - flex-direction: column; color: var(--text); - gap: var(--small-gap); + gap: var(--gap); .sub-group { display: flex; @@ -181,7 +178,7 @@ .subcontent-wrapper { display: flex; - flex-wrap: wrap; + flex-direction: column; color: var(--text); gap: var(--small-gap); @@ -228,23 +225,17 @@ } .add-wrapper { - display: flex; - align-items: center; - - min-width: 250px; - - border: 2px solid var(--dark-3); - border-radius: var(--border-radius); - - padding: 0 var(--small-gap); .add-button-2 { display: flex; gap: var(--small-gap); padding: 5px; - - width: 100%; + + border: 2px solid var(--dark-3); + border-radius: var(--border-radius); + + max-width: 200px; cursor: pointer; diff --git a/src/client/addplate/index.html b/src/client/addplate/index.html index 907a61e..8f02f5d 100644 --- a/src/client/addplate/index.html +++ b/src/client/addplate/index.html @@ -74,7 +74,7 @@
-
+
Portions @@ -110,41 +110,6 @@
-
@@ -164,8 +129,7 @@
1. Step
Add Heading - Add Time - Add Time of Day + Add info
diff --git a/src/client/saveplates/_src/index.ts b/src/client/saveplates/_src/index.ts index f4977f9..0f38886 100644 --- a/src/client/saveplates/_src/index.ts +++ b/src/client/saveplates/_src/index.ts @@ -35,4 +35,27 @@ changeListButton?.addEventListener("click", () => { element.style.width = "100%"; element.style.maxWidth = "none"; }); +}); + +const savePlateItems = document.querySelectorAll(".saveplates-item"); + +savePlateItems.forEach(item => { + item.addEventListener("click", () => { + const clickedItemId = item.id; + + const modalItemId = clickedItemId + "-modal"; + const modalElement = document.getElementById(modalItemId); + + if (modalElement) { + modalElement.style.display = "flex"; + + const closeButton = modalElement.querySelector(".close-button"); + + if (closeButton) { + closeButton.addEventListener("click", () => { + modalElement.style.display = "none"; + }); + } + } + }); }); \ No newline at end of file diff --git a/src/client/saveplates/_styles/index.scss b/src/client/saveplates/_styles/index.scss index 22cef7e..b3f93d4 100644 --- a/src/client/saveplates/_styles/index.scss +++ b/src/client/saveplates/_styles/index.scss @@ -16,12 +16,277 @@ } } +.view-plate-modal-container { + display: none; + justify-content: center; + + .view-plate-modal { + position: absolute; + background-color: var(--surface); + + width: 98%; + height: fit-content; + + border: 2px solid var(--dark-2); + border-radius: var(--border-radius); + + padding: var(--small-gap); + margin: 4px; + + .modal-top-wrapper { + display: flex; + justify-content: space-between; + gap: var(--small-gap); + flex-wrap: wrap; + + .modal-top-left { + display: flex; + flex-wrap: wrap; + + .modal-name { + color: var(--text); + padding-right: var(--small-gap); + } + + .time-difficulty-wrapper { + display: flex; + gap: var(--small-gap); + } + } + + .modal-top-right { + display: flex; + gap: var(--gap); + flex-wrap: wrap; + justify-content: right; + } + } + + .content-container { + gap: var(--gap); + padding: var(--gap) 0; + + display: grid; + grid-template-columns: 300px .8fr 2fr; + + @media (max-width: 1100px) { + width: 100%; + display: flex; + flex-wrap: wrap; + flex-direction: column; + align-content: center; + } + + .content-info-wrapper { + display: flex; + flex-direction: column; + align-self: center; + border: 2px solid var(--dark-3); + border-radius: var(--border-radius); + height: fit-content; + padding: var(--small-gap); + gap: var(--gap); + + .content-info-top { + display: flex; + justify-content: space-between; + + .portions-wrapper { + border: 2px solid var(--dark-3); + border-radius: var(--border-radius); + display: flex; + height: 32px; + width: fit-content; + + .portions-input { + max-width: 50px; + outline: none; + background-color: transparent; + color: var(--text); + border: none; + padding: 1px 4px 1px var(--gap); + font-size: 16px; + } + + .portions-text { + background-color: var(--secondary); + border-radius: 0 var(--border-radius) var(--border-radius) 0; + border-left: 2px solid var(--dark-3); + color: var(--text); + display: flex; + align-items: center; + gap: 4px; + padding: 1px 8px; + cursor: pointer; + + .material-symbols-outlined { + font-size: 16px; + } + } + } + } + + .modal-info-content { + display: flex; + flex-direction: column; + + border: 2px solid var(--dark-4); + border-radius: var(--border-radius); + + padding: var(--small-gap); + gap: var(--small-gap); + + .modal-info-content-head { + color: var(--text); + font-weight: bold; + } + + .modal-info-items { + display: flex; + flex-direction: column; + + gap: 4px; + color: var(--text); + + padding-left: var(--small-gap); + + & > * { + position: relative; + display: flex; + gap: var(--gap); + + &::before { + position: absolute; + top: calc(var(--small-gap) * -0.5); + bottom: calc(var(--small-gap) * -0.5); + left: -15px; + content: ''; + width: 1px; + background-color: var(--secondary); + } + } + + .modal-info-item { + border: 2px solid var(--dark-3); + color: var(--text); + background-color: var(--dark-4); + border-radius: var(--border-radius); + padding: 2px var(--gap) 2px 14px; + width: fit-content; + display: flex; + gap: var(--small-gap); + + margin-left: 20px; + } + } + } + } + + .content-description-steps-wrapper { + display: flex; + flex-direction: column; + align-items: center; + height: fit-content; + background-color: var(--dark-4); + border-radius: var(--border-radius); + + @media (max-width: 1100px) { + background-color: transparent; + } + + .content-description-steps { + background-color: var(--dark-4); + border-radius: var(--border-radius); + padding: var(--small-gap); + display: flex; + flex-direction: column; + gap: var(--small-gap); + width: 100%; + + @media (max-width: 1100px) { + width: 300px; + } + + .step { + display: flex; + flex-direction: column; + align-items: center; + gap: var(--small-gap); + + border: 2px solid var(--dark-3); + padding: var(--small-gap); + border-radius: var(--border-radius); + width: 100%; + + .step-head { + color: var(--primary); + padding: 4px 0; + border-bottom: 2px solid var(--dark-3); + } + + .step-content { + display: flex; + flex-direction: column; + align-items: center; + gap: 2px; + color: var(--text); + + .light-step { + color: var(--dark-text); + } + } + } + } + } + + .description-area-wrapper { + display: flex; + flex-direction: column; + align-self: flex-start; + background-color: var(--dark-4); + border-radius: var(--border-radius); + height: fit-content; + width: 100%; + padding: var(--small-gap); + + .description-area { + display: flex; + flex-direction: column; + gap: var(--small-gap); + + .description { + display: flex; + flex-direction: column; + color: var(--text); + border: 2px solid var(--dark-3); + border-radius: var(--border-radius); + padding: var(--small-gap); + + .description-head { + color: var(--primary); + padding-bottom: var(--small-gap); + + } + + .description-content { + padding-left: var(--gap); + font-size: 15px; + } + } + } + } + } + } +} + + + .saveplates { display: flex; justify-content: center; .saveplates-container { - max-width: 1100px; + max-width: 1300px; display: flex; flex-direction: column; padding: var(--gap); diff --git a/src/client/saveplates/index.html b/src/client/saveplates/index.html index 17883cc..cb10a05 100644 --- a/src/client/saveplates/index.html +++ b/src/client/saveplates/index.html @@ -15,9 +15,139 @@ + +
+
+ +
+ +
+
+
+ 1. Step +
+ Kartoffeln Schälen + 7min +
+
+
+ 2. Step +
+ Kartoffeln kochen + 15min +
+
+
+ 3. Step +
+ Lachs in den Ofen + 200 Grad + 8min +
+
+
+
+
+
+
+ 1. Step Description +
+ Die Kartoffeln schälen und gründlich abwaschen. +
+
+
+ 2. Step Description +
+ Danach die Kartoffeln in kochendes und gesalzenes Wasser geben. Nach etwas 15min sind die Kartoffeln fertig. Man kann auch mit einer Gabel überprüfen, ob die Kartoffeln gut sind. +
+
+
+ 3. Step Description +
+ Als nächstes den Lachs in den Ofen tun. Diesen vorher auf 200 Grad Umluft vorheizen. Den Ofen auf 8min einstellen. Während der Lachs im Ofen ist, mit Step 4 weitermachen. +
+
+
+
+
+
+
@@ -28,7 +158,7 @@
-
+
Kartoffelbrei und Lachs
5:15h