-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix(global): stylelint errors * feat(blog): add dark theme * feat(projects): add dark theme * fix(projects): background card
- Loading branch information
1 parent
7f0c566
commit 002722e
Showing
30 changed files
with
358 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
@import url('./variables.css'); | ||
@import url('./global.css'); | ||
@import url('./theme.css'); | ||
@import url('./animations.css'); | ||
@import url('./variables.css'); | ||
@import url('./posts.css'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
.dark-mode { | ||
--color: theme('colors.gray-main.400'); | ||
|
||
/* --color: theme('colors.gray-main.50'); */ | ||
--bg: theme('colors.dark'); | ||
|
||
/* --bg: theme('colors.blue-main.950'); */ | ||
--icons-color: theme('colors.white'); | ||
--title-color: theme('colors.gray-main.400'); | ||
--nav-links-color: var(--color); | ||
--nav-link-active-color: var(--color); | ||
--tag-bg: var(--bg); | ||
--tag-bg-hover: var(--bg); | ||
--blog-card-shadow: var(--bg); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
<template> | ||
<div> | ||
<ul class="flex items-center"> | ||
<li v-if="$colorMode.preference !== 'light'"> | ||
<IconLight | ||
:class="getClasses('light')" | ||
class="cursor-pointer" | ||
@click="$colorMode.preference = 'light'" | ||
/> | ||
</li> | ||
<li v-else> | ||
<IconDark | ||
:class="getClasses('dark')" | ||
class="cursor-pointer" | ||
@click="$colorMode.preference = 'dark'" | ||
/> | ||
</li> | ||
</ul> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
name: 'ColorModePicker', | ||
components: { | ||
IconLight: () => import('@/assets/icons/light.svg?inline'), | ||
IconDark: () => import('@/assets/icons/dark.svg?inline'), | ||
}, | ||
methods: { | ||
getClasses(color) { | ||
if (this.$colorMode && this.$colorMode.unknown) { | ||
return {} | ||
} | ||
return { | ||
[this.$colorMode.value]: true, | ||
selected: color === this.$colorMode.value, | ||
} | ||
}, | ||
selectColor(color) { | ||
this.$colorMode.preference = color | ||
}, | ||
}, | ||
} | ||
</script> | ||
|
||
<style scoped lang="scss"> | ||
ul { | ||
@apply m-0 p-0 list-none; | ||
li { | ||
@apply inline-block px-1; | ||
.dark { | ||
fill: theme('colors.white'); | ||
} | ||
} | ||
} | ||
</style> |
Oops, something went wrong.