morethanmin / morethan-log

😎 A static blog using notion database
https://morethan-log.vercel.app
MIT License
1.89k stars 1.51k forks source link

[feat, refactor]: Support to config default theme #360

Closed nfl1ryxditimo12 closed 2 months ago

nfl1ryxditimo12 commented 4 months ago

Description

1. Unify scattered Scheme type declarations

2. Simplify ternary operator

3. Support to config default theme

4. Auto mode according to the system theme


Usage

site.config.js #L23-24

스크란샷 2024-05-03 03 26 01
  1. If you want to choose light mode as the default theme, please write that. default value is dark.

  2. If followSystemTheme is true, the appearance will be changed according to the system theme on first visit your blog. After that, follow the cookie settings.


Example

Light mode

Frame 133999 (1)

Dark mode

Frame 133998 (1)

Auto mode (Base on system appearance)

Frame 134000 (2)


Related tickets

https://github.com/morethanmin/morethan-log/issues/XX


PR Checklist

vercel[bot] commented 4 months ago

@nfl1ryxditimo12 is attempting to deploy a commit to the morethanmin's projects Team on Vercel.

A member of the Team first needs to authorize it.

nfl1ryxditimo12 commented 3 months ago

@morethanmin PR 확인 λΆ€νƒλ“œλ €μš”~!

nfl1ryxditimo12 commented 2 months ago

μΆ”κ°€ν–ˆμŠ΅λ‹ˆλ‹€ 🫑

vercel[bot] commented 2 months ago

The latest updates on your projects. Learn more about Vercel for Git β†—οΈŽ

Name Status Preview Comments Updated (UTC)
morethan-log βœ… Ready (Inspect) Visit Preview πŸ’¬ Add feedback Jun 19, 2024 1:25am