umputun/remark42

support color-scheme

开放

#1,430 创建于 2022年7月22日

 (3 条评论) (0 个反应) (0 位负责人)Go (432 个派生)user submission
frontendgood-first-issuehelp wanted

仓库指标

星标
 (5,500 个星标)
PR 合并指标
 (平均合并 87天 10小时) (30 天内合并 18 个 PR)

描述

  • add new option for theme to the config in order to understand if site supports auto switch between light and dart theme
  • add color-scheme: light dark when the param is true, add light or dark when false and switch coloe-scheme value accordingly
  • remove this change https://github.com/umputun/remark42/pull/1429

Cases

Auto

var remark_config = {
  theme: 'auto'
}
color-scheme: light dark;

Add support for auto switch between themes

Dark

var remark_config = {
  theme: 'dark'
}
color-scheme: dark;

Light

var remark_config = {
  theme: 'light'
}
color-scheme: light;

贡献者指南