From 57edc63f244ff2a4076291a70253f6fe2ec8c9ec Mon Sep 17 00:00:00 2001 From: pedrocx486 Date: Sun, 5 Mar 2023 01:54:59 -0300 Subject: [PATCH] I hate this code. Needs to be completely rewritten --- src/app/archives/archives.component.html | 6 +-- src/app/archives/archives.component.scss | 2 +- src/app/home/home.component.html | 2 +- src/app/posts/posts.component.html | 6 +-- src/app/posts/posts.component.scss | 16 +++--- src/assets/posts/archive.json | 25 +++++++++ .../navigation/navigation.component.html | 7 ++- .../navigation/navigation.component.scss | 34 ++++++++++-- src/shared/styles/buttons.scss | 54 +++---------------- src/shared/styles/cards.scss | 16 +++--- src/shared/styles/inputs.scss | 2 +- src/shared/styles/lists.scss | 7 +-- src/shared/styles/placard.scss | 4 +- src/shared/styles/utils.scss | 11 +++- src/styles.scss | 2 +- 15 files changed, 105 insertions(+), 89 deletions(-) diff --git a/src/app/archives/archives.component.html b/src/app/archives/archives.component.html index 0e450e5..135dde3 100755 --- a/src/app/archives/archives.component.html +++ b/src/app/archives/archives.component.html @@ -4,9 +4,9 @@
- +   - +
@@ -22,6 +22,6 @@ \ No newline at end of file diff --git a/src/app/archives/archives.component.scss b/src/app/archives/archives.component.scss index 2f4cef8..1991b42 100755 --- a/src/app/archives/archives.component.scss +++ b/src/app/archives/archives.component.scss @@ -2,7 +2,7 @@ input[type="text"] { width: 30%; } -@media only screen and (hover: none) { +@media screen and (max-width: 600px) { input[type="text"] { width: 55%; } diff --git a/src/app/home/home.component.html b/src/app/home/home.component.html index 248e22b..982fdb6 100755 --- a/src/app/home/home.component.html +++ b/src/app/home/home.component.html @@ -15,6 +15,6 @@ \ No newline at end of file diff --git a/src/app/posts/posts.component.html b/src/app/posts/posts.component.html index c084cf3..e71d562 100755 --- a/src/app/posts/posts.component.html +++ b/src/app/posts/posts.component.html @@ -44,13 +44,13 @@
- + -
+   - diff --git a/src/app/posts/posts.component.scss b/src/app/posts/posts.component.scss index de9fc13..f047c49 100755 --- a/src/app/posts/posts.component.scss +++ b/src/app/posts/posts.component.scss @@ -3,22 +3,19 @@ padding: 1rem; margin-top: 5rem !important; margin: 0 auto; - background-color: rgb(56, 56, 56); - box-shadow: #000a 4px 4px; + background-color: rgb(37, 37, 37); width: 50%; .avatar { padding: 0 1rem 0 1rem; display: inline-block; - max-width: 200px; - max-height: 150px; + max-width: 100px; + max-height: 100px; } .avatar img { - border: 3px solid #6100a2; - border-radius: 5px; - max-width: 200px; - max-height: 150px; + max-width: 100px; + max-height: 100px; display: block; } @@ -27,7 +24,6 @@ .bio-username { color: rgb(255, 255, 255); - text-shadow: 0px 0px 10px #00bc97; font-size: larger; } @@ -41,7 +37,7 @@ } } -@media only screen and (hover: none) { +@media screen and (max-width: 600px) { .margins { margin: unset; } diff --git a/src/assets/posts/archive.json b/src/assets/posts/archive.json index 8dbe898..de953e6 100755 --- a/src/assets/posts/archive.json +++ b/src/assets/posts/archive.json @@ -1,4 +1,29 @@ [ + { + "postTitle": "Hello World!", + "timestamp": "1654062776", + "filename": "hello-world" + }, + { + "postTitle": "Hello World!", + "timestamp": "1654062776", + "filename": "hello-world" + }, + { + "postTitle": "Hello World!", + "timestamp": "1654062776", + "filename": "hello-world" + }, + { + "postTitle": "Hello World!", + "timestamp": "1654062776", + "filename": "hello-world" + }, + { + "postTitle": "Hello World!", + "timestamp": "1654062776", + "filename": "hello-world" + }, { "postTitle": "Hello World!", "timestamp": "1654062776", diff --git a/src/shared/components/navigation/navigation.component.html b/src/shared/components/navigation/navigation.component.html index 9eb5c67..d55f1b0 100755 --- a/src/shared/components/navigation/navigation.component.html +++ b/src/shared/components/navigation/navigation.component.html @@ -1,6 +1,9 @@
- {{settings.blogTitle}} - Home + + {{settings.blogTitle}} + » + + Home Archives {{settings?.customUrl?.title}} diff --git a/src/shared/components/navigation/navigation.component.scss b/src/shared/components/navigation/navigation.component.scss index eb9c121..45849e7 100755 --- a/src/shared/components/navigation/navigation.component.scss +++ b/src/shared/components/navigation/navigation.component.scss @@ -1,13 +1,13 @@ .topnav { min-height: 48px; overflow: hidden; - background-color: #333; + background-color: #2a2a2a; position: relative; top: 0; left: 0; right: 0; z-index: 2; - box-shadow: #000a 4px 4px; + box-shadow: #000a 2px 2px; } .topnav a { @@ -18,20 +18,24 @@ padding: 15px 16px; text-decoration: none; font-size: 17px; - border-right: rgb(159, 159, 159) 1px solid; + border-right: rgb(97, 97, 97) 1px solid; } .topnav a:last-child { border-right: unset; } +.topnav a:first-child { + border-right: unset; +} + .topnav a:hover:not(.no-focus) { - background-color: #ddd; + background-color: #a1a1a1; color: black; } .topnav a.active { - background-color: rgb(97, 0, 162); + background-color: rgb(229, 114, 0); color: white; } @@ -39,11 +43,31 @@ display: none; } +.topnav .pointy-thingy { + font-size: 2rem; + line-height: 0%; + position: absolute; + margin-top: 0.5rem; + margin-left: 0.2rem; +} + +.topnav .first-after-name { + margin-left: 1rem; +} + @media screen and (max-width: 600px) { .topnav a:not(:first-child) { display: none; } + .topnav .first-after-name { + margin-left: unset; + } + + .topnav a { + border-right: unset; + } + .topnav a.icon { float: right; display: block; diff --git a/src/shared/styles/buttons.scss b/src/shared/styles/buttons.scss index 1fb2175..3eaadb4 100755 --- a/src/shared/styles/buttons.scss +++ b/src/shared/styles/buttons.scss @@ -5,8 +5,8 @@ button { text-decoration: none; padding: 0.6rem; border: none; - box-shadow: #000a 4px 4px; - font-size: .8rem; + box-shadow: #000a 2px 2px; + font-size: 0.8rem; } // Misc. @@ -15,51 +15,11 @@ button { } // Primary -.btn-primary { - background-color: rgb(97, 0, 162); +.btn { + background-color: rgb(229, 114, 0); color: white; } -.btn-primary:hover { - box-shadow: 0px 0px 7px rgb(97, 0, 162); -} - -// Secondary -.btn-secondary { - background-color: #00d199; - color: #444; -} - -.btn-secondary:hover { - box-shadow: 0px 0px 7px #00d199; -} - -// Tertiary -.btn-tertiary { - background-color: #17a2b8; - color: white; -} - -.btn-tertiary:hover { - box-shadow: 0px 0px 7px #17a2b8; -} - -// Action -.btn-action { - background-color: #00905e; - color: white; -} - -.btn-action:hover { - box-shadow: 0px 0px 7px #00905e; -} - -// Action -.btn-bad-action { - background-color: #cf2200; - color: white; -} - -.btn-bad-action:hover { - box-shadow: 0px 0px 7px #cf2200; -} +.btn:hover { + box-shadow: unset; +} \ No newline at end of file diff --git a/src/shared/styles/cards.scss b/src/shared/styles/cards.scss index be3f235..9aa9cdc 100755 --- a/src/shared/styles/cards.scss +++ b/src/shared/styles/cards.scss @@ -1,21 +1,22 @@ // Cards .card { border: none; - box-shadow: #000a 4px 4px; + box-shadow: #000a 2px 2px; } .card-header { border-bottom: none; - background-color: rgb(97, 0, 162); - padding: 1rem; + background-color: rgb(86, 86, 86); + padding: 0.5rem; + padding-bottom: 1rem; margin-bottom: 0; } .title { - color: #00ffea !important; + color: #c2c2c2 !important; text-decoration: none; - font-size: 1.5rem; - font-weight: 500; + font-size: 1rem; + font-weight: 300; } .timestamp { @@ -29,6 +30,3 @@ margin-top: -10px; color: #bbb; } - -// .card-text { -// } \ No newline at end of file diff --git a/src/shared/styles/inputs.scss b/src/shared/styles/inputs.scss index 153d940..98b1046 100755 --- a/src/shared/styles/inputs.scss +++ b/src/shared/styles/inputs.scss @@ -12,5 +12,5 @@ input[type="text"] { background-color: transparent; color: white; font-size: 15px; - box-shadow: #000a 4px 4px; + box-shadow: #000a 2px 2px; } diff --git a/src/shared/styles/lists.scss b/src/shared/styles/lists.scss index 17a2279..41cf4bc 100755 --- a/src/shared/styles/lists.scss +++ b/src/shared/styles/lists.scss @@ -1,17 +1,18 @@ // Lists .list-group { padding: 2rem; + margin-left: 10%; + margin-right: 10%; } .list-item { padding: 1rem; - border: rgb(88, 88, 88) solid 1px; background-color: rgb(46, 46, 46); margin-top: 0.5rem; - box-shadow: #000a 4px 4px; + box-shadow: #000a 2px 2px; } .list-item:hover { - background-color: rgb(52, 39, 62); + background-color: rgba(52, 52, 52); cursor: pointer; } diff --git a/src/shared/styles/placard.scss b/src/shared/styles/placard.scss index b49788a..96e141b 100755 --- a/src/shared/styles/placard.scss +++ b/src/shared/styles/placard.scss @@ -1,13 +1,13 @@ // Placard .placard { - background-color: rgb(97, 0, 162); + background-color: rgb(59, 59, 59); text-align: center; padding: 2rem; margin: 2rem; font-weight: 200; font-size: 1.25rem; color: white; - box-shadow: #000a 4px 4px; + box-shadow: #000a 2px 2px; } .placard-title { diff --git a/src/shared/styles/utils.scss b/src/shared/styles/utils.scss index b4342e2..a63f8f4 100755 --- a/src/shared/styles/utils.scss +++ b/src/shared/styles/utils.scss @@ -1,10 +1,12 @@ //Margins .margins { margin: 1rem; + margin-left: 15%; + margin-right: 15%; } .margins-sides { - width: 40%; + min-width: 20%; margin: 0 auto; } @@ -21,3 +23,10 @@ .text-center { text-align: center; } + +@media screen and (max-width: 600px) { + .margins { + margin-left: 5%; + margin-right: 5%; + } +} \ No newline at end of file diff --git a/src/styles.scss b/src/styles.scss index 492f66f..af5d4e5 100755 --- a/src/styles.scss +++ b/src/styles.scss @@ -12,7 +12,7 @@ body { font-family: monospace; margin-left: 0.5em; margin-right: 0.5em; - background-color: #444; + background-color: #363636; } // Anchors