From 61bafdc6e0243b9fc6170ea4bb27a883c401ea99 Mon Sep 17 00:00:00 2001
From: Pavuuk <88192739+Pavuuk@users.noreply.github.com>
Date: Thu, 11 Nov 2021 23:25:13 +0500
Subject: [PATCH 1/4] master
---
index.html | 2 +-
index.js | 29 +++++++++++++++++++++++++++++
2 files changed, 30 insertions(+), 1 deletion(-)
diff --git a/index.html b/index.html
index ddc8250..a4b333f 100644
--- a/index.html
+++ b/index.html
@@ -57,7 +57,7 @@
Напиток №1
-
+
diff --git a/index.js b/index.js
index e69de29..c970575 100644
--- a/index.js
+++ b/index.js
@@ -0,0 +1,29 @@
+document.getElementById('add-button').onclick = addList;
+
+function addList()
+{
+ let list = document.querySelectorAll ('fieldset');
+ let clone = list[0].cloneNode(true);
+ let countOfmenu = list.length;
+ clone.children[0].innerHTML = 'Напиток №' + (countOfmenu + 1);
+ rec = clone.querySelectorAll('input[type="x"]');
+ for (let x of rec) x.name = 'milk' + countOfmenu;
+ list[countOfmenu - 1].after(clone);
+}
+function moveList()
+{
+ let list = document.querySelectorAll ('fieldset');
+ let move = this.parentNode;
+ if (list.length > 1)
+ {
+ move.remove();
+ list = document.querySelectorAll ('fieldset');
+ for (let i = 0; i < list.length; i++)
+ {
+ rec = list[i].querySelectorAll('input[type="x"]');
+ for (let x of rec) x.name = 'milk' + i;
+ list[i].children[0].innerHTML = 'Напиток №' + (i + 1);
+ }
+
+ };
+}
\ No newline at end of file
From 5558985e3516dd48a9f45b5aa1f373566bddd7b1 Mon Sep 17 00:00:00 2001
From: Pavuuk <88192739+Pavuuk@users.noreply.github.com>
Date: Fri, 12 Nov 2021 15:26:55 +0500
Subject: [PATCH 2/4] =?UTF-8?q?=D0=9D=D0=BE=D0=B2=D0=BE=D0=B6=D0=B8=D0=BB?=
=?UTF-8?q?=D0=BE=D0=B2=D0=B0=20=D0=95=D0=BA=D0=B0=D1=82=D0=B5=D1=80=D0=B8?=
=?UTF-8?q?=D0=BD=D0=B0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
index.html | 69 ++++--------------
index.js | 200 ++++++++++++++++++++++++++++++++++++++++++++++-------
styles.css | 72 +++++++++++++++++++
3 files changed, 261 insertions(+), 80 deletions(-)
diff --git a/index.html b/index.html
index a4b333f..fcc350e 100644
--- a/index.html
+++ b/index.html
@@ -6,64 +6,23 @@
-