diff --git a/guestbook.html b/guestbook.html
index cd426aa..ef37869 100644
--- a/guestbook.html
+++ b/guestbook.html
@@ -5,11 +5,10 @@
-
+
-
Guestbook | Hamza Nasher-Alneam
@@ -22,14 +21,12 @@
-
-
Guest book - leave a note!
-
+
@@ -39,7 +36,7 @@
-
-
diff --git a/icons/phil.png b/icons/phil.png
new file mode 100644
index 0000000..e3bf114
Binary files /dev/null and b/icons/phil.png differ
diff --git a/icons/race.png b/icons/race.png
deleted file mode 100644
index 0593258..0000000
Binary files a/icons/race.png and /dev/null differ
diff --git a/index.html b/index.html
index 08d1dec..90fc62c 100644
--- a/index.html
+++ b/index.html
@@ -4,7 +4,7 @@
-
+
diff --git a/partials/menu.html b/partials/menu.html
index 4cfddad..33b71e9 100644
--- a/partials/menu.html
+++ b/partials/menu.html
@@ -1,24 +1,16 @@
\ No newline at end of file
diff --git a/projects.html b/projects.html
index d1a1bae..fe3fa8f 100644
--- a/projects.html
+++ b/projects.html
@@ -4,7 +4,7 @@
-
+
diff --git a/scripts/guestbook.js b/scripts/guestbook.js
index 7333edb..94f8510 100644
--- a/scripts/guestbook.js
+++ b/scripts/guestbook.js
@@ -5,6 +5,10 @@ function checkSubmissionValid(event) {
event.preventDefault();
document.querySelector('.status').textContent = "Fill out all fields";
}
+ else if (message.length > 500) {
+ event.preventDefault();
+ document.querySelector('.status').textContent = "Message too long";
+ }
else {
document.querySelector('.status').textContent = "Post succesful!";
}
@@ -58,12 +62,4 @@ function toggleElement(elementName) {
element.style.opacity = 0;
element.style.pointerEvents = "none";
}
-}
-
-function showAll() {
- getAll();
- let messagesElement = document.querySelector(".messages");
- messagesElement.style.overflowX = "hidden";
- messagesElement.style.overflowY = "auto";
- messagesElement.style.whiteSpace = "wrap";
}
\ No newline at end of file
diff --git a/styles/guestbook.css b/styles/guestbook.css
index 0f35db1..784f0b3 100644
--- a/styles/guestbook.css
+++ b/styles/guestbook.css
@@ -1,3 +1,73 @@
+* {
+ font-family: "Nunito", "Times New Roman", Times, serif;
+}
+
+body {
+ overflow-x: hidden;
+}
+
+.content {
+ transition: .2s;
+ margin: auto;
+ max-width: 80rem;
+ transition: .2s;
+}
+
+h2 {
+ position: relative;
+ margin: 1rem .75rem .75rem 2.5rem;
+ font-size: 1.5rem;
+ transition: .2s;
+}
+
+h3 {
+ margin: .75rem 0 0 2rem;
+}
+
+button {
+ padding: .2rem .5rem;
+ font-size: 1.1rem;
+ color: #fff;
+ background-color: var(--theme-color);
+ border: solid .2rem var(--theme-color);
+ border-radius: .5rem;
+ box-shadow: 0 .1rem .2rem #ddd;
+ transition: .15s;
+}
+
+button:hover {
+ color: var(--theme-color);
+ background-color: transparent;
+}
+
+button:active {
+ transform: scale(.98);
+}
+
+a {
+ color: var(--theme-color);
+}
+
+@media only screen and (max-width: 700px) {
+ .content {
+ grid-template-columns: 100%;
+ margin-right: 0;
+ width: 100vw;
+ }
+}
+
+@media (prefers-color-scheme: dark) {
+ button {
+ box-shadow: 0 .2rem .2rem #000;
+ }
+}
+
+
+
+
+
+
+
.guestbook {
padding-top: 2rem;
position: relative;
@@ -9,11 +79,6 @@
.guestbook .messages {
margin: 1rem 0;
- max-width: 100vw;
- overflow-x: auto;
- overflow-y: hidden;
- white-space: nowrap;
- scrollbar-width: none;
text-align: center;
}
@@ -26,7 +91,7 @@
margin: 0 .3rem;
min-height: 14rem;
min-width: 20rem;
- max-width: 25rem;
+ max-width: 24rem;
/* max-width: 700px; */
border: solid .2rem var(--theme-color);
border-radius: 1rem;
diff --git a/thoughts.html b/thoughts.html
index b4249ff..26fafc9 100644
--- a/thoughts.html
+++ b/thoughts.html
@@ -3,7 +3,7 @@
-
+