ybbond

My site. The main domain
Log | Files | Refs | README | LICENSE | CC-LICENSE

commit a4e7f22674b962ab45f05fd2279fa110f680f42a
parent fe7c6a09a6bbf0618af8e1ed8c5502c3a12670da
Author: Yohanes Bandung Bondowoso <hi@ybbond.dev>
Date:   Mon, 22 Jun 2020 04:27:10 +0700

refactor: different font weight for light/dark

Diffstat:
Massets/styles.scss | 8+++++---
Massets/variables.scss | 7+++++--
Mcontent/posts/Why I Positioned Sidebar to the Right.md | 2+-

3 files changed, 11 insertions(+), 6 deletions(-)

diff --git a/assets/styles.scss b/assets/styles.scss
@@ -6,10 +6,10 @@ html {
   @include themify($themes) {
     background-color: themed('color-background');
     color: themed('color-text');
+    font-weight: themed('font-weight');
   }
   font-family: $font-text;
   letter-spacing: 0.025rem;
-  font-weight: 300;
   line-height: 1.6;
   text-rendering: optimizeLegibility;
   font-size: 16px;
@@ -26,7 +26,9 @@ html {
 }
 
 strong {
-  font-weight: 600;
+  @include themify($themes) {
+    font-weight: themed('font-weight-bold');
+  }
 }
 
 body {
@@ -78,8 +80,8 @@ code {
 h1, h2, h3, h4, h5 {
   @include themify($themes) {
     color: themed('color-green');
+    font-weight: themed('font-weight');
   }
-  font-weight: unset;
   font-family: $font-text;
   line-height: 1.3;
   position: relative;
diff --git a/assets/variables.scss b/assets/variables.scss
@@ -28,6 +28,8 @@ $themes: (
     color-red: #C31B00,
     color-blue: #2263b6,
     color-green: #257933,
+    font-weight: 400,
+    font-weight-bold: 600,
   ),
   dark: (
     color-text: #E3E0D7,
@@ -37,8 +39,10 @@ $themes: (
     color-red: #F9690E,
     color-blue: #8DBFFF,
     color-green: #79D688,
+    font-weight: 300,
+    font-weight-bold: 700,
   ),
 );
 
 $font-mono: 'iA Writer Duospace', monospace;
-$font-text: -apple-system, BlinkMacSystemFont, avenir, helvetica, ubuntu, roboto, noto, segoe ui, arial, sans-serif;-
\ No newline at end of file
+$font-text: -apple-system, BlinkMacSystemFont, avenir, helvetica, ubuntu, roboto, noto, segoe ui, arial, sans-serif;
diff --git a/content/posts/Why I Positioned Sidebar to the Right.md b/content/posts/Why I Positioned Sidebar to the Right.md
@@ -16,7 +16,7 @@ I laughed when I read that tweet. It brings back so much memories of my previous
 
 Positioning the sidebar to the right reduces distraction when I toggle it. If the sidebar is on the left, the text shifts around whenever the sidebar is toggled on or off. Readjusting my eyes for the moved text creates disturbance to my logical thinking. "Why are you not just leave the sidebar open?", you might be asking. I want to keep the screen real estate wide.
 
-Back then, I often toggle the sidebar because two reasons. First, the project I was in uses **Redux**-**Saga**. Second, I was using **VSCode**. 
+Back then, I often toggle the sidebar because two reasons. First, the project I was working on uses **Redux**-**Saga**. Second, I used to use **VSCode**.
 
 Redux-Saga is a great states and IO management for React, I was blown away when I was first using it. Sadly, cannot grok the Redux paradigm easily. I often need to see the file structure when I write new files or refactoring. My current project uses Apollo GraphQL and Domain Driven Development paradigm. I am comfortable using the current setup.