all repos — website @ d3efe0a0788c2a5cf1a555ff4efd8e20ab60ca1d

personal website hosted at prithu.xyz, built using hugo

refactor the cta buttons on sections
Prithu Goswami prithugoswami524@gmail.com
Thu, 07 May 2020 11:24:07 +0530
commit

d3efe0a0788c2a5cf1a555ff4efd8e20ab60ca1d

parent

5b5327f54e80277ca05cf2d76cadd0eed6a9fd49

3 files changed, 35 insertions(+), 5 deletions(-)

jump to
M hugo-site/content/posts/jq/index.mdhugo-site/content/posts/jq/index.md

@@ -1,7 +1,7 @@

--- title: "Using jq to display cricket scores on i3bar" date: 1554643152 -description: "jq is a command line utility that parses JSON data and gives you the ability to access it using a simple syntax" +description: "jq is a command line utility that parses JSON data and gives you the ability to access it using a simple syntax." tags: - i3 - unix utilities
M hugo-site/layouts/index.htmlhugo-site/layouts/index.html

@@ -118,7 +118,7 @@ </div>

</a> {{ end }} </div> - <!-- <div class=btn id=project-cta>View All</div> --> + <a href="/projects/"><div class=btn id=project-cta>View All</div></a> </div> </div> </section>

@@ -138,7 +138,7 @@ </div>

</a> {{ end }} </div> - <!-- <div class=btn id=project-cta>View All</div> --> + <a href="/posts/"><div class=btn id=writeup-cta>View All</div></a> </div> </div> </section>
M hugo-site/static/css/main.csshugo-site/static/css/main.css

@@ -279,8 +279,9 @@ right: -7rem;

} .section-text{ - padding: 2rem 2rem; + padding: 0rem 2rem; padding-top: 3.5rem; + padding-bottom: 5rem; } .page-section h2 {

@@ -315,12 +316,35 @@ .btn {

margin: none; display: inline-block; padding: 1rem 2rem; + border-radius: 6px; +} + +.btn:hover{ + box-shadow: 0px 7px 7px rgba(0,0,0,0.15); + transform: translateY(-2px); + box-shadow: 0 10px 18px rgba(50, 50, 93, 0.25), 0 3px 6px rgba(0, 0, 0, 0.08); +} + +.btn:active{ + transform: translateY(1px); + box-shadow: 0 4px 7px rgba(50, 50, 93, 0.2), 0 3px 6px rgba(0, 0, 0, 0.08); } #project-cta{ + position: absolute; + bottom: 2rem; + right: -2rem; background: #B554E3; color: white; - transform: translate(34rem, -2rem); + box-shadow: 0px 7px 7px rgba(0,0,0,0.15); +} + +#writeup-cta{ + position: absolute; + bottom: 2rem; + right: -2rem; + background: #4ED44C; + color: white; box-shadow: 0px 7px 7px rgba(0,0,0,0.15); }

@@ -417,6 +441,12 @@ background: #B554E3;

color: white; box-shadow: 0px 7px 7px rgba(0,0,0,0.15); transform: none; + position: relative; + left: calc(70% - 70px); + top: 1.5rem; + } + + #writeup-cta{ position: relative; left: calc(70% - 70px); top: 1.5rem;